设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6611|回复: 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'* _+ h+ h5 u8 N- y( T, E1 Q! e, ]- ~
*/
8 b* E0 l. I" @1 E+ Mis' _6 Y2 U* ?3 e- Y+ X- L
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
$ m- G$ |5 T, ado9 E0 x: x* f4 r; W6 n
        Lan := rootfolder.Internal.Tools.AOLlanguage;
: Z  y1 W( _) Q# V        if current = @.Destination -- else return+ L' p* [8 [: X9 Y/ d
        then( @+ D# G! y0 x4 R
                @.Destination := void;& U6 c  a4 I$ b: A, G
                if @.occupied then0 X3 X2 D( c; V  l$ w4 O6 S5 t
                        part := @.cont;- |7 Z9 w7 U1 h0 T
                        @.transpOrder := void;7 v+ U, x3 l1 q' ?2 S( c) C: O
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,) ^# H/ C5 ~" y3 e" [" a6 L
                                @,root.eventcontroller.simTime);% l) o, W' a; w' @
                        @.HasOrder := false;7 Q- K) I4 ]1 e) G; _% R3 `
                        @.DrivingHome := true;0 H+ \  T& H7 f- O* Y
                        rgManager.tryToStartTransOrder;- C; N, e. @& U9 J1 R, n- y
                        if @.Destination = void
+ y$ t+ ?/ z" L2 P2 _3 C                        then -- no transport order for vehicle @
; e5 h" |6 D* C  U                                @.Destination :=% e; x. A5 n, W$ z4 S; ^
                                rgManager.nearestFreeStation(@,track.~);
! l6 Q' f/ z5 C3 y: s                                newDirection(@);   ! Y& p. N, ^7 u
                                if @.Destination /= void then7 |% c- x1 b' I" g
                                        @.Destination.NumReservation :=
3 R4 X  j# |. o( v5 Y0 J& L5 t                                        @.Destination.NumReservation + 1;
  z3 {0 n6 e' x$ p                                end;
6 X& U( j" _4 t9 N                                @.CurrIcon := "drivingHome";
2 ^7 X: S: m) O+ P3 `- X7 W                                @.DrivingHome := true;/ U! L7 v8 @5 C0 V& }/ |! F) z1 D  e
                        end;
/ C5 D# g: Y  \9 V+ D                else -- the vehicle @ is empty, both vehicle and part are in the same dock station6 I( I0 r. P5 c3 h; g8 l- P
                        part := @.transpOrder;
( D+ `0 b# {9 r                        part.move(@);-- load part
0 z4 L9 R9 Q$ f) u                        @.CurrIcon := "load";
2 Q3 D) v2 w3 S5 w4 U9 t$ @& n1 v4 P                        GlobalDistObj := part.globDestination;
5 O+ \6 w; @$ g9 p. ^                        assignLObj := rgmanager.rgAssignL;; W. Q& i" v8 T- v
                        row := assignLObj.getRowNo(GlobalDistObj);
2 @  }/ z9 k& B' G+ s3 ~3 n                        if Row = -1 then -- since 70
- J# {8 @6 C8 P9 d                                if lan=1 then
8 E5 S2 @% N, g# a  j1 f: w                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
/ S0 g- f8 Y4 h8 o8 F- b                                                to_str("in der Andockstation: \"",?.~.name,"\""));, [  l% E1 P- g! V
                                else1 W  C: }% B- q  A- V+ x
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
! R- t$ ?& V! R% i/ \& j                                                to_str("in docking station: \"",?.~.name,"\""));                               
' u- b0 Q& F, q: ^9 B: v8 T                                end;+ {. o1 ]- P9 T& d, @
                        else! c1 P& R: q; v! I6 P# s- K
                                @.Destination := assignLObj[1,row];/ g4 b! V( I* Z  C, ?
                        end;                        : g" Z6 |1 H& X  `! }
                        newDirection(@);
. X! S- g6 y& w7 U                        @.HasOrder := true;
* T2 H) Z, q' M6 b0 A                end;8 e. u2 g. i/ r
        end;0 P/ E* ?8 p$ @6 [5 B8 p# n) M/ b
end;        -- of the method
% f3 `; u" v. Q4 C- H4 H# y6 ]
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
" }2 [' Y/ f5 w: k& g; B
' I% t# u2 @/ s6 T这是AGV_putin中arrive的method。
! z6 F6 X8 B. O% \) }
+ M% Q) h- z1 Y' R# C2 @0 K当到达物料速度越高时,这个报警更多,
) L4 R& Y/ {0 z" K可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
6 m& w! V) F6 Z" W0 A# G程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?7 A4 `. r) L4 c  h; Z% \
7 o# H* s/ T) I7 t7 \: c& E/ p8 G
另外一个小建议,就是move,所有的move都可以这样# }# C* r1 Z$ f. ^0 q+ i  ^
if not move() then debug end
1 t9 o( _2 m2 `; p2 V) P这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
4 D7 e# }' V, s0 p4 Aplant simulation中的free libraries有AGV模板,0 A8 B9 H0 E- J/ E. k
里面也有案例。3 @( w) P; L' W$ J# B8 L
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
/ ]' z+ s& f9 j5 l: K
7 q9 h5 Q1 k: [- M我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 % g2 U: \$ n7 N# h2 r4 Y0 ^
8 u1 _/ V" A  p: K' @. N5 O2 L/ L
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
2 L$ Z$ r1 x1 S0 O* h这是AGV_putin中arrive的method。
$ v$ e/ a  C0 L/ K1 P; I" I0 S% P( T& I" `4 r* V' G2 i. F. N3 v
当到达物料速度越高时,这个报警更多,
( E. e) ]: L! y
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-16 06:46 , Processed in 0.019697 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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