设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7537|回复: 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'
: f1 r0 B; U3 _! t; B*/7 ~9 w* o5 |' }3 B. Y2 j
is# i0 f% k! h3 {; {
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
8 U1 d0 Q1 s% E# ^4 h4 ]4 vdo' B# R: z/ L$ u+ o8 e3 D
        Lan := rootfolder.Internal.Tools.AOLlanguage;! G6 S# w/ V9 B# Q+ q5 _( a% [( O
        if current = @.Destination -- else return
' K( ?! ^+ o8 y        then: g4 h$ N) J3 G3 L1 P; |' Z9 V
                @.Destination := void;
- F2 L) t( d  z* x3 T1 B                if @.occupied then
$ p+ ^. F+ X3 h, z# X3 z+ ?                        part := @.cont;
5 m" n( {+ q3 A, q$ v                        @.transpOrder := void;
: _0 r; X3 W+ O: r; y6 v* ?  B, Q                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1," ]; R% o6 E* z+ S
                                @,root.eventcontroller.simTime);; E- O- Z4 `/ C% ?
                        @.HasOrder := false;
) k& i9 D" U- L                        @.DrivingHome := true;7 W, r% ]0 u; V; C" }
                        rgManager.tryToStartTransOrder;$ o3 a4 q9 s9 ^! z
                        if @.Destination = void
4 K. x/ ?8 Y/ J                        then -- no transport order for vehicle @7 I& ~4 v6 j" \. A7 X, H8 i3 s
                                @.Destination :=
# \+ C! C1 J( j2 F5 U                                rgManager.nearestFreeStation(@,track.~);' y* \  q& E3 \, _  X
                                newDirection(@);   , }$ `4 s2 f0 z: c; [$ a9 V) J- m, p
                                if @.Destination /= void then
- Z; G. G6 g( T) \0 l                                        @.Destination.NumReservation :=& B* X: W3 L* g
                                        @.Destination.NumReservation + 1;$ B: Q+ K6 G8 }* _
                                end;
5 A2 J! C; y8 C8 d. H  w4 d- A                                @.CurrIcon := "drivingHome";
/ i5 H: R( \/ p4 E8 u! z& q. m& h                                @.DrivingHome := true;
# \: ~1 f5 ?( I8 B                        end;1 {% G7 i5 `" P6 @1 W
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
$ a1 _4 O$ a7 W                        part := @.transpOrder;
# c9 \, i8 ]) l' S) j                        part.move(@);-- load part! o7 \( F0 }1 Z$ j1 w+ a
                        @.CurrIcon := "load";
. J" K. c0 W! _. u+ }                        GlobalDistObj := part.globDestination;. M3 y7 t  c- w( f; r2 f
                        assignLObj := rgmanager.rgAssignL;" m) {- f, o1 f) c" l$ [
                        row := assignLObj.getRowNo(GlobalDistObj);. U4 {! m$ Y4 y4 R  ^
                        if Row = -1 then -- since 70& A3 X: h4 n; u5 D6 a3 M2 [0 H+ q3 v
                                if lan=1 then
3 f' N1 O- z# O  g                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),5 J0 O( R7 e( I, z5 j- ~) d- z3 x
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
" D2 }" R6 p) K( f                                else
  E/ q* Q& G9 \; ^5 ]                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),! _' G: b, W/ W
                                                to_str("in docking station: \"",?.~.name,"\""));                               
: w. a  ^% {9 c$ Q5 {1 J2 @                                end;: ]. Y  t- N- c/ e4 S
                        else7 _$ X1 _  W  d: X: R6 m! W* @2 {
                                @.Destination := assignLObj[1,row];. B7 U; X3 s4 u, f" r1 i
                        end;                        ( @; ?  M. }  Z0 Y# {% x0 F- k3 i$ U
                        newDirection(@);
- v$ _5 d3 }4 L                        @.HasOrder := true;  h7 ]# \7 R9 i& ~9 y" g
                end;8 ]7 x0 a! h8 V# @/ H2 K
        end;% X! E  }6 P! F
end;        -- of the method: U, \0 |- m) P. [" B
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 6 l9 L' J# Z+ k3 x0 t5 Q

" T2 ~4 O2 t/ ?( G5 Q这是AGV_putin中arrive的method。
1 Q  z* z, z1 \2 D$ N6 Z6 j
, ]# F1 V+ y; ^" g当到达物料速度越高时,这个报警更多,7 @" J3 C; n/ A8 {% t. d$ {6 g
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。/ N  a9 {* B  d: t( b# {
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
- t: |( Q' B  y# O) D6 h$ c+ A+ _; {" @9 D
另外一个小建议,就是move,所有的move都可以这样
: _5 L7 p# D, w& ]if not move() then debug end
  k+ ~& q. R& p7 u8 p这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。: q  R. N7 ^2 U$ q
plant simulation中的free libraries有AGV模板,
" _& J5 `" o1 S里面也有案例。
/ g# Z8 S+ H: _# D  v* T( a我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。9 l" _" }$ \1 J% l3 }) q; Q
2 j: m( u  f# F7 U4 ]& e
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 * O2 Y/ [8 R* m6 H7 S' n8 L
1 n3 M( u2 d8 J) q
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
! A, o( T( _5 S/ g这是AGV_putin中arrive的method。
# S2 z2 J% h0 _3 p4 A6 A8 u' d2 I, F6 j# v
当到达物料速度越高时,这个报警更多,

( O& i" X1 q2 p9 y" G+ d( h另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-16 23:36 , Processed in 0.020948 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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