设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6342|回复: 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'
& E0 w- Q# g! \; Z3 |*/* p. K" A  i; }
is
- c2 P1 U: g# o        part, GlobalDistObj, assignLObj:object;row,Lan:integer;4 @+ r) f, |; I5 E& X# n- k
do
3 E8 }& l) e9 V" w" Q" g        Lan := rootfolder.Internal.Tools.AOLlanguage;
, N. E% f  V1 N: F' p5 Q        if current = @.Destination -- else return& x& x' _4 `* b# P& H
        then% L* {. U, H+ x" `% e
                @.Destination := void;0 q$ P1 B% R( j7 b/ i% d) \3 I5 n
                if @.occupied then
1 `0 d/ x, z9 u& o                        part := @.cont;
! J1 l( K3 ]  P0 y0 d                        @.transpOrder := void;4 Z# l/ `/ u& p+ z' O
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
6 X  v/ O2 P4 q; X6 Z' h0 b- j                                @,root.eventcontroller.simTime);
. Y! d: y& ~) V/ U                        @.HasOrder := false;
8 K; `$ H/ V0 }+ [+ j2 F                        @.DrivingHome := true;& I( R. U5 y& X% y' r# ^. n! J
                        rgManager.tryToStartTransOrder;5 g) P  q) _* r$ ~# P) d+ `# Q3 p
                        if @.Destination = void
# d2 v& h# H% ?5 o                        then -- no transport order for vehicle @' O. w1 O8 |  Z9 P# r1 M9 W" q
                                @.Destination :=$ [: X2 S$ f3 s% H+ A" R0 v
                                rgManager.nearestFreeStation(@,track.~);
% q0 _2 D9 r5 e, o( A                                newDirection(@);   
$ w& U$ z+ Y& X                                if @.Destination /= void then( h# D5 b+ o/ g4 s$ k$ o. \; j
                                        @.Destination.NumReservation :=
# N. Q& ], W, s* S                                        @.Destination.NumReservation + 1;+ x7 l# O5 c! _$ V, p
                                end;
3 A& B) z7 U* ?9 p/ y  T4 L4 [                                @.CurrIcon := "drivingHome";# A0 ]" n# q: O; Q- j4 q, p
                                @.DrivingHome := true;' F) Z, X. G" p
                        end;& G3 O6 M# i# `2 I2 ~2 i, c4 Z: U
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
0 E" d/ P9 R+ ?" T                        part := @.transpOrder;1 F; Y4 a$ x  p, [1 z
                        part.move(@);-- load part  {; F* H6 O! L0 f# J2 F9 B
                        @.CurrIcon := "load";1 x' e# `# ]' v4 b: n
                        GlobalDistObj := part.globDestination;! [3 @6 x  S3 u+ E  ?% {+ U
                        assignLObj := rgmanager.rgAssignL;
" P" C. p: T  |1 Q                        row := assignLObj.getRowNo(GlobalDistObj);4 G: c2 b& |# q2 k$ E2 @
                        if Row = -1 then -- since 70
2 z# X1 h/ e8 p                                if lan=1 then
9 H9 C; s1 d; f' ^* j+ v                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),6 I" ~: [/ E  R& H- ?" ~! X
                                                to_str("in der Andockstation: \"",?.~.name,"\""));- G8 Y0 R& x; w& S6 m
                                else+ f+ \; ~+ c/ g$ }5 R+ p5 |
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
9 D1 d4 J6 \  l" D4 i                                                to_str("in docking station: \"",?.~.name,"\""));                               
5 l/ f1 m  B; e8 X6 b% ^. p                                end;
6 |1 b) B: I5 h- h6 n7 Y: O' b7 H, g                        else) b5 a& C4 V" d5 |8 q
                                @.Destination := assignLObj[1,row];
. S% T5 B- m- q+ E& q                        end;                        5 j8 P( z$ }5 z, A
                        newDirection(@);
$ o: B; X1 q& b" r4 `3 F                        @.HasOrder := true;( x" F5 c. [! n$ E0 K/ g" r
                end;: x; B' p( t) }  j% U
        end;
1 b. B* s8 o7 _2 K7 b! v8 gend;        -- of the method8 f6 j7 n, p4 T$ t
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
4 i7 O7 G# {1 L* ?0 R
2 y! \* ^/ W" v这是AGV_putin中arrive的method。- \% y1 w3 v6 c8 J) G; g  D
9 I+ Q+ H& f0 i/ Y( `
当到达物料速度越高时,这个报警更多,
* F! R- [4 r& \: Y; ~可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
/ G4 u6 O/ z& Y- `# w/ P/ L/ E程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
* ]' X# M4 g/ ~9 b& s. g) |* ]. n' f7 u  J) W& D( ^
另外一个小建议,就是move,所有的move都可以这样
1 A: P! Q1 {" eif not move() then debug end
& D6 _$ b5 z. B, q$ c8 m; j这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。" ?6 \- s+ s" y. s$ W
plant simulation中的free libraries有AGV模板,5 N1 b: e9 [. K1 }. P! F
里面也有案例。! h8 ^( N0 I+ x0 [
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
- P; p( E. i- |3 x& X, [' v+ F( o# q6 E- U: y+ q# A) a6 J4 ]4 t
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
8 X: N' h9 S/ F. j6 B, \& O- o1 F  P$ Z
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
' J( p4 B( a& w# |* [$ j& e; S这是AGV_putin中arrive的method。8 E  |2 m# J7 _$ C: S. s7 h
  h; t! z; [) Y
当到达物料速度越高时,这个报警更多,

8 N* \5 E5 r: Q- x8 X另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-31 20:20 , Processed in 0.017633 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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