设为首页收藏本站

最大的系统仿真与系统优化公益交流社区

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9631|回复: 9

[求助] 用AGV模板发生了以下错误,请解!

  [复制链接]
发表于 2011-11-5 16:38:28 | 显示全部楼层 |阅读模式
问题在哪里?

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有帐号?注册

x
 楼主| 发表于 2011-11-14 10:37:54 | 显示全部楼层
没有解决,再顶一下。
 楼主| 发表于 2011-11-17 11:03:27 | 显示全部楼层
/* called by:        entrance ctrl of the object 'track'
% I: A' ~1 g9 G*/
2 X7 t) j" ?) v& u. H5 @9 Y; o4 zis  ?* g& H+ R7 h; n( R  U' ]
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
5 |; ], A8 a4 F9 A/ e' p' n5 l* jdo( R: g- q. d& o* K5 e
        Lan := rootfolder.Internal.Tools.AOLlanguage;
' s2 c6 |, Y6 `; h. G% M; H        if current = @.Destination -- else return' i/ N1 z( }5 U
        then4 _2 P, }6 h6 k2 H) G
                @.Destination := void;1 |4 b6 ~: }' v, v  U
                if @.occupied then
  s* Y8 a4 }* @$ p3 Q; x                        part := @.cont;3 o4 I" d$ b0 n# i
                        @.transpOrder := void;  ^; X. P* V& Y3 V
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,% _+ f! d+ Y9 a) `1 N3 ]4 C3 d/ g
                                @,root.eventcontroller.simTime);
9 B5 a+ E6 H; `, ~9 T; R7 {3 v                        @.HasOrder := false;, Z' m' X4 ?3 R/ M1 Y6 ?. m- c
                        @.DrivingHome := true;5 v3 K6 l4 _& I" g' u8 T: I
                        rgManager.tryToStartTransOrder;
& a1 o. C- n* `2 L0 e0 v                        if @.Destination = void1 x* U: o) A) H- m, j  {( c# _( H7 i
                        then -- no transport order for vehicle @
7 u  V; }/ u, x  M2 ^$ P" m0 L                                @.Destination :=8 s6 Z) ~  b- C  e, ^( P7 w
                                rgManager.nearestFreeStation(@,track.~);
, }( {: W% ~6 k5 F' X  \1 }                                newDirection(@);   % A) E* G! Y* r8 P- a; h! w* R2 E9 b
                                if @.Destination /= void then( L5 a  v8 J' z6 O! j
                                        @.Destination.NumReservation :=
8 ^( N$ Y2 y8 J' a( Y5 {! D- u                                        @.Destination.NumReservation + 1;
2 w3 w1 {+ ]. j6 L% _                                end;6 L, N- F. n2 ^1 w
                                @.CurrIcon := "drivingHome";
7 m1 k4 _$ _" i* S5 o  u  J8 o                                @.DrivingHome := true;
% N( c3 k4 u. t- |+ g2 j7 {3 `                        end;
0 h; K3 t; n  }- Q, @6 h" v0 `5 I% K4 X                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
  }* f. P$ f3 _9 T                        part := @.transpOrder;
+ K- b2 y5 ^7 r. B                        part.move(@);-- load part
! P% n) n. p: l# t; Q; v% m                        @.CurrIcon := "load";
+ ?6 ?. h* m% g- o                        GlobalDistObj := part.globDestination;" H$ X/ U, t2 b- |/ a+ t- K0 D
                        assignLObj := rgmanager.rgAssignL;' z2 d2 f' o3 c; ?3 ^- T& J4 a3 O9 |
                        row := assignLObj.getRowNo(GlobalDistObj);
3 E" Y" J. u) c9 }& Q& c                        if Row = -1 then -- since 70
: h% {9 H3 {( y( W( m                                if lan=1 then
9 P7 s1 I' }% c9 g9 [0 f1 ?; ^                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
$ z) P. f+ h( P5 w                                                to_str("in der Andockstation: \"",?.~.name,"\""));8 S' g- e4 ~% v3 A- a* `3 u
                                else
5 N: P. n% o4 L) m7 p4 Y0 Y                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
9 R% `% D6 p  a/ _( S# k+ V4 d                                                to_str("in docking station: \"",?.~.name,"\""));                                7 p- Q1 T  s  W
                                end;% `' n( m; q3 M6 r6 K6 S6 T  A
                        else
9 l, j# }$ x: H9 n, o                                @.Destination := assignLObj[1,row];! }6 e  g, H, j$ p) L, D/ N' p
                        end;                       
9 t2 }! C  z4 R- R* L( h" W                        newDirection(@);. u0 s8 M5 b5 q" V6 t
                        @.HasOrder := true;
$ U8 t+ B# m& X; _4 E5 |                end;
, g+ w! O/ C) ^        end;
, y0 t  G: o7 Zend;        -- of the method: e" `9 t$ \" B6 ^! G
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 1 A+ H( S6 y! Z9 A8 `

8 q9 D; ?0 q$ K( p4 K6 v8 R这是AGV_putin中arrive的method。% `& _* ]5 r' n; f( S3 z

8 J- j3 O7 C5 V0 Y- d当到达物料速度越高时,这个报警更多,
& ~- W, [1 d( z; L# _可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。: R+ x7 e6 w( v; F6 B8 b
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?, Q9 ~0 m( `- e2 ^
5 S9 o2 @, V' m, P1 R
另外一个小建议,就是move,所有的move都可以这样
6 Y3 |* k. s( H' nif not move() then debug end' \9 s  w2 r) u' M8 R! k6 V7 v
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
6 h, s. |: U3 P, ?8 |( Zplant simulation中的free libraries有AGV模板,
& g; X6 R! E! H里面也有案例。" V6 V: p3 ~3 f- D( y3 T
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
2 D) X2 z6 C: D. n* x3 E# q2 S2 T1 r9 D. O
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ( f) d/ s% }7 v" Q
* T0 z% g  R4 s% a
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
+ H' }9 J8 Z* Z( L这是AGV_putin中arrive的method。* i  b$ N; S5 p5 X4 H% v% u- g2 f

  f9 ]2 i- |: Q6 S% h6 ?2 M当到达物料速度越高时,这个报警更多,
* L7 x  k$ c2 l
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|Archiver|手机版|SimulWay 道于仿真   

GMT+8, 2026-8-13 02:11 , Processed in 0.018399 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

快速回复 返回顶部 返回列表