设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9296|回复: 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'
* p0 o0 \/ S5 F  R& G- @*/4 e7 H2 K! ~* E& A, `, O
is
) P6 o6 |' F. |, R; \8 q  V' k        part, GlobalDistObj, assignLObj:object;row,Lan:integer;; X3 q/ P6 r3 V3 n
do
% v! ~; u: r( {+ {        Lan := rootfolder.Internal.Tools.AOLlanguage;3 Y' M' |' h" o6 x$ \  M* Q
        if current = @.Destination -- else return# Z; N8 I8 n' r* [
        then8 i$ g  ?9 X( L  t1 Y! g  e5 p/ r
                @.Destination := void;
0 E/ _6 |! R  ^* g# N" f% |                if @.occupied then$ M: x) U7 }8 `8 t# B: E$ C
                        part := @.cont;
/ s% b& c+ ?. S( i( i" ~$ _  i4 s                        @.transpOrder := void;
' d- E2 @1 C% J& T5 h. `                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
; u( E/ r! Q9 n5 ~                                @,root.eventcontroller.simTime);
) ]) t1 X) w8 v0 h6 r% K                        @.HasOrder := false;
4 i6 v' D0 A1 {. X& D# X2 @6 b7 }. N. m. V                        @.DrivingHome := true;
! G9 `# S8 h! H5 r                        rgManager.tryToStartTransOrder;
+ G, r+ a5 A; ~; `                        if @.Destination = void( \  p% @- q7 L4 b
                        then -- no transport order for vehicle @' u  ^+ ~- Q# z- H; M- u2 P) F
                                @.Destination :=
2 _5 W5 w6 m2 W$ W, t                                rgManager.nearestFreeStation(@,track.~);7 ^- A7 T8 y) O/ _. S
                                newDirection(@);   9 K: k$ r8 i  v
                                if @.Destination /= void then
# ]6 [# E1 e3 h8 {                                        @.Destination.NumReservation :=, U! b' o& G4 c/ |4 B
                                        @.Destination.NumReservation + 1;* a; I# Z4 [" O3 W& |3 r7 _& S$ N1 z: m
                                end;
* E& E  y8 s" F                                @.CurrIcon := "drivingHome";1 r6 l. C3 C' D! @5 D7 e& S1 Q
                                @.DrivingHome := true;
7 N8 g) |) }9 {/ I( {9 g                        end;
: a0 F( [% G0 O; @/ ~" ]                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
2 t/ W5 P) \6 L6 c# B                        part := @.transpOrder;
4 v6 Q' z  b3 q( Y% }                        part.move(@);-- load part
" e) M+ g' k/ B. v: i                        @.CurrIcon := "load";; u$ z6 c5 C1 Y" M8 K
                        GlobalDistObj := part.globDestination;, p1 _% Q/ c2 ~1 H* o8 o9 ]
                        assignLObj := rgmanager.rgAssignL;
& S" B. J& \, [. B& V                        row := assignLObj.getRowNo(GlobalDistObj);" C( a5 `; t. l9 F7 x' j! k
                        if Row = -1 then -- since 70
; R# o% O. j$ l+ e, P                                if lan=1 then+ C  M3 c0 K9 p5 a) L- T
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
5 A2 ~! q% H  a                                                to_str("in der Andockstation: \"",?.~.name,"\""));% M3 }/ h4 |  L5 w
                                else3 P1 e( P! @8 v/ Z! ?1 d! x
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),7 g  c1 _, A7 P# `9 ^$ b
                                                to_str("in docking station: \"",?.~.name,"\""));                               
) K; p$ h+ ?( o# L                                end;
5 [& `+ a) d: W! I' @/ P0 A                        else
7 o4 M) T* _: F                                @.Destination := assignLObj[1,row];
# P  a, Y: n, ?8 q- J- D, F+ k                        end;                        ' Y% t. i. v' R0 ~, @! `
                        newDirection(@);
8 B: g( K  K- x; y5 x9 r' I  q                        @.HasOrder := true;" r2 p6 E; b* Y4 m  _
                end;& R/ ?1 I" x# k, Z& l
        end;0 n/ C, @& E" J+ N  K  ^
end;        -- of the method
  D. E# u( \; S5 p7 |2 e/ D
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 - W6 h+ I3 v( s7 J! O% C

7 B9 ?6 f# T- X2 ?' F8 m+ q这是AGV_putin中arrive的method。3 p7 m* n1 E' r$ Y" V

# J8 a+ [; Z& G7 n当到达物料速度越高时,这个报警更多,/ G( `9 Z( T8 n
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。# i% S9 h3 |, H1 G( d( V- k% G8 z
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
& }+ m5 D* G& j- Q! r, R5 A1 Y5 n4 T7 ]+ A0 A6 L
另外一个小建议,就是move,所有的move都可以这样# V; c7 ~, b; i  l
if not move() then debug end3 }. ^. f1 |8 _: A
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。' b6 Z: S' L! K6 P" K4 m7 E
plant simulation中的free libraries有AGV模板,/ [. m! Q$ V( S1 ]
里面也有案例。
; E2 A( J# P6 w9 }0 l我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。0 P0 V: u7 f& C: C4 D' F# C
7 F, ]/ S- ^8 k1 o  h; S  l
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
6 n+ `5 ~7 K. W5 Q3 L' r
1 S  c% J2 p9 J5 }* S那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 : N0 |4 ~, C' x. r3 I0 ~7 A9 f
这是AGV_putin中arrive的method。
( y/ l' y5 y8 V6 E* @9 c. T
+ o- X8 w; q8 S8 X. @1 b5 [; x当到达物料速度越高时,这个报警更多,

" u  p$ I' o, g2 h7 T另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-23 15:29 , Processed in 0.019571 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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