设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8303|回复: 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'
* ]8 @" k9 {# E. n* E, F6 L3 m*/5 I8 _3 o* U+ b7 ]7 u
is. M; h! \+ M3 s5 |
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;" q4 d9 l$ u* F- P3 F2 D
do; p% H! j$ C9 e3 [7 V1 {
        Lan := rootfolder.Internal.Tools.AOLlanguage;( m6 R; P: o; I: s, }
        if current = @.Destination -- else return* b* d& ^) F" t/ t2 p# j; l
        then' t" d; m2 @* F  g+ G, h4 f
                @.Destination := void;
4 U, q, ~! ^4 A$ k( C: S0 p+ L4 u3 F( I                if @.occupied then
, }- B% @  D  d8 O                        part := @.cont;9 w: x2 k2 m5 m$ j( q6 l( M4 e
                        @.transpOrder := void;3 i) Z! R3 B7 W5 C
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
# I5 j+ \7 s+ ]" O; z* O5 j! ~0 L1 v                                @,root.eventcontroller.simTime);
1 p1 A' F& v$ _, S                        @.HasOrder := false;
( s/ ~& T; w: S; s                        @.DrivingHome := true;; Y; r# p+ N9 V6 N9 k$ T
                        rgManager.tryToStartTransOrder;( X; y4 Z) _" i- }% `. g
                        if @.Destination = void2 T8 y% y. }" m/ ^: F1 G7 F
                        then -- no transport order for vehicle @  Y8 D6 H: i9 k* x
                                @.Destination :=& c5 G  @& _9 g* O( ?
                                rgManager.nearestFreeStation(@,track.~);/ N1 J# @! R. E0 K( ~- ]
                                newDirection(@);   2 o$ h2 H4 h: o; j/ n2 u
                                if @.Destination /= void then
- r* o( A! U" N6 @. x# [                                        @.Destination.NumReservation :=
* {8 t( b, n+ S: v                                        @.Destination.NumReservation + 1;& t# F1 U  k; B/ `
                                end;) P! c) u  P% t9 w
                                @.CurrIcon := "drivingHome";) c2 ?9 V: |8 d# x
                                @.DrivingHome := true;4 A% ]( K+ Q/ n4 ~  @  _
                        end;
$ h: d3 v1 P" c8 Z% t. V' {                else -- the vehicle @ is empty, both vehicle and part are in the same dock station' u5 O" L+ q+ G4 Y( k5 X- v0 L
                        part := @.transpOrder;
; r1 Y3 c! K+ H! e% z6 B' S) K                        part.move(@);-- load part
4 J" ], r/ a2 B# q$ I; C' I8 O) m                        @.CurrIcon := "load";7 |7 o$ A1 ]/ i; m# @
                        GlobalDistObj := part.globDestination;' y: }. g* u. K4 u: C' C/ L) D
                        assignLObj := rgmanager.rgAssignL;1 m4 @$ Q' b& a/ c
                        row := assignLObj.getRowNo(GlobalDistObj);
1 b" E4 C3 ^8 P) X6 p                        if Row = -1 then -- since 70. S9 h" f6 l; U6 d  B( }
                                if lan=1 then
) b; b& `8 L) o( s: U( z, Q                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\"")," r: ]& n: c8 G6 }! J8 ~1 N* f/ E( S
                                                to_str("in der Andockstation: \"",?.~.name,"\""));/ i, i# H; f+ f8 C* u
                                else; f. u( Y/ W, ^. _
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
1 W* O1 h5 l/ p, Y                                                to_str("in docking station: \"",?.~.name,"\""));                                ( x4 X; p6 H4 w
                                end;
  c: G; y1 ?" o, P4 J1 T, S0 ?                        else
) S4 x& @' b" C$ M- i9 Y: ^                                @.Destination := assignLObj[1,row];' B3 i7 }0 G9 e6 m9 |
                        end;                       
3 j5 S: G' d1 X$ a7 l                        newDirection(@);
. D" v2 B+ ]7 H8 J( Y                        @.HasOrder := true;8 k- b" |  ^* Q& W; F
                end;
& r+ G) o. ]! u+ N        end;
4 y( i, F( Y3 j( ~6 vend;        -- of the method8 k$ A1 t3 ^' \( Y; C
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ( H. h4 m1 z$ I- V; e/ P
2 J- w5 U9 f/ g) k* x
这是AGV_putin中arrive的method。9 Z6 ^. p! j2 @- N; E
" I& Y6 S. S* Y0 ]
当到达物料速度越高时,这个报警更多,
. |& ~  X8 s; a, k! z可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。2 ?6 a' r( d- a
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
& H& Y8 [0 I7 _5 e6 g+ P: v& l, e% A1 V6 L0 `
另外一个小建议,就是move,所有的move都可以这样
* q* q$ S4 S) G# ^, Fif not move() then debug end0 i/ Y" x2 \, G8 E
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。7 w1 |' t( d; M" q+ [& r
plant simulation中的free libraries有AGV模板,
( C, h+ m2 S4 C0 i! |1 h1 U6 h里面也有案例。2 ?  ]4 D. m( y9 m  H) ]
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
" o4 y* z7 J4 l1 F3 v4 \
4 j$ H* ?+ H4 B- [我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
# ^6 u; K3 s/ J( T) V# o# X6 C$ V; [, J
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 : n' F( T  G0 C, a; f
这是AGV_putin中arrive的method。" w2 A# W) i0 N5 Y
. C, [, Q: z2 P# X7 F7 _* d
当到达物料速度越高时,这个报警更多,

% r2 j* s4 i- H) _6 E另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-26 14:40 , Processed in 0.019574 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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