设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6937|回复: 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'
! Y1 T% a1 c5 p$ A& O3 I*/
" }5 B" k; A5 U/ Ois
1 G' j, d) p0 @% l        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
' i* ?0 A1 ~. S8 H  c/ ^do
) W: U% a* Y3 q* {: Z8 a        Lan := rootfolder.Internal.Tools.AOLlanguage;$ J9 b' n7 d) o+ O2 A1 g$ b
        if current = @.Destination -- else return
: u8 T) [. L) D* D        then1 G+ ?: [: K0 [! g, Z1 X
                @.Destination := void;/ ^5 z3 e9 U: x* J1 Z
                if @.occupied then
/ G4 E6 l- w6 m7 Z                        part := @.cont;$ ~7 c" Z" A1 l" @  {: X. S
                        @.transpOrder := void;" g5 r' T. K  _+ Z. a0 Z
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
, \1 b, j" c4 O. @" U$ ?                                @,root.eventcontroller.simTime);
$ J% i( F/ z2 h  B9 N4 i                        @.HasOrder := false;( p: }6 a7 N  j' i& T: b2 V1 I
                        @.DrivingHome := true;
9 W  U) O, s% t  i2 H2 M                        rgManager.tryToStartTransOrder;- \3 L9 U# U3 ~) Q
                        if @.Destination = void
. ?' c' w- z% K& Q: I5 ?5 [                        then -- no transport order for vehicle @; o$ Y' R$ V( j  H
                                @.Destination :=
( ]: L% X/ x7 V: y& H8 o                                rgManager.nearestFreeStation(@,track.~);
& M8 b3 h  B% |$ ]! l                                newDirection(@);   
$ g; ~: @" a% d0 Y+ x/ n                                if @.Destination /= void then0 u# V4 [+ G+ n6 H2 @. {4 Y
                                        @.Destination.NumReservation :=( p9 U% C- A1 A" T
                                        @.Destination.NumReservation + 1;& M" t/ T6 ?2 l+ k
                                end;
' z" ?# D8 _( a" g                                @.CurrIcon := "drivingHome";# D" I# T& f1 {
                                @.DrivingHome := true;2 \4 J8 w$ N; O5 W6 w
                        end;; i; ~+ w; N8 Y4 J. ]5 Z0 h
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
; r5 n. f% ^& V" ]                        part := @.transpOrder;4 U5 M6 E( g1 a4 N3 F$ @% F; f
                        part.move(@);-- load part% |0 w# |$ e) ]) d3 N- T9 h
                        @.CurrIcon := "load";
$ P0 g9 [, f( C1 b* a. N                        GlobalDistObj := part.globDestination;' r) ~# a: N; o; a$ A; t8 G
                        assignLObj := rgmanager.rgAssignL;8 a- F5 c( z8 g: n3 v6 l  c
                        row := assignLObj.getRowNo(GlobalDistObj);
" H& U( i3 l4 _* l! Q4 ~4 T6 ?                        if Row = -1 then -- since 70+ e" n3 y( U4 U5 Y$ N, s
                                if lan=1 then5 W0 A7 J$ \9 x0 o8 K  V
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),& ]( [. K0 V( o8 y9 k& k
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
. e5 }! I) u4 L8 ]; m                                else( n; [: L+ x, m! h* i
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
# I( q2 l* O& @; a5 U% m5 l                                                to_str("in docking station: \"",?.~.name,"\""));                                0 {7 V3 Z# B- g9 z" x0 a9 r) _
                                end;' F, O% o" h/ |: ]& u
                        else$ ?" M  Z% X' p: h) r" Q
                                @.Destination := assignLObj[1,row];( Z: \/ t, Q1 ^. U- w% M0 [( t
                        end;                       
/ j7 P' F) T3 v& z                        newDirection(@);
$ |6 T; Y! E2 Y; S0 Y/ A                        @.HasOrder := true;
+ ^. y; X. [; F: X- _$ _1 L4 u                end;
3 J/ ]; a. b( K1 Q        end;
/ z+ Q& Q& b9 cend;        -- of the method" h9 j. {& Y2 }
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
$ N( o5 P! L+ y( g& w
3 Q( \8 @% x1 _) `8 `这是AGV_putin中arrive的method。
* K9 p1 M% J8 k, f+ C# W  V3 e% ^( L
- s9 d1 a) g+ @& w2 z& @当到达物料速度越高时,这个报警更多,& o# u+ e" h2 B9 D- _
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。: \2 Z3 u2 r7 J! r
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
$ w6 O# ]& ?; P; S+ W' C2 Y% \
: \5 G5 k/ f. B) _另外一个小建议,就是move,所有的move都可以这样* o+ q0 [1 w3 |6 }; L
if not move() then debug end
- A' y: l' d2 e0 f& Z这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。8 Z6 D+ y$ D* v; o* v7 E
plant simulation中的free libraries有AGV模板,
$ V' @9 H6 x7 ~) z. E  u里面也有案例。
! m) A8 c+ L2 q- e+ E) q* L我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。( W; N* j: m$ K) O2 L
. p3 W. w4 b$ s; _
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
* ^6 S) I0 I4 c2 o
$ Q% c& M% |7 v: r1 f6 U' n& n那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
" w* r: O7 X& F/ c. X" e8 c这是AGV_putin中arrive的method。
7 i1 \8 Z7 p! r* t' c9 k* c' u
! b! d1 _+ k+ N7 p" i7 J当到达物料速度越高时,这个报警更多,
0 c9 p3 D9 N: {" ]) I
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-7 12:55 , Processed in 0.016282 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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