设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9367|回复: 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'8 `) z$ S3 E' x7 z0 r9 F$ b
*// u; ]- G6 q  ]
is6 I9 o( A  }8 ?
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;6 c1 _9 t% x1 N6 w
do
% I+ U0 P) B# ]; N8 i        Lan := rootfolder.Internal.Tools.AOLlanguage;, a- y2 g! Z; \7 e' |9 L
        if current = @.Destination -- else return
1 s  P* s1 S0 \        then- D2 `- E( Z+ V4 A
                @.Destination := void;- ^% {, y$ n6 f% L( H- q# ?
                if @.occupied then  q" J0 K, E) n1 a, F) L
                        part := @.cont;. `& i! }: f. `% {1 H- `5 s3 B. ~
                        @.transpOrder := void;
5 s; k. V# x! s3 h* ^                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,5 E3 j8 T/ C* W8 f8 `
                                @,root.eventcontroller.simTime);0 j5 H9 q( D! K( F4 i8 s
                        @.HasOrder := false;* k! R3 ~# e: W3 b( P$ N6 M) }
                        @.DrivingHome := true;
9 M: A8 T! M- K% I* d2 ~8 `6 M# t                        rgManager.tryToStartTransOrder;
2 k- T: @- S2 r7 Q8 X& b                        if @.Destination = void
6 @: n$ I  V4 y0 p# |( e                        then -- no transport order for vehicle @
) X( T' \/ \9 q# M4 N: x                                @.Destination :=
- N- h$ _/ l1 i; ?                                rgManager.nearestFreeStation(@,track.~);) s, ?% @. i  o! B7 I: x
                                newDirection(@);   
4 H; v1 }5 o, `                                if @.Destination /= void then9 `3 r! F$ [- g1 W$ ]( `( ]' ^& b
                                        @.Destination.NumReservation :=
: W5 [2 t* o8 R/ H                                        @.Destination.NumReservation + 1;0 m$ I$ y. @' V  X8 [
                                end;
  B2 X" G/ ]. P" c; h9 ?: c; l                                @.CurrIcon := "drivingHome";
$ m2 ~) f$ Q' m" Q/ ^( J5 A                                @.DrivingHome := true;. r1 x  u7 N$ c1 p4 m6 {2 C$ p2 J5 R
                        end;+ h6 F( J( q6 D* [" V
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
3 h$ h% l- S: G! H, G                        part := @.transpOrder;
) W& h0 \6 V+ q$ G1 W                        part.move(@);-- load part
& J* Z/ A6 G5 K; c0 _! G' _# w                        @.CurrIcon := "load";1 s2 `; A, M; Y" G
                        GlobalDistObj := part.globDestination;
" V* p$ E6 }* }: R. q0 F* O! K  v                        assignLObj := rgmanager.rgAssignL;4 w' o0 e1 O8 N; T5 j
                        row := assignLObj.getRowNo(GlobalDistObj);, [2 \# J0 A% o
                        if Row = -1 then -- since 70# K3 {! ~( B2 B/ R6 H6 F& u
                                if lan=1 then
# a6 N& D2 l% I# \2 Z; y: \& I                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),$ a5 k, d% v. o5 p9 [& ~
                                                to_str("in der Andockstation: \"",?.~.name,"\""));0 D+ M8 j1 J6 E' ^$ o" D) T: ~
                                else
- ~/ r1 C; x* o" T                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
$ O+ C: a" F: S& {: i$ H6 \* H                                                to_str("in docking station: \"",?.~.name,"\""));                                , X+ Y" h- [: ?4 u$ ~9 L
                                end;
. S9 S. O+ Q/ b  e                        else$ N$ H0 q# A/ O& K+ o  R
                                @.Destination := assignLObj[1,row];
9 |5 }' @( g9 J6 `: {1 u' [                        end;                       
, W# q, I4 V4 g. Z7 E5 [9 m4 o. E                        newDirection(@);! X+ H/ N) N9 x1 ?( A4 i
                        @.HasOrder := true;! d' q, c: T2 r, H
                end;: r6 f3 D  z; O8 C# K( ?) l
        end;& G9 r. t$ z9 {4 w* c- O
end;        -- of the method( U5 U! g. u; Q+ s$ ^! x. S
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 & h# H6 K' f2 P( S+ k

% N  ]( C( H2 D  o% |这是AGV_putin中arrive的method。
  y+ A& I  f% w7 k
  @$ R  Q  O( i# y当到达物料速度越高时,这个报警更多,
6 |( W3 i: ]5 A% a1 {$ w可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
3 I+ G; n0 P+ U' u9 Z7 W% C5 L程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?; v# X. h, r- Z. \+ i! p0 X

; [: R1 ?. R! E. j8 O! c另外一个小建议,就是move,所有的move都可以这样
( N- {) R1 S9 F; e, x& Qif not move() then debug end
6 l! x0 {, Y/ U$ `1 Y这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。7 L5 v2 X/ a/ f- l
plant simulation中的free libraries有AGV模板,
* S( \* j* [' S+ x里面也有案例。% F- q2 S) G. U; Q2 c6 Z4 X% V
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
9 a. _9 o  V1 O* i1 T  ^( H
- Y% P$ y, F$ ?我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
# ^) d* E2 z7 e7 M  J' `; g$ @7 l3 r: o1 v* V$ Q- ~
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
' ?3 O  o  A6 V6 D; \) X" C' f. _这是AGV_putin中arrive的method。
& ]1 g" ~, m2 o7 p9 Z; q
1 }. x5 I. V  {& q% h5 T当到达物料速度越高时,这个报警更多,

+ @3 z9 f2 x0 a4 q: u另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-28 05:53 , Processed in 0.016679 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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