设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6238|回复: 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'
3 j3 c; l1 x/ ]1 G& G*/
- |& I! ]5 G" ^/ g$ G% Q0 zis3 ^# L6 X/ F7 S
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
5 ?1 n' f7 U. d7 Ddo1 X" u7 e$ R/ v% G7 f
        Lan := rootfolder.Internal.Tools.AOLlanguage;
# R. \; K  N. l( ?+ _4 q        if current = @.Destination -- else return
$ `3 P) u. g# X; d, V! v$ _% }        then
) q& Q6 \  O; t+ B: d* O8 I                @.Destination := void;( m$ J* h% m( C3 [& G- K
                if @.occupied then& z9 U0 c9 Z0 K6 r
                        part := @.cont;
4 Z6 |0 S0 ^# [( t) ~. Q+ i7 f                        @.transpOrder := void;' H4 E3 C+ u& x! l- Q
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,- t2 D5 A. L) X& p; h, K
                                @,root.eventcontroller.simTime);. Q, H) x! d3 f! ]% T: E7 J+ U- j' x7 ]
                        @.HasOrder := false;8 ?% n$ I' ^" [7 o/ e' z
                        @.DrivingHome := true;: V3 `/ C; N& E3 N
                        rgManager.tryToStartTransOrder;
. t! N8 A+ D; [' q                        if @.Destination = void
* q2 q/ M9 ~. J$ d- Y+ k' I                        then -- no transport order for vehicle @
* v1 Y, _1 i& @  g+ d  i                                @.Destination :=
9 ~* L$ d& r7 J: U* t7 f: s1 [                                rgManager.nearestFreeStation(@,track.~);
; h# U& E8 L( n6 q                                newDirection(@);   
! |8 n7 L! z4 x6 N9 d: q                                if @.Destination /= void then
3 x' w5 Q- j) i: [" T                                        @.Destination.NumReservation :=. \: V) R0 D4 K! H: d7 Q
                                        @.Destination.NumReservation + 1;
/ U6 ~2 F: V* @2 ?7 d                                end;
' \0 _% N6 n" a1 m" B- A6 ~                                @.CurrIcon := "drivingHome";
+ y7 r  V; g, o0 D) p                                @.DrivingHome := true;8 t1 W, f6 s' U  i; y/ ?. j+ N
                        end;
2 P( `8 S/ a. P) G                else -- the vehicle @ is empty, both vehicle and part are in the same dock station9 c( k1 d1 y) R
                        part := @.transpOrder;
7 [: G" \* R' u0 E3 c- X                        part.move(@);-- load part2 P1 }# {/ S; I9 p
                        @.CurrIcon := "load";
0 p$ P9 f; t6 l6 j                        GlobalDistObj := part.globDestination;
% u- D4 v9 O0 ]                        assignLObj := rgmanager.rgAssignL;
& k$ B1 R+ i1 X, p- r                        row := assignLObj.getRowNo(GlobalDistObj);* [% L3 b1 z! {" |5 u
                        if Row = -1 then -- since 70' ?: S( \8 b- \
                                if lan=1 then
* D8 i$ Z3 s9 W9 A/ J# s* Z6 _, n                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),, w6 x( u* r9 G) H0 N/ R4 \
                                                to_str("in der Andockstation: \"",?.~.name,"\""));* Z5 [7 A! ~$ F9 P
                                else0 x7 f' W# ~& T, F* w5 C0 l! x2 k! Z
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),) V9 D# b% n' R, q8 ]: s* E
                                                to_str("in docking station: \"",?.~.name,"\""));                               
0 j$ u7 M0 ?+ p5 e                                end;/ t* p! S# y( @) b  G: n
                        else1 O. {* N! {- l) v' b% Q; M1 A
                                @.Destination := assignLObj[1,row];
' @# ~  ?: j* T; p* a& b: Q3 `; O( L                        end;                       
% L# s( [4 U' o8 \9 k                        newDirection(@);
) Y/ D8 _  v; Y                        @.HasOrder := true;
! Q. u" E+ B5 q5 ~                end;! ^+ r+ n7 ]5 \% n! n( d7 }: @
        end;
5 n9 N& o+ Q" N3 U6 P$ m: \8 z+ Mend;        -- of the method
0 U* h% _: p( E( c' t8 T8 b
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 9 z- s9 [8 U/ H( A( T! E

* O: Y. A+ ]% C/ s; M: |+ ?这是AGV_putin中arrive的method。# t% r2 @; D4 @* i3 X
6 N& r/ |% \! c- q- |( j5 C! G
当到达物料速度越高时,这个报警更多,
' v! a0 h8 V. F可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
% Q. R1 P. Y7 v程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
. X+ B8 P  y" f! a8 a* S) o9 k# u) S( [. C  P" U8 d* y
另外一个小建议,就是move,所有的move都可以这样" p  N& ]5 j2 V) ?
if not move() then debug end/ }4 _7 }; K: ^3 k& }/ h: N3 I
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。% p2 {7 O+ G; s" h, l+ v! ~$ ?
plant simulation中的free libraries有AGV模板,9 j3 R! |# L1 A6 E8 Z$ B. \
里面也有案例。* R7 \8 o( {% ~" z1 M  |
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
; c9 y- k* f- o" Y) E/ W  `9 w5 f
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
0 a. b; H! Z1 C# M! g/ f8 l$ r5 T* X- W* H" S2 w: e
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
& O) |* T; h: l这是AGV_putin中arrive的method。( V2 }3 Q' A1 v: ~* n

: j; ^$ r- y' w1 m当到达物料速度越高时,这个报警更多,

6 q' Q! ]* U9 Z. P2 A另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-26 14:02 , Processed in 0.018765 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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