设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10180|回复: 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'
, J/ d$ i( l! s* r. Z% u*/
& ?0 x5 g. g9 h: L/ ~5 f' kis! C) k3 N" k# q  _; @- z
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;3 R3 x8 ?# N) O3 w' h; S2 B. U
do
. h* T" S7 o( m9 V8 U( n+ @: s0 l        Lan := rootfolder.Internal.Tools.AOLlanguage;
0 w* Y6 ~2 |, h$ b5 _7 J# P  G        if current = @.Destination -- else return' X! C; O2 U0 r; Y& ^% q
        then2 `  |) M& l$ _6 K% |0 H
                @.Destination := void;8 w$ y/ N4 ?& ?# N- T/ M2 y& y
                if @.occupied then! i0 P' i. q4 |( O, t  F
                        part := @.cont;
' B3 F* z+ L8 X6 @/ q; d& x) X# d; {                        @.transpOrder := void;
1 A% C8 c* {) @& O6 o; I7 u                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
* b5 ~) H0 i- _, P2 @$ h" p! @                                @,root.eventcontroller.simTime);  k% _& x5 m& ^/ A
                        @.HasOrder := false;1 Q. U9 q2 D: \; g" O* i  X$ [+ y
                        @.DrivingHome := true;: r6 \- y. B  y! `  m- a
                        rgManager.tryToStartTransOrder;& W' U- c9 X, g, b( Y/ `! Y. i
                        if @.Destination = void3 ~# A/ S6 w4 I0 P. x0 S# H
                        then -- no transport order for vehicle @
8 k& Q5 Q( a) }7 }9 G  P2 k                                @.Destination :=
7 D& j) ], y1 D, F2 J; o                                rgManager.nearestFreeStation(@,track.~);! M9 [/ \! x8 d; `. q0 D  G
                                newDirection(@);   
0 d# y  w; B5 a5 ~) X                                if @.Destination /= void then" d) D$ N9 P# i; N# F2 h& `7 T3 A
                                        @.Destination.NumReservation :=
( I$ [5 `5 Z; ]                                        @.Destination.NumReservation + 1;" V7 L" l/ Q( ~# M
                                end;
9 G& G1 J0 Y6 [/ Z                                @.CurrIcon := "drivingHome";
- U! Y0 [/ t- ]* a0 k9 u& J$ q3 D. C                                @.DrivingHome := true;
0 @, n9 |0 a. H- W$ y0 L# M                        end;1 X9 R2 W0 p' o, n5 k
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station0 D! E0 s; b" S5 h! F6 |
                        part := @.transpOrder;8 c4 z( v9 X! o: z' `9 {
                        part.move(@);-- load part
; W+ T$ z' C! z+ Y% K! e3 ]                        @.CurrIcon := "load";
: h6 Q% g/ S: j- H2 L/ ^- L! W                        GlobalDistObj := part.globDestination;4 m; C. j4 k3 Q" f
                        assignLObj := rgmanager.rgAssignL;
# \  e. a& s9 K( Q, `                        row := assignLObj.getRowNo(GlobalDistObj);& i: [; h# P. |3 s# E  C
                        if Row = -1 then -- since 70
# u; v$ y. U* c( s  F                                if lan=1 then- o$ L$ t+ M, ]+ R8 A$ E3 j
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),0 V( O/ l! {) o1 n7 x( j6 F
                                                to_str("in der Andockstation: \"",?.~.name,"\""));8 }6 y7 m, U% l3 X
                                else& s" C- J/ z" v( S
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),8 ~7 X; |4 M1 f4 M" H/ u+ o
                                                to_str("in docking station: \"",?.~.name,"\""));                                ' J) M5 y- X, c# O( |& ~
                                end;
# s1 R( G; Y* K4 V                        else( b8 `! j  j" n( ^5 X
                                @.Destination := assignLObj[1,row];
3 b, J( G* {! n                        end;                        % j. T* h1 ]0 ]7 k- S( R) }9 i
                        newDirection(@);3 Z7 b5 g. F8 S7 I/ C4 U  v; l6 o* n
                        @.HasOrder := true;
& V) }; M8 N; c4 x% P6 Q                end;/ E* B! k  U7 ]5 G3 _# T
        end;
, B3 H0 T3 h( k6 T; L9 qend;        -- of the method
% ?* M6 k& _( M# x+ {5 Z! D
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 3 Y5 m9 p8 ^. l; T0 O& x; D

" [6 B# \5 G2 }; G, U这是AGV_putin中arrive的method。  N) I5 s' `) k& [* c1 c" @

, a$ Q9 s8 W7 V7 L当到达物料速度越高时,这个报警更多,
) [4 V0 V( [& ?+ m2 l% v可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。# l5 m1 Z0 S% L! E; E6 S9 J
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?/ g' H2 u) @, [: k) Y9 b
7 D& C# g4 ]6 F( t6 J7 G+ h- U
另外一个小建议,就是move,所有的move都可以这样
6 \) U: y, l* Uif not move() then debug end3 |+ f" G; f9 Q& \1 H+ u5 @: D
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
# L7 o& S0 g: h0 }* lplant simulation中的free libraries有AGV模板,/ z' C+ _! f0 K5 q! p' h
里面也有案例。6 p1 _2 p# P/ f$ w: n
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。6 n, M. _4 I8 T5 A( H5 q

* Z$ d' `5 l( x/ E2 u& g我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
7 O; s  t- q" b/ z7 C' P
4 h$ h+ u4 J$ Y7 K+ D, Z; I0 l6 q& M那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 9 C. H1 [. ~, u
这是AGV_putin中arrive的method。. W! q3 H* _$ A" ?

# H! ~3 ~: n& K) w- @当到达物料速度越高时,这个报警更多,
8 u$ R. `3 i: S, h, x7 F9 F, O' y! h
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-18 17:09 , Processed in 0.027026 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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