设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6109|回复: 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'
1 h5 i( m3 V9 a3 v*/4 B4 H0 ]1 @1 _0 ?, l% O4 t
is" I! L9 f2 K  r) _9 w: {
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
4 _% U& H; g' ^8 r; `# w& W2 Wdo+ K* w7 N; y  p# P2 v0 Y! T8 z
        Lan := rootfolder.Internal.Tools.AOLlanguage;! u" i* v2 l# Z- J$ D9 D
        if current = @.Destination -- else return8 u$ e2 F/ D2 A0 q, I
        then6 `! q% j$ h, b0 r
                @.Destination := void;2 z- z" F! A! g% l+ W: {
                if @.occupied then" Z# d  N3 K  O" m8 E
                        part := @.cont;
9 f0 d: C+ u- L) S                        @.transpOrder := void;
" E- E' g% J) M, v5 c                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
4 p/ t3 i7 X( L5 G6 a( c& x: N                                @,root.eventcontroller.simTime);: W7 K* O9 n( b% T3 P! E
                        @.HasOrder := false;
& r* [* m) y6 A$ l9 }8 z                        @.DrivingHome := true;
1 z% [; \; X9 a0 r                        rgManager.tryToStartTransOrder;
- }$ ~6 R. d) V4 y                        if @.Destination = void
7 V. N5 d, J& s6 N; I5 h                        then -- no transport order for vehicle @
: U* A, W& Y& F+ x9 q% i: I                                @.Destination :=
5 j; c! V4 l+ J- @                                rgManager.nearestFreeStation(@,track.~);! `- X& P& H+ e7 m
                                newDirection(@);   
- b7 h6 U5 R! R$ o# m                                if @.Destination /= void then
, O& F& P4 h( w! P                                        @.Destination.NumReservation :=4 @3 w1 k9 `* r0 B- @) H: y
                                        @.Destination.NumReservation + 1;7 H) m) A- k+ {# ]
                                end;; q+ B0 W. N% W7 x1 K0 F
                                @.CurrIcon := "drivingHome";
" P$ `* m; p. o+ f. E( f; |) ]8 q                                @.DrivingHome := true;
' g! `! @( h1 t2 O. V# y/ W                        end;
& `1 O. a, \$ k7 }: r4 Z" P; P+ E                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
; @! T3 W& E. r( V% X5 L' [# n                        part := @.transpOrder;
6 u) [; u! s% t. C1 M" T: ]" F                        part.move(@);-- load part
7 C9 k% h% H& {/ D$ t1 g: e3 U                        @.CurrIcon := "load";
; c( O; r  C; b) D* l3 U) E  D                        GlobalDistObj := part.globDestination;
9 C6 n- N" Y+ N                        assignLObj := rgmanager.rgAssignL;0 D/ e$ s, I) M' O7 ?' y% X6 T7 E
                        row := assignLObj.getRowNo(GlobalDistObj);- D& m6 e; j0 F- k
                        if Row = -1 then -- since 70
0 L0 u% w: c, W: r2 k3 T- l2 i8 ^                                if lan=1 then  l: w+ u$ @$ o( L4 a! T. ]
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),, w$ [$ x& Z; r
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
4 X3 W8 v( M% Z( q0 b. _; g) C                                else, ^* ?8 L: [2 Q5 w9 q: e8 U
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),- }( h8 ?1 V3 L  [4 R; K1 S0 F! Y
                                                to_str("in docking station: \"",?.~.name,"\""));                                , v/ J5 u7 e/ }& f7 _) n
                                end;+ e$ b* w$ H$ Q9 J. e6 T& s9 [
                        else# V1 e: ~! ^. Z4 i
                                @.Destination := assignLObj[1,row];9 ^8 J- O9 j6 o$ Q
                        end;                        9 |, e/ \! w& q; i. G5 I
                        newDirection(@);; g, t8 L! v/ d7 a( ?
                        @.HasOrder := true;! p6 |& B& ?- R& i4 _. U( V: w
                end;9 m$ [. o1 r! y/ }: |
        end;
9 C+ B  L) p. G' {9 i  s, }end;        -- of the method! P2 K; c- o: @" O9 b/ r" F5 C
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ' e0 |4 ^: T8 r  ^, Z

9 @8 G* A  j* `8 [( |8 Q/ P这是AGV_putin中arrive的method。. o5 h* Q# e; T  ]! X  f

! p" t% t6 f! o4 C/ N当到达物料速度越高时,这个报警更多,
' ~& s% j6 ~3 U7 ?% A( N8 z可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。# r' D8 j! W; N0 F
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?/ X( H6 X/ n3 T" V: x& G

7 M2 i; |+ u+ y7 l3 _另外一个小建议,就是move,所有的move都可以这样; V0 d0 k: X& A5 o) k$ x! `) |( {
if not move() then debug end& k* N& B8 ~' N
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。" s$ X$ U* \5 O# @! t& j2 B, {
plant simulation中的free libraries有AGV模板,
4 }9 `8 k/ u) {- Y里面也有案例。
/ o* ~4 t5 {) Y1 }9 P9 u! D我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
4 P2 Z2 b3 r6 L6 I1 Q4 v' y! [: ?, F
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 7 z- i/ J4 J5 `& N9 z! ~' U

: j. m7 O& _  S4 \那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 2 V0 D6 F9 j' w  q& J% g
这是AGV_putin中arrive的method。
4 ^+ _% e" \. m4 V$ }. a3 W' Y. D' ^5 S5 A
当到达物料速度越高时,这个报警更多,

7 f: x$ J9 B6 m& [另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-19 03:17 , Processed in 0.027518 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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