设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8976|回复: 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'
2 S! x) ]: G$ n6 W" P  I# U*/
6 p& G9 l1 V0 k" U! Z8 x0 ris
1 J. w# l3 i, Q        part, GlobalDistObj, assignLObj:object;row,Lan:integer;- Q; I0 r  y4 Z* c: @
do
8 F8 s" n, i' L. _+ w2 `        Lan := rootfolder.Internal.Tools.AOLlanguage;
% t: l. }; w4 e$ x: r        if current = @.Destination -- else return0 h  F- P8 I. J$ F9 q  H' _
        then
+ N/ R7 r$ O* l7 l' K2 V                @.Destination := void;
  o- N9 Z$ o/ G8 F+ g                if @.occupied then
5 \% V5 Z2 R6 k& {                        part := @.cont;
) X/ F1 X: w/ p2 B8 `+ E                        @.transpOrder := void;/ k% H" Q0 \; ^0 @  v+ v4 n8 s3 w
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,$ F$ B  u& @! K
                                @,root.eventcontroller.simTime);
& ~" P1 E/ r4 h                        @.HasOrder := false;
- A  ]9 ?8 ^: D- ^                        @.DrivingHome := true;6 L. s1 b  W) X* j6 e
                        rgManager.tryToStartTransOrder;6 U% e2 k) O1 V2 K; a6 @
                        if @.Destination = void) _6 j. R; V8 n, V
                        then -- no transport order for vehicle @
7 e0 ^$ a9 ~# z+ L" t) ^! u& ?: n                                @.Destination :=
# T3 I. [; F; y0 m                                rgManager.nearestFreeStation(@,track.~);* L4 l* I2 Y8 [7 k& W8 H7 z
                                newDirection(@);   
4 y8 E) @1 t+ e" @  a, R                                if @.Destination /= void then
- \& V1 U$ u2 s& h                                        @.Destination.NumReservation :=
2 `3 Y+ H) ^7 U$ s" `9 D! G7 M, d& [0 j                                        @.Destination.NumReservation + 1;
# E* V( G6 T2 m, y6 Z# H$ ^                                end;
8 a. s4 f) p7 o9 i: J  ]  d                                @.CurrIcon := "drivingHome";6 w. F" `: `( V+ V6 x$ m' R# c4 Q
                                @.DrivingHome := true;. w+ i/ X* q* ?
                        end;
' _9 K4 f5 ?1 W) Y                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
- V! {7 d$ H) ~! q8 P6 b  {                        part := @.transpOrder;
) D# F6 |5 Z  I, }( I3 J& ?0 [& B+ `                        part.move(@);-- load part
. B' l; S: M+ l: i$ \6 U                        @.CurrIcon := "load";
& K: n: }& {. ~% B2 p4 ?                        GlobalDistObj := part.globDestination;
9 F# ?' X; ?8 c8 O. h9 e                        assignLObj := rgmanager.rgAssignL;% U* f0 M* d( n
                        row := assignLObj.getRowNo(GlobalDistObj);& R# M4 X$ P5 w2 y( F. }4 z
                        if Row = -1 then -- since 70
: H( s; v& j( J/ P                                if lan=1 then# ?& x; L) f& D3 s
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),8 D4 y; P/ w7 \" p% Z
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
8 X  M* D& d1 P% C3 B; C; p                                else8 J: J, T  v( Q: l3 b; F+ K
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
% }* X/ ?/ b4 i* f$ v% |7 v                                                to_str("in docking station: \"",?.~.name,"\""));                               
6 a% F1 [- A) O4 Q                                end;
! y0 a7 |: m. ?0 e9 _' X                        else3 V" p* Q8 I: \; u! p1 g
                                @.Destination := assignLObj[1,row];
# M9 \2 r. x# e* p                        end;                        * H+ l$ a" r) E
                        newDirection(@);
2 H) h( K) h9 _                        @.HasOrder := true;- k7 I/ O* g4 A; ~& q9 J
                end;
/ n. Q! J6 i- Q, Y0 }3 \& d        end;' Z& ^. o9 [+ R4 h$ Y8 h: P
end;        -- of the method
  e9 y6 @  s! H# n  z
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 $ E; G  F+ P3 T4 A8 i) w

( R7 O7 e( ^  A. D9 a这是AGV_putin中arrive的method。
) {8 @/ h/ _: i( o( w; _. M+ r6 ~# m/ o* R+ ]
当到达物料速度越高时,这个报警更多,
# W2 ]4 h. b% T% s3 J可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
7 V% m1 k) ?2 W9 X程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?' Z0 A0 {) q1 V# s4 O1 G

8 \& P5 @4 `  l* s& b另外一个小建议,就是move,所有的move都可以这样. d  w7 q; }. I& G2 ^$ S
if not move() then debug end
9 L: f1 Z2 x0 S2 C' D这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
: e( E7 \4 {' m" Uplant simulation中的free libraries有AGV模板,
: k; m5 f$ B3 C4 b. s) g8 M里面也有案例。
$ h  L% p5 z& V& C我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。- S% k( s# k2 Z! g" f# n
1 w: X1 P& m( j7 p; N
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 & A- L/ }7 P& F- m( ]1 x

5 b) }5 q% ~$ d- D' Y那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ' _/ B: Z5 o, e0 d6 y+ L' |' k( T% I
这是AGV_putin中arrive的method。
  z+ `  A( r$ ]; N( F# J; O
0 Y! H! s, c5 w/ _- p. x当到达物料速度越高时,这个报警更多,
! ]2 T1 l6 _+ f4 a- }# n
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-7 00:50 , Processed in 0.014761 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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