设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6364|回复: 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'
% G$ Z! B/ T2 q+ ~8 d. m*/0 g" ^5 u1 o$ p3 ^
is
# \% C! B6 q2 F2 P6 H        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
! M2 b9 t' E' c; k  ^do
2 D- I3 y6 e5 T8 H        Lan := rootfolder.Internal.Tools.AOLlanguage;  u/ x6 k5 i* X7 Y* d  l) j+ d
        if current = @.Destination -- else return9 ]* ~+ \2 k/ r# X( Q& S
        then5 y  S! ?( V- v3 B
                @.Destination := void;
4 U! h0 i( t7 J/ Q& d                if @.occupied then
1 T/ ]* }1 R9 x9 c3 J/ @5 R. O                        part := @.cont;  A8 g' k/ w5 G% ]) f
                        @.transpOrder := void;
% ^) m& [( W1 t+ k# Q5 H% B                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
8 t/ T  ~1 w  W  x& j                                @,root.eventcontroller.simTime);
# L. C8 L$ P3 v  w6 z- i; f                        @.HasOrder := false;! [; o& L0 r0 U# s( k4 D/ b
                        @.DrivingHome := true;2 T- P; b( p/ b2 A3 c+ L
                        rgManager.tryToStartTransOrder;3 r# `1 f) n1 J. {
                        if @.Destination = void; F9 K' O* Q- x2 N
                        then -- no transport order for vehicle @; E. X& y) [# |+ K( E$ c
                                @.Destination :=
1 G2 y: {2 t, @9 i# E( U                                rgManager.nearestFreeStation(@,track.~);. `2 S) k. T7 V
                                newDirection(@);   " ]) h. A. f4 Q
                                if @.Destination /= void then
) ]: O' t. w; x( L& U9 B7 B                                        @.Destination.NumReservation :=5 N* u5 i, V* O/ L7 }. r% s
                                        @.Destination.NumReservation + 1;8 B* n) P! h% r5 m
                                end;
, e7 ]- e" k9 ?2 ^4 {                                @.CurrIcon := "drivingHome";
# d) m2 B& b/ M' l, M                                @.DrivingHome := true;2 A! `% D* i# _
                        end;- P* F. p. s4 o! ^# A
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
: _8 O8 }2 q" G, s( v( H$ T  j                        part := @.transpOrder;
' f) \) H( V" r- |                        part.move(@);-- load part
+ x; q. ?6 a* ^! t% D4 ~) D4 `                        @.CurrIcon := "load";) e/ |4 G( L) |$ G7 F% d& Y  b
                        GlobalDistObj := part.globDestination;! O! b, u2 i3 L9 K  n1 W
                        assignLObj := rgmanager.rgAssignL;/ @- g' h1 s0 H
                        row := assignLObj.getRowNo(GlobalDistObj);
/ g9 t& Q4 i1 T: F% }* }# X5 |& ]                        if Row = -1 then -- since 70
  I( Z" i( p; e  p5 f; q                                if lan=1 then
6 E6 K3 |6 _1 D  x1 h+ i                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),3 ?, c) |7 Y& @
                                                to_str("in der Andockstation: \"",?.~.name,"\""));, ~) D" `0 ~" Q
                                else0 d0 P" j' e# l
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
9 k. O; q4 f* }1 W& L+ T' I' I                                                to_str("in docking station: \"",?.~.name,"\""));                               
/ ]# v3 j1 M! {0 }" V                                end;5 N0 V; H, V$ i0 {! Z& S
                        else2 \4 `5 k. C) ?- D" N; K2 j, f, Q
                                @.Destination := assignLObj[1,row];
1 V8 h/ s$ ?. g, \, p                        end;                        9 q$ f. j8 {& m6 L" O& P5 D& u. A# U
                        newDirection(@);
; w5 b. q1 B! ?( Q% e4 g' a: H" y                        @.HasOrder := true;4 ^6 J/ b/ }( D' O. |
                end;
9 m4 b8 F: f9 }+ u7 u5 I& M        end;
, T; C) O* v! p9 S/ d; Z& V3 tend;        -- of the method
/ u$ S$ I4 Z0 G9 `3 N
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ' _, |: ?$ p! ], E" g/ x
) e# i7 r6 O3 |4 F) h
这是AGV_putin中arrive的method。
! k; a. Y" q$ w' c# `8 ~: B3 ^9 v
: Y- `) d4 H9 ?, |% y% {) S8 t当到达物料速度越高时,这个报警更多,
' c. r2 p- e! s可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
% i6 w9 P7 U/ \2 q: _+ d' V5 k1 |程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
5 \2 ^0 }, h* x* ?+ @3 W; D) ?
另外一个小建议,就是move,所有的move都可以这样
8 i5 f- W# D1 H1 u( |. `/ Pif not move() then debug end
5 E# l3 S8 @! d这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
1 |4 i$ z' Q4 a8 _% H2 gplant simulation中的free libraries有AGV模板,
9 v0 \% \$ p) e里面也有案例。
4 j9 H' Y. B% u/ A% c8 ?我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。% A$ X% {9 D0 Y0 D
9 f' H$ V3 k7 v  Q2 h
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
( K! E3 e6 C: k/ ?' J1 x5 @4 A2 m! a% {' S; X3 a0 G$ _" B, t! D( _
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 / H7 C0 U4 d& T1 T1 D
这是AGV_putin中arrive的method。" ~0 p* L3 B8 P/ u5 P- G) T
0 J9 C: I2 B( \9 E
当到达物料速度越高时,这个报警更多,

3 G4 V3 P" w, b# C另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-1 23:31 , Processed in 0.018895 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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