设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6912|回复: 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'7 {& h; Q8 O! W- ]8 [2 K8 Q8 e) i
*/2 E2 u( L! A4 X" ?
is( R, @4 a; f3 Y
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
# n/ Y3 g( r+ V+ s9 C& x, V4 ~. C0 U% ^do1 Q' f& X! X7 o9 Z: N: B4 M$ |
        Lan := rootfolder.Internal.Tools.AOLlanguage;. P6 |! Q; f3 [0 u
        if current = @.Destination -- else return. C+ V  U8 h1 T* w
        then
; u3 b2 J# t2 [1 y0 \                @.Destination := void;
9 d: T: |9 b# ?0 k                if @.occupied then) F, B, M8 t9 ~# l4 n
                        part := @.cont;
* u5 E  Z8 p2 i& P: c) _" S                        @.transpOrder := void;1 w9 K5 d6 M, f
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
5 `0 h5 [9 `6 P( R/ r. d. t                                @,root.eventcontroller.simTime);6 s8 _$ V: E4 e
                        @.HasOrder := false;3 d$ a. ]! D/ M8 T2 P3 }
                        @.DrivingHome := true;- G% }( x( J4 x7 a7 J* h7 X
                        rgManager.tryToStartTransOrder;
! E  _# l+ s/ b1 |. Y                        if @.Destination = void
, D, m& H# R% H' J- _% W                        then -- no transport order for vehicle @
/ M- J; T2 A6 W. c9 v! i                                @.Destination :=- L( U% e: h+ i8 t# a
                                rgManager.nearestFreeStation(@,track.~);7 \8 g$ s5 c  ^: C  v9 G; e( @
                                newDirection(@);   - l8 x. s' N: A
                                if @.Destination /= void then' _1 w6 D; I2 v% o$ A/ |" @. _/ F
                                        @.Destination.NumReservation :=+ p5 n, E  @4 r, ?
                                        @.Destination.NumReservation + 1;7 y4 O/ P# Z+ M( X
                                end;
2 r! i- p. x  d! X3 C  I# v! j                                @.CurrIcon := "drivingHome";
( g0 ]& Q/ A  _! \0 _9 w                                @.DrivingHome := true;. L% b% n; I( o# o2 ]
                        end;  ]4 ^9 l6 q' j' D& R% \
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station- e2 x5 L/ h) r. T+ r
                        part := @.transpOrder;, {$ k: k& @1 U4 n, z3 i5 u
                        part.move(@);-- load part
! c4 j% W. D7 \4 K                        @.CurrIcon := "load";" r' y$ @$ a% }% Q) W
                        GlobalDistObj := part.globDestination;* o8 Z8 E% Z7 o' f1 d
                        assignLObj := rgmanager.rgAssignL;
+ X! T+ _0 p3 i0 Q# x                        row := assignLObj.getRowNo(GlobalDistObj);
# x% c  p% X& {& v                        if Row = -1 then -- since 70
/ o# \7 ^/ j; Y3 o( c# \- ]* d                                if lan=1 then
) Q- W% l( q1 L5 e( M                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
( `' V. q1 c5 B1 y                                                to_str("in der Andockstation: \"",?.~.name,"\""));/ E" `& c, z- O2 Q
                                else7 n8 Y7 u/ a: A2 _, I# X$ M
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
) m1 {3 ?9 G. l4 r2 ^                                                to_str("in docking station: \"",?.~.name,"\""));                               
5 c( j" U$ H1 W- Y8 L                                end;
( ]( P  B, P' S0 k4 e$ {                        else
; X4 C$ G: N+ H                                @.Destination := assignLObj[1,row];8 m! h' p; V% x0 F$ F4 x9 [* L
                        end;                       
, k6 U' X: T- O  ~8 y6 H# }2 c                        newDirection(@);6 L" n- H8 C0 b. R" j) |" H9 A
                        @.HasOrder := true;$ l6 Z1 Z* j3 ]/ k( ?" x- I
                end;2 {/ I4 G1 ]) Y) a  a5 J3 L/ U  v
        end;8 H- _9 Z- s3 D5 o# S+ F
end;        -- of the method
3 ]7 X) B( P6 W( I
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
" d# T+ P3 [6 @& F# E4 x
7 \0 X6 g% j; k/ K# F0 [. o0 g这是AGV_putin中arrive的method。
" J, q' `& x- G) ^! v& h: L& y8 p( ^
当到达物料速度越高时,这个报警更多,
$ `; \2 B, B0 D+ a; `8 d5 p% X可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
4 D* ^6 F" v" \/ O* t程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
% a) b7 |# G) h
4 f( o7 m4 J2 b  {. r# N另外一个小建议,就是move,所有的move都可以这样3 A" [5 i3 d! \
if not move() then debug end
7 v) P+ l( u+ ?% _. u* s# F这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
* \: a) i8 w! I3 b( q6 l& {plant simulation中的free libraries有AGV模板,) ]) |- p/ H" L& V
里面也有案例。
+ ^+ J9 G! F  K- B  I我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
0 l7 t- Y' h; G* W% E8 u% Q: Q/ |& t: V. ^2 ~  N# a$ {/ O8 ~
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
4 H8 }! C# b- z
/ o3 b4 q  b5 I, _$ R, n那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
5 g5 Z7 E4 _' |4 |, M2 G这是AGV_putin中arrive的method。7 r. W" E, d1 |" k$ F( a3 Q$ U

9 N8 W& ~' B0 F6 v$ R1 ?, e) n6 q4 G当到达物料速度越高时,这个报警更多,
$ \! g9 B" L- J
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-6 11:43 , Processed in 0.016333 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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