设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7391|回复: 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'
7 C" ~  h' ?' p* ]*/* ^- [) m- X2 `! C- _5 X+ R
is. C1 N3 b; y, m7 s3 Q6 B
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;4 `1 l6 X! s5 |1 f5 b- \: u
do
/ ^3 e' v$ K* K+ W0 I        Lan := rootfolder.Internal.Tools.AOLlanguage;
3 Q$ s6 Q3 x' w% G; O, Q        if current = @.Destination -- else return# V6 e9 W9 Q# P6 g5 q
        then
0 y. ]. M: k9 c- r: D$ L                @.Destination := void;
" r5 J8 X& K0 q, Q) f8 e8 M                if @.occupied then
# T" |& X% v* U- [/ R                        part := @.cont;2 S. B/ M- w% G" L" L" x
                        @.transpOrder := void;
* ?6 T' u% c1 N  v# S; K                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,7 @- a% o5 O6 j
                                @,root.eventcontroller.simTime);
. c, F) W3 u9 B* G- Q                        @.HasOrder := false;6 U: ~" x) [: }8 N, f
                        @.DrivingHome := true;
3 j+ F6 s& F& l, y/ q; g( S                        rgManager.tryToStartTransOrder;
; l) s" c1 E' E( T                        if @.Destination = void
, M% H1 P0 j9 ^1 G' l6 Z0 T                        then -- no transport order for vehicle @
0 K# p9 Z8 M2 m( k                                @.Destination :=  c. A# s+ f! v7 m
                                rgManager.nearestFreeStation(@,track.~);, P0 q9 y5 z8 |* o  P9 Z6 m
                                newDirection(@);   0 y/ Y0 |, H' c+ _+ V
                                if @.Destination /= void then
! P) x* S4 B+ h8 Y+ A                                        @.Destination.NumReservation :=
2 ?) O. V/ @% |, D                                        @.Destination.NumReservation + 1;) D4 F0 w+ z( k" X! _
                                end;
0 p; k7 n% D9 t9 M8 Z$ T7 [; _, m! F                                @.CurrIcon := "drivingHome";
6 w1 u9 t, S% H% X- T                                @.DrivingHome := true;: w7 R7 n3 Q0 J' K; z) ]
                        end;# z9 O/ k0 ?1 B0 e% o) {# j, o
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
5 d: f( J( w/ M9 k. }2 a                        part := @.transpOrder;: m2 ~( P( k3 {8 Q# i, H
                        part.move(@);-- load part4 c3 r( V. O) h" q
                        @.CurrIcon := "load";) E: B5 Y3 o0 X! ^$ X3 M+ O
                        GlobalDistObj := part.globDestination;0 a' Z2 c7 s# z0 r1 U/ ^
                        assignLObj := rgmanager.rgAssignL;
, h: o- S# B$ i1 Y, d                        row := assignLObj.getRowNo(GlobalDistObj);
4 P% _7 o& J! @1 i7 c4 B0 h                        if Row = -1 then -- since 70& c. k+ {, T9 D( c9 d1 k  H
                                if lan=1 then
6 L0 w8 Y1 G$ l( j0 \                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),0 O# Z) s+ A; y1 F9 f* n
                                                to_str("in der Andockstation: \"",?.~.name,"\""));2 M. I# p/ p& W" P& W8 o
                                else7 Q/ Z0 c( k' N5 i, [
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),4 h+ o7 c. i9 z/ L6 ^
                                                to_str("in docking station: \"",?.~.name,"\""));                               
$ M/ _+ U; }% E; ~4 b. ?                                end;3 D& o9 F, [2 i& v
                        else: U4 l5 I( ~' h" Y) ^9 m
                                @.Destination := assignLObj[1,row];
1 ~6 ?  m. Y: l# n                        end;                       
/ ]1 A1 S1 Y% a! p9 ^+ G                        newDirection(@);; ?) q+ t% l; W% S7 U
                        @.HasOrder := true;
2 z) g  c" T$ A4 X$ q9 N1 M* W. T7 u                end;
4 ?# u( {% T) S" T+ x; y        end;
2 M# K: Z; s1 iend;        -- of the method. Y, d6 b5 d1 e3 l& K
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 0 e' _2 v1 `/ p4 M9 m$ ]% i

+ ^( Q( D, ]4 U) x- I这是AGV_putin中arrive的method。
! w( i. g# F4 W5 o* R) h6 h7 s' F- j
当到达物料速度越高时,这个报警更多,
9 T3 C# h+ Q+ u, h6 [. I7 C+ r可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
& Y. k( r% d+ Q, X. W程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?3 j; a. V9 e9 o& ?* H
2 M( r, d# U. P# L* y7 d% j
另外一个小建议,就是move,所有的move都可以这样
+ Y; `- e- d, `1 |5 A0 Sif not move() then debug end$ t- n$ c: `' C0 K  B7 L4 x
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。0 o! Z4 ?+ W5 E  R4 n( G. ~/ O
plant simulation中的free libraries有AGV模板,
( z! F! z. @. o里面也有案例。4 B+ `+ T6 X+ B
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
* Q2 L& p. Z: a9 A) W+ M5 x# @) ^: h: X, ~" x6 r- n2 o1 y( e8 E' z3 A
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 % J1 z3 O$ ?6 x2 E( p+ L1 s

$ P, s8 m# g  e5 J: o那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 2 f; _( j3 Y6 b" g9 w0 V+ ?- k
这是AGV_putin中arrive的method。% R. @9 g0 l$ T8 ^6 \

1 t0 G# }+ \' |7 d. X/ t当到达物料速度越高时,这个报警更多,

6 g' E0 h, @3 j9 a0 i. g$ t+ R另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-9 07:19 , Processed in 0.018624 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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