设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9048|回复: 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'0 y- l( s: R1 A" h1 |+ W
*/
. h& q1 ^1 q9 O7 x% D, Qis1 P0 u7 c9 v3 @3 L+ g1 c
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
2 q5 j0 J  Y+ b+ I( _! udo- j' F& O9 E# _6 j  V
        Lan := rootfolder.Internal.Tools.AOLlanguage;( X1 r: @1 J. s( c4 K
        if current = @.Destination -- else return
- u1 t' M- z% Z+ j: a        then
  w6 [7 t$ d1 \' q- b5 k                @.Destination := void;, t& ]$ J0 @& p
                if @.occupied then
& A1 z' o/ U5 U                        part := @.cont;
2 W7 p2 d" _  A# \: @: L                        @.transpOrder := void;
- o" m6 v! _* x" B' y) N                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,4 `. h4 ?; y. G, y. o4 D
                                @,root.eventcontroller.simTime);
2 Q1 ~" S; F: f" s                        @.HasOrder := false;
0 Q% B* N& c3 _, ]                        @.DrivingHome := true;" c$ S7 F+ v4 U# }1 i; g
                        rgManager.tryToStartTransOrder;* ?! F  |4 h) l* U# |* m
                        if @.Destination = void/ r0 X) s* H# E  P0 U* J
                        then -- no transport order for vehicle @* Q2 d6 w, _# _$ B8 ~% g# r
                                @.Destination :=
; o+ A6 h# f% V1 Q; U: @" x6 M. z                                rgManager.nearestFreeStation(@,track.~);
5 a) n0 O5 ~: X: S' x7 x                                newDirection(@);   
) T+ P2 [7 c0 G$ ~                                if @.Destination /= void then- {+ [! y) f9 X
                                        @.Destination.NumReservation :=
9 n8 |; ]1 z- I' i1 ^* C; o% w3 }                                        @.Destination.NumReservation + 1;
" k6 o1 X; W9 k5 R6 u/ S1 F                                end;
  N6 i4 m' m# \+ U9 ^* r" C1 z( l1 g                                @.CurrIcon := "drivingHome";4 o  T8 ~& I+ B+ v, g; l. w9 f! X
                                @.DrivingHome := true;( r6 L  v3 z. Y1 n
                        end;  V0 o$ H6 f. f, Q1 }# h$ @
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
9 x* v. W. N# C9 R5 ?* H; w8 E                        part := @.transpOrder;" L0 p1 @8 Z" }1 a
                        part.move(@);-- load part
6 N) R4 g& b2 J: Q0 x; ~/ f                        @.CurrIcon := "load";; l! @7 Y. n) \7 P: s; n
                        GlobalDistObj := part.globDestination;2 P( j- A4 J( x5 e2 B3 Y
                        assignLObj := rgmanager.rgAssignL;4 J# O- U1 b4 @4 j
                        row := assignLObj.getRowNo(GlobalDistObj);" L& j8 p- X5 u& q
                        if Row = -1 then -- since 70
# N. ?- Y9 G" B( @/ i- W                                if lan=1 then
4 b2 f" r, o7 i; l                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
( \7 a) E/ ^5 r' m                                                to_str("in der Andockstation: \"",?.~.name,"\""));: w  [9 D/ ~8 R
                                else
4 @4 ]+ s7 Z4 u8 }. n                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),5 n. C8 L/ e. M- w4 q
                                                to_str("in docking station: \"",?.~.name,"\""));                                  N& \2 O/ C. e+ |
                                end;
9 j( y9 {0 j* I0 I0 B/ Q! N                        else% u' Y) R0 Q& Z7 B" [
                                @.Destination := assignLObj[1,row];+ U. w6 V. o+ P5 c9 ?0 z4 y
                        end;                        & g1 p: m  R4 F5 f/ f$ c$ c
                        newDirection(@);$ M; f2 f% {0 e/ [! \8 v6 C
                        @.HasOrder := true;
  G! [8 ~5 f2 {                end;
% `) x1 w0 ^" M' N# }. H        end;/ {! Z. _' ~; `* t
end;        -- of the method
7 A0 o; h' v! m
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
  \) H5 V8 Q3 j4 X6 z8 |2 ^3 u% ?  z: m. E* e. a
这是AGV_putin中arrive的method。
3 |- E1 _$ [: \1 V9 `; C( e1 R! Z" I5 E( G
当到达物料速度越高时,这个报警更多,2 b5 C/ V# G# o6 u2 J; H/ G! e# `6 q
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。; h: `1 v6 |2 h; c3 u$ ?$ T3 m4 r
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?" |5 E8 W5 [, G+ b/ m6 O

( U5 ~* h# Z- {6 o; k+ L另外一个小建议,就是move,所有的move都可以这样
- l. Y0 \2 m+ I" T. [3 B: O5 Jif not move() then debug end3 y6 j2 \4 e) K2 B
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。+ c. N/ E4 p# h0 t  L. @
plant simulation中的free libraries有AGV模板,& U0 \! w' t$ A8 a6 d3 N$ i
里面也有案例。+ n! D" m& V% s, c2 \% Y
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。! d1 H3 K6 i. W3 b0 ?
$ p! P) N. W1 e/ F) b
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 6 [. w9 I; \+ D8 j4 J

% Q  L: I* H. c: g8 r" K那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
1 Z: Q% B: [4 p4 B  P这是AGV_putin中arrive的method。
7 a7 y: j! m6 n  O* k* }8 a$ c) ~* K& A. J/ z
当到达物料速度越高时,这个报警更多,
: u2 }3 S8 B' k3 p
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-10 16:22 , Processed in 0.016977 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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