设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6384|回复: 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'. X5 E" m3 I1 h, K; w/ R7 {: F
*/
, q; Y" k& d. p& Z) Yis( N/ Q* t' o7 s' \4 N7 b
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;# h8 `( i6 m, s
do
/ |  W$ M, l6 J' V        Lan := rootfolder.Internal.Tools.AOLlanguage;" E/ U4 u/ ~, ]$ D# s. A
        if current = @.Destination -- else return) V2 k" C! J0 a+ K
        then
) s: G8 Q7 n( e* \# k/ [                @.Destination := void;- a6 K3 |2 l$ ~" ?  M
                if @.occupied then; @  y& S" W9 u8 a$ Q& V- S" b
                        part := @.cont;: B$ d9 S+ p' u5 p, Z  Y
                        @.transpOrder := void;" r: Y: h6 j2 w) A3 ?' V' f: S* i: @5 A; p
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
0 p- Y; u/ l( \! D5 \6 p0 P                                @,root.eventcontroller.simTime);
& c& ^( b" N0 T: ^6 q1 \                        @.HasOrder := false;
+ P0 R$ y$ V% ^- f& s) N                        @.DrivingHome := true;
6 a7 e5 e! V! b5 h( b8 L) d" d* \                        rgManager.tryToStartTransOrder;
' `0 C, O/ C) e                        if @.Destination = void* w# Q/ g& b3 m" D. x6 x" ?* n
                        then -- no transport order for vehicle @8 ?$ I  k3 W. h/ ]2 [; T; u: T
                                @.Destination :=! p, g7 l) _) t+ p' A
                                rgManager.nearestFreeStation(@,track.~);
; ^- N1 ?' N# m' v7 C; a* D3 s2 w                                newDirection(@);   + m, Q2 g' f* A: y
                                if @.Destination /= void then9 P  h+ J8 a- N% u: N8 t9 o/ w
                                        @.Destination.NumReservation :=+ \% ^: V$ D! f( d1 A4 U+ t% s; p! X
                                        @.Destination.NumReservation + 1;
5 T, ~% C' I( |5 t% `                                end;6 [9 }( A  b. k8 d1 e
                                @.CurrIcon := "drivingHome";& N$ p1 _8 z3 c- y7 \3 D- A
                                @.DrivingHome := true;
8 n# N( ~) g& d. Z+ i: c6 o                        end;8 L/ b0 g; e$ ~5 w' U3 i
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station7 \' x  [) }: B1 g0 v
                        part := @.transpOrder;
2 L3 j  Z& [( c1 Z2 @, G  J                        part.move(@);-- load part
# f7 w  R& Z4 K6 w2 ?( t                        @.CurrIcon := "load";# s# v! ^) S* `6 I
                        GlobalDistObj := part.globDestination;+ e/ ]  ?/ |5 W
                        assignLObj := rgmanager.rgAssignL;
3 }( l6 B: \9 _3 H# C5 z( q                        row := assignLObj.getRowNo(GlobalDistObj);& k$ f) A2 l8 Q; a0 b; o
                        if Row = -1 then -- since 70
% m2 s5 n' M# r$ T0 k                                if lan=1 then& I9 W2 o8 F0 ?+ N- v7 J+ z
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
+ o% n! j: h: I) R! T; _                                                to_str("in der Andockstation: \"",?.~.name,"\""));
3 s' I) d# a6 k                                else3 L' M' [# v. s! m
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),' l$ M, m0 |% W; F7 z; l
                                                to_str("in docking station: \"",?.~.name,"\""));                               
+ V3 O. W/ s7 k9 T& ]( ~6 Z3 F* F8 Z                                end;
0 |% c; H+ Y% B& f( U9 ]8 R& M" F                        else' D9 x( I; A5 G" o; F9 u6 o- Y/ B
                                @.Destination := assignLObj[1,row];" _2 B7 j/ s% g6 e/ Q) ?. Y
                        end;                       
; I9 {$ j  q/ s7 y' L                        newDirection(@);- o6 C/ w+ O+ X- I
                        @.HasOrder := true;
3 y3 ?, `% s  y3 {) g- k) A                end;: z1 p$ g* l4 r) u) H' s
        end;
1 z$ q7 ~7 b+ ^' Fend;        -- of the method6 L# b# |3 D4 v8 R6 w% h: u8 M
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 9 F# b4 o0 ^: ]

+ S6 m0 Q5 [; K! D: [这是AGV_putin中arrive的method。
/ J* J% ^4 W  ?9 A* k
% y+ u; m0 q  v9 {6 a  W, P: i( B当到达物料速度越高时,这个报警更多,7 q9 k4 r/ U+ g' [
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。' v+ a$ W( a9 D, W
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
1 D5 B' k, O& \3 t! s
2 W( v4 B9 _3 ^# p. w3 [  s另外一个小建议,就是move,所有的move都可以这样- m4 E6 ?& t2 u
if not move() then debug end- K- }" ^0 a( D) K( n0 n$ z
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
2 \3 L3 x5 g4 F- Gplant simulation中的free libraries有AGV模板,+ A, a- c, W6 }  |- d
里面也有案例。
4 j6 O* y) r1 S& A' m; a我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。2 U( O  i2 j$ F

! F! G. o, ~6 h' Z% ?我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
1 t, S) Z# t. m$ M/ o0 L$ L( o) H5 w. b+ D( x
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 4 V; N3 I- N8 r% e7 x- s+ i
这是AGV_putin中arrive的method。( @1 i! Z# X, j9 |6 \) ^# ~
% I2 s7 Z$ }- b; p! E) M
当到达物料速度越高时,这个报警更多,
: B: ?1 {" \/ V. C
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-3 03:45 , Processed in 0.017493 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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