设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8032|回复: 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 G. e# r. J, D8 e0 C
*/
* u6 W6 y& \: @0 x( ?$ W$ U; vis" R$ k' q/ a4 I+ r
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;0 x9 K; [& U: X
do
$ H/ c8 o# t' J        Lan := rootfolder.Internal.Tools.AOLlanguage;
5 `4 Q  R. x4 W, t2 W. {; `        if current = @.Destination -- else return
" C% \$ D* m1 `! h1 @$ ^4 [5 n        then
* |8 I% B& h+ Z1 g                @.Destination := void;- K! C: \& \5 I
                if @.occupied then% ~2 j* z- X8 k( F: }
                        part := @.cont;
" V6 U# J1 v* ]( W( G* n                        @.transpOrder := void;8 `! A. E2 [  M8 v" a- c
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,3 k" H/ O, S6 i4 w  o2 x& a
                                @,root.eventcontroller.simTime);
3 w) K3 p, U+ m% z/ l                        @.HasOrder := false;: L. f& m/ @9 Q2 C0 N
                        @.DrivingHome := true;
2 O/ Q1 S) h5 o+ V: g0 W" o, y                        rgManager.tryToStartTransOrder;' F& c6 D3 J  w
                        if @.Destination = void
4 H/ V8 a' ]  a2 |                        then -- no transport order for vehicle @4 V8 J. T, |. B4 \  f7 G
                                @.Destination :=0 T) Y% N( @' W2 H9 {# m
                                rgManager.nearestFreeStation(@,track.~);6 r. Z0 A& w- _+ D3 F# b# ?
                                newDirection(@);   3 m! n- i2 F% y0 g, R8 b
                                if @.Destination /= void then
/ Z; c/ o7 `6 `) {; R                                        @.Destination.NumReservation :=
9 M* t2 r5 X" P% _1 m                                        @.Destination.NumReservation + 1;
, e( x! a4 Z. t6 S& s                                end;' y* l/ N6 q0 `1 ~! X+ A
                                @.CurrIcon := "drivingHome";
/ w6 Q2 ~" A# M  }" D1 `0 c6 C$ S                                @.DrivingHome := true;% ?8 }' Z# Z; K4 |* o5 t  k$ r
                        end;* ?* D% o! u0 `% m; r7 `0 i5 E
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station' m# L* J% u* u1 y) M1 O
                        part := @.transpOrder;1 X0 }2 R: X- b, G
                        part.move(@);-- load part, U- T0 V: }, s; p" p
                        @.CurrIcon := "load";4 w1 p- C% C) V# N2 l1 [& E$ @7 S
                        GlobalDistObj := part.globDestination;5 r* d3 P+ _1 F! U: L+ S, w* C
                        assignLObj := rgmanager.rgAssignL;3 M- v. b7 F+ }. F/ G
                        row := assignLObj.getRowNo(GlobalDistObj);9 I1 H# Z8 G; A0 I  a5 q. g
                        if Row = -1 then -- since 70# d0 B6 S# B2 K: h/ W
                                if lan=1 then2 r; Q$ J1 R5 Z4 d1 U5 A  n& a
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),0 t/ A3 `4 c. z' Y; _
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
( y( I& U4 s- W" S) O6 W& S                                else  N4 z7 P& w9 T0 ^5 m
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),- M9 r* e$ A8 O+ {6 F- B6 a
                                                to_str("in docking station: \"",?.~.name,"\""));                                5 U) i9 R- n! q- s
                                end;* d/ y3 |/ a! ^2 \
                        else1 P0 a- {+ ?# x
                                @.Destination := assignLObj[1,row];
+ o; B: m, M- S+ _+ V& e. y  I" B                        end;                       
/ J7 u: u, J- D% B8 J                        newDirection(@);
  p3 w1 O1 M! L# Y& y                        @.HasOrder := true;5 C2 _2 J2 T+ c$ W
                end;1 Z/ P5 c( R8 S
        end;
: c2 I- {$ J! I3 lend;        -- of the method4 `" K* m/ s$ c2 y5 V
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ( t, B9 r' `9 N
' E; i7 V0 w5 k  L$ G: s
这是AGV_putin中arrive的method。; o8 i( @( ]8 t; ^% _1 w
1 m- Y& |1 ^& _( w
当到达物料速度越高时,这个报警更多,
" V% D3 {0 H& W' Y$ k- L4 G可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
: y  U/ `# q$ c4 `5 q程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?' e; O1 E- D6 f5 v0 B: P  S3 X
. R8 V, _5 G' |' o8 ~3 k5 m
另外一个小建议,就是move,所有的move都可以这样
" X* g9 c2 W' e% J! r; Z6 Hif not move() then debug end- Y9 A* G; z! `5 n2 w
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
  @# C9 U; z' J* [( ?( Z. x7 k3 uplant simulation中的free libraries有AGV模板,
& r  L  {( |  J+ }) z里面也有案例。; o, R: a5 ~6 o' y8 l
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。# [' {7 v5 x" P$ F3 t) Y. R

- Y/ A7 [. s7 L& e  P我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
2 c) L: T+ M$ w$ ]
; t  ?, Q% y1 \" S那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 " A5 m7 D: ^. L; I* R8 W  M7 x
这是AGV_putin中arrive的method。+ I1 \5 |6 n- @* K  x( ]

4 K4 C# R: P' _9 w, C& k& `9 u当到达物料速度越高时,这个报警更多,
# \+ Q8 x# j5 Z5 o* a6 }, `
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-11 21:18 , Processed in 0.020703 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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