设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7774|回复: 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') [/ X" l: o- k8 |  Q+ G
*/6 _( m3 ?! d4 [2 K: F: I7 [0 B
is8 ^9 X7 |2 M& P- a: w# ?6 l
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;  l0 \4 e0 C; i5 `2 c* l- J# B' y
do( z+ w4 T% V) V
        Lan := rootfolder.Internal.Tools.AOLlanguage;
$ X  f6 _" l) S" B& i8 Q        if current = @.Destination -- else return
3 t( [2 s0 r) F9 x        then) k) i3 U& \7 m) z6 n7 C2 D+ e  _
                @.Destination := void;0 Y! r( t6 v" ?/ c2 L/ f5 |
                if @.occupied then
/ m8 i3 w; g/ H                        part := @.cont;
* B3 U* `4 }1 Y, P                        @.transpOrder := void;
# e- y  Q$ N  @                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,2 J3 c% s, c( W1 J; p
                                @,root.eventcontroller.simTime);
5 S4 L5 {3 P" ]                        @.HasOrder := false;# Q+ Q7 A9 d  T( A$ y8 q& s. o/ ]
                        @.DrivingHome := true;3 [  Z0 k6 {. ]
                        rgManager.tryToStartTransOrder;% g! G2 d& t: w! `2 ]* A
                        if @.Destination = void4 H" v$ q- ]0 r
                        then -- no transport order for vehicle @" e! p0 T% i. o; {# j$ F, j
                                @.Destination :=
4 Y1 j0 ~+ M) n, X                                rgManager.nearestFreeStation(@,track.~);/ A* L% W/ N/ |2 v
                                newDirection(@);   
; b; U) b; I+ j" B5 h. ^5 k: J                                if @.Destination /= void then
6 o& x/ i' b. c- f' j; T                                        @.Destination.NumReservation :=
& q4 G2 M1 P, M( C                                        @.Destination.NumReservation + 1;- I# C2 w8 F. U% c! S8 M# y
                                end;% G9 g& ]- K, s% b/ n
                                @.CurrIcon := "drivingHome";- g; _1 s) |, @* h' P5 p0 b3 Z/ l
                                @.DrivingHome := true;
0 K0 s$ x7 h9 L4 k/ E5 F1 e                        end;
" N8 \1 m' f4 v* b; V% G  g) ^; N                else -- the vehicle @ is empty, both vehicle and part are in the same dock station6 h# `9 _5 B% P; i# V8 H/ I
                        part := @.transpOrder;
# D6 a+ m# l% x: C                        part.move(@);-- load part: K) B1 s0 W* j, F3 d7 q
                        @.CurrIcon := "load";* Z9 _, \& Z$ u% i
                        GlobalDistObj := part.globDestination;
5 c& ^. z2 D, D                        assignLObj := rgmanager.rgAssignL;7 F( N7 n: `& l! B' O2 n% i
                        row := assignLObj.getRowNo(GlobalDistObj);
8 ?% F0 S; z9 u- i- ], c                        if Row = -1 then -- since 70* i0 s+ h2 D; }1 e
                                if lan=1 then
3 e0 W; @, q6 l$ K+ \                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
9 e- Q7 }) N5 p: i; D$ T, J+ i                                                to_str("in der Andockstation: \"",?.~.name,"\""));
0 ?9 U3 ?6 k) p9 G) C: P                                else
2 w% ]  c8 S4 T8 ^7 V                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
8 J8 R; N+ U6 k" U. m9 a: W5 @! u* B                                                to_str("in docking station: \"",?.~.name,"\""));                                * r$ c6 F0 Q, r6 B0 M
                                end;
- {! e5 _$ i: L# g4 G8 V0 K                        else9 [3 k; _- a' |. c
                                @.Destination := assignLObj[1,row];
& ?# \1 `9 r# \: B0 e: o                        end;                       
" i8 C7 N1 S& i6 k8 {6 z! J                        newDirection(@);
- J' t9 R9 w" k0 I' m- f; V( {" B8 E                        @.HasOrder := true;
" i8 B0 J  E, W9 H$ w- }                end;
4 {# ^, r& o0 N: Z        end;  s  t7 k: V& E' B
end;        -- of the method
1 g; R5 s+ J2 D6 o3 u( F( |4 Y2 E! t
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 : q& W3 l5 m7 x

5 L$ d/ h1 g- S, @" D. e# T这是AGV_putin中arrive的method。7 M" h4 W; M' d' Y1 n/ Q
* a! r( y! S6 w$ |; r
当到达物料速度越高时,这个报警更多,
/ z" A  F* j: i; G可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
& o7 Z1 D- D. t6 v程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
% m' N! C/ @$ i  ?2 ^) h% }8 n& F" c7 q9 L% b: O5 |! L! D
另外一个小建议,就是move,所有的move都可以这样9 e& o0 i- l3 I2 Z. o: [
if not move() then debug end
. O0 v& ~, M$ P这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
" |0 `1 F2 d' g, z: [8 b( I% {; z# `plant simulation中的free libraries有AGV模板,7 O* R% N/ O9 ^, O; O5 Y6 g7 [3 u
里面也有案例。
3 }" e: ]1 o, i4 v我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。- I3 ^9 }  f& J2 J) S
; i. f# i& w% o; w2 n& B) }' j+ Z
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 * \8 B. J/ z: a2 t, j% q6 b: d
/ I; I$ R3 s7 ~" E* \
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
( H1 `5 g; h, c  L) j这是AGV_putin中arrive的method。8 m" y4 R% h: ]" }
# U7 Z3 C& W. I" k
当到达物料速度越高时,这个报警更多,

8 b0 ~3 }/ O5 d1 L1 h另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-28 22:03 , Processed in 0.016189 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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