设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8149|回复: 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'
- _, J7 l$ ]3 D8 d*/- e* e# J; T, `4 G  T2 V
is
% K) B) J3 I6 p8 u2 J/ j( s        part, GlobalDistObj, assignLObj:object;row,Lan:integer;! I- V6 D1 O( o
do
2 w4 z$ [1 o6 a3 v) ~2 W9 |        Lan := rootfolder.Internal.Tools.AOLlanguage;& }/ k6 V# V( r& g5 b9 b, Y
        if current = @.Destination -- else return
+ _4 S3 Y! O) }0 H! g4 u2 `        then
2 \, m4 z; d  U' u% {                @.Destination := void;' P( I$ Z5 L0 z. L. q
                if @.occupied then
# d8 H6 Q+ P* d+ n# W! l/ {) s9 U                        part := @.cont;% l! V/ [+ l/ u/ g1 ?1 `" R% R
                        @.transpOrder := void;
4 i3 F4 _: R& U6 h( \                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1," p) u& |! x+ D( A# d
                                @,root.eventcontroller.simTime);) J' e! A, d0 \5 }4 Q
                        @.HasOrder := false;! t' D: F& h: [4 A
                        @.DrivingHome := true;4 I( }  I% b, m3 D: F, j8 f
                        rgManager.tryToStartTransOrder;& d, N4 I, h! h5 q. h
                        if @.Destination = void
1 r8 E6 e/ h, G2 I" l                        then -- no transport order for vehicle @7 {& {, U3 \9 q
                                @.Destination :=
: a3 r! I( \+ R6 h" y                                rgManager.nearestFreeStation(@,track.~);) G3 K$ L0 L; ?3 L
                                newDirection(@);   
8 _/ g- Z! I* m% o                                if @.Destination /= void then
: i2 y) P  @$ {" k+ I' k. R7 @6 }                                        @.Destination.NumReservation :=- i' v) m3 I/ Y" |5 y
                                        @.Destination.NumReservation + 1;4 o- L% w  x2 k, J
                                end;
# M) \( `! d, x! q+ [                                @.CurrIcon := "drivingHome";8 p# g7 k; a# p( [# o
                                @.DrivingHome := true;
6 F' L) v8 }% T1 `                        end;* G2 ^! k' D4 I9 G1 o. Z' U3 q
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
& ]/ {3 @& \2 H2 p/ H: N5 O                        part := @.transpOrder;
3 f) w9 {* m+ s9 ~                        part.move(@);-- load part7 N9 L: f1 T3 D7 z$ Y5 b) c
                        @.CurrIcon := "load";8 s. L5 }) a3 \8 k
                        GlobalDistObj := part.globDestination;
. q! B5 \" s  R% j* ^# |& a                        assignLObj := rgmanager.rgAssignL;1 I4 h9 q8 O5 g+ h4 Z) e
                        row := assignLObj.getRowNo(GlobalDistObj);
7 f: @4 _% Y+ l1 G7 T                        if Row = -1 then -- since 70, ]5 O. U9 f# I
                                if lan=1 then' \% S$ @/ `. n
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),( T. y' |( H' H5 h- L# \( q
                                                to_str("in der Andockstation: \"",?.~.name,"\""));' o- X" q- Y. r+ C$ U2 }0 w
                                else7 R3 x; {, p8 L# u/ @; A/ @! r
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),3 R( u. G% T3 F# z: u
                                                to_str("in docking station: \"",?.~.name,"\""));                                6 P4 l0 Q# B0 k% Q* Y
                                end;! y1 H$ {# M4 c" L: ^4 |
                        else& `2 f& @3 R8 v# _9 O: z
                                @.Destination := assignLObj[1,row];
# n- ]- T, ]/ d                        end;                       
& V8 ?; ^8 A. y) v8 j) x. R/ K1 Q& n                        newDirection(@);
8 k/ g2 v- J3 c& K                        @.HasOrder := true;! c1 p+ ~$ C0 W4 q0 F
                end;. o. k" A1 `& g! h% i
        end;& Q4 g1 X" A* U. N, ?6 v- T
end;        -- of the method% g& t8 ]! |1 c* o# N
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
- r, X% o' @. c; c/ ~& [+ r9 V! U; C$ x9 k, f
这是AGV_putin中arrive的method。- b0 H8 u& G9 M
# M$ ~  y& t' |4 }
当到达物料速度越高时,这个报警更多,) S( O$ R6 C0 }$ @2 ?0 g
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
% A# ^0 {5 ?. C4 O: s" y3 R" b程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?$ r) y% P  R  Z! X, h4 m* [
' ~* ?0 q' v2 O) M6 I
另外一个小建议,就是move,所有的move都可以这样/ t  p. ^! _% V; W+ O- d" {+ b
if not move() then debug end
% [/ [: Q# X/ ?9 M* [这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
8 H! M" l5 ?( m- rplant simulation中的free libraries有AGV模板,
, t( P6 F. N% w9 d1 Y3 G' n8 t( m里面也有案例。- x9 H' x# P5 L. m  V8 U
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
+ Z: V8 D  e: D) m& z" U. s9 N
- ]5 X# \3 b" b& A7 `/ v4 x7 @! h# S/ i我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 , g, l' W# h4 ^9 ^. D% l. p

1 [% ^' N0 y. }* _3 [! @那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
+ l: c; w1 |$ k5 ~1 x这是AGV_putin中arrive的method。) f+ f( @9 J9 |4 e7 d

# V1 m6 `4 B" Q' ?当到达物料速度越高时,这个报警更多,

6 E) ?$ M: e& N" U0 J8 y" ?4 N: n另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-17 12:29 , Processed in 0.018351 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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