设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7503|回复: 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'4 o( ?5 z5 `1 J1 N1 `1 `
*/7 Z( E' C$ b- H7 a) t0 [( f
is
. \( @7 Q/ i; @' f        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
4 F* o5 e/ }" D* \% b6 ado
5 w' O# L7 W" ?+ |# _; P( |2 r6 I        Lan := rootfolder.Internal.Tools.AOLlanguage;
, R; F0 l4 K* Y5 |* j        if current = @.Destination -- else return
- v/ E7 W1 {3 q9 S        then; q4 J$ Z( A8 N% Y5 |2 q
                @.Destination := void;
1 R. g  O6 a$ t6 q% W3 Y                if @.occupied then
% F8 z' a* g% x* y, b- U                        part := @.cont;5 J& S1 |+ A; H
                        @.transpOrder := void;0 Z2 L- E# L! [+ O1 x5 N3 r
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
* y5 l% ~) F$ W7 i: t7 M  D& }                                @,root.eventcontroller.simTime);# }" q4 {- j6 l8 g/ \4 q9 H7 h0 ~
                        @.HasOrder := false;8 k- B6 N& c1 @, b
                        @.DrivingHome := true;
3 t$ P: x& x5 R                        rgManager.tryToStartTransOrder;
* o. ?! q; b0 K8 D                        if @.Destination = void) v! X' v2 R6 [" D% G' d
                        then -- no transport order for vehicle @
" q1 z; E- j# \% C# ?3 z                                @.Destination :=
0 z+ s7 U! U- P                                rgManager.nearestFreeStation(@,track.~);4 L9 Y/ N; {" }) i/ C
                                newDirection(@);   ' b+ r  n1 i- A2 W# T/ O, t% A
                                if @.Destination /= void then
' s) S$ k+ d( R* N- r                                        @.Destination.NumReservation :=
+ `6 r& l- n! X                                        @.Destination.NumReservation + 1;7 c3 ]7 F; S% k9 P) m, d
                                end;  S2 \3 G: \' c$ W' Z/ h( L
                                @.CurrIcon := "drivingHome";: a2 {0 R( w, r3 H) }7 Z1 H; D
                                @.DrivingHome := true;: f" \: K4 P2 m; i3 H* ]5 E3 e7 R
                        end;
7 n. i" h6 X3 f8 r                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
& |: }! J7 e) d% M# b                        part := @.transpOrder;, U$ k/ L; g4 H9 {) G
                        part.move(@);-- load part! A1 w6 _- [* |  U1 \8 h8 |
                        @.CurrIcon := "load";
' X, C: s4 V9 B; _/ [/ H& y, t' K; W                        GlobalDistObj := part.globDestination;4 z8 T* Q) e6 u; T
                        assignLObj := rgmanager.rgAssignL;& @; P( M1 ]+ N
                        row := assignLObj.getRowNo(GlobalDistObj);
9 L; |7 N/ U& O, H/ t3 L                        if Row = -1 then -- since 70! O0 D, o# R4 B* ?6 J6 I1 I
                                if lan=1 then
9 j5 z+ l9 G/ w0 D- t                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),9 Z0 ?, K9 X9 h$ Y2 O; v
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
% u7 l3 D$ y9 L$ x                                else2 h; ]3 _+ E+ y$ M
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),8 }  v9 I( A5 Y6 M6 I7 o: t& s
                                                to_str("in docking station: \"",?.~.name,"\""));                               
5 N! ]! `( k$ Z0 C; D1 b& m                                end;. D/ E9 D. a' ]8 [% T
                        else4 s: n: Q. q6 i7 H% O, g
                                @.Destination := assignLObj[1,row];% a8 A/ D! A. O8 C; K( i
                        end;                        ( d; H4 W9 z2 Z9 L4 \  f
                        newDirection(@);6 U9 W# i7 f8 ]% a+ f, i
                        @.HasOrder := true;* l9 V' z* R2 q6 i" X/ n' ^2 _
                end;: A& s" t) ^% {" t# F6 P
        end;, v9 u: q' p( ]9 c* l
end;        -- of the method
8 z% w: v3 I: }, C! k3 V* [
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
% Z7 ~. ?2 M/ U6 f5 y9 t, p7 d- N; x% {! ?
这是AGV_putin中arrive的method。0 X3 {. Y/ c4 Z7 D  H0 F

  Q+ K4 K' K* n( S- F& j; `当到达物料速度越高时,这个报警更多,& G# k/ {( j6 a, j+ h: g( ^1 J! D
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
( u& ~2 q! j; w& ^$ R, m( \程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?5 h+ I6 P, c* {2 `

8 L; e) ~% a3 ~2 Y另外一个小建议,就是move,所有的move都可以这样+ r, p+ G3 D1 n4 O- u9 ~$ x
if not move() then debug end
7 g+ ^6 T- I9 A3 B# j9 u9 G2 y这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。% w* l% Y) l" B* w8 |
plant simulation中的free libraries有AGV模板,
# p/ Q4 m. h4 q* Z里面也有案例。2 H6 M' W9 r" \
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。, k# ~+ k' `1 i( D9 I
: J" V- x+ u- o$ q
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 5 w" @1 n3 d) _# O4 @2 I9 ~+ ~
5 s# _: o  L! a# ?1 I- Q
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
9 s3 s9 t% G( O! e1 ?这是AGV_putin中arrive的method。
: s( P  e3 J* r4 V9 H/ w7 {
, D, p( a- T1 ^8 G0 l( W' S& G当到达物料速度越高时,这个报警更多,
* o: h1 K5 R' W6 l: D
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-15 05:33 , Processed in 0.017996 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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