设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8212|回复: 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'
6 e: K; _" O8 k*/5 ~* ^4 r7 [$ g) n$ n1 ]! O% y
is
5 e7 q6 n$ }( h4 S" L! o        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
, T' Q9 C5 ^( T4 v( I4 [4 ], a: _do# Q' F2 [+ B0 Y7 |
        Lan := rootfolder.Internal.Tools.AOLlanguage;
: J+ T8 q0 p0 B; k! o1 K) |# r        if current = @.Destination -- else return
( t8 [7 P( L* F& Q2 J- B9 V; `3 I        then! p. k4 g) n1 M: I+ j; y
                @.Destination := void;
: ~7 B1 M. r9 L                if @.occupied then) R+ e# }0 a4 o1 Y( J
                        part := @.cont;" t9 k" R2 p' U; K0 X, z8 I8 J
                        @.transpOrder := void;/ k( s5 ~- L3 h# [
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,8 d$ F# X: n( h9 f- E/ o2 u/ D
                                @,root.eventcontroller.simTime);: P) A: z$ }, h5 L# X
                        @.HasOrder := false;* c: ^, }6 v( y- C4 G
                        @.DrivingHome := true;5 m, _( U8 U# A* r' f% O1 j
                        rgManager.tryToStartTransOrder;
/ }! \  T6 J' _* V: x' D. g" K                        if @.Destination = void
# `8 I4 y! P$ E6 R                        then -- no transport order for vehicle @/ k5 c/ k& D; [2 P( F2 n/ e
                                @.Destination :=7 j; K' m( _+ R* r. k  c+ r, E
                                rgManager.nearestFreeStation(@,track.~);; s7 F6 Y6 _& i$ l6 ?- n
                                newDirection(@);   / \; J) K+ P) l+ q" h
                                if @.Destination /= void then
# Q4 V; a7 u5 ^4 q& ~  @                                        @.Destination.NumReservation :=
- ^( |/ }6 k) o                                        @.Destination.NumReservation + 1;
+ `! k5 r  R. u7 ~1 d1 L                                end;
# S; O  h8 A0 V& \3 l                                @.CurrIcon := "drivingHome";8 Q+ g4 ^4 j- u4 e/ _0 e
                                @.DrivingHome := true;2 T- B3 o4 B' u# `! w3 c: o9 O7 m
                        end;
3 l( c4 Q5 R9 I. f) K                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
  Z  _/ J' X' A: }5 z* P                        part := @.transpOrder;
5 l6 t# f0 h. t1 o0 j6 A                        part.move(@);-- load part
# f, Z6 ~% j" j7 {8 G' V* z                        @.CurrIcon := "load";. b& P0 S' I3 C; S# E9 S: w! ^0 s
                        GlobalDistObj := part.globDestination;
- |) z/ v6 |0 |2 R/ K$ s                        assignLObj := rgmanager.rgAssignL;
7 j9 O/ p- P! }" Z                        row := assignLObj.getRowNo(GlobalDistObj);3 ]. |8 a7 U( q; U2 K
                        if Row = -1 then -- since 70, N3 H/ K6 c+ K* m/ s% @( Z) W
                                if lan=1 then5 {0 Y$ J  a  H3 ?  {6 b" x
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\"")," [! u# R, z# b  ]
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
7 I7 R0 @7 o8 ]1 E" H9 |                                else
9 F1 t" v3 S' H                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
2 T& R* J6 K2 b6 q0 Y% }                                                to_str("in docking station: \"",?.~.name,"\""));                                * {" y7 m* G' S( k; \" c' Z, P- U
                                end;* Q: [9 l7 ]$ c1 s* b" i, ]
                        else
- F: o/ R) U$ n# V% _' A6 f                                @.Destination := assignLObj[1,row];
  Y$ N/ G# _$ {$ I3 G1 d9 g                        end;                       
+ k2 a- b# `0 ^: H: N) [                        newDirection(@);
! G5 R! |. I. M: e7 h3 y5 A, B                        @.HasOrder := true;
; c7 I$ u2 E' w  N) y+ y: m                end;
9 s1 B1 Q& g: d7 ]& w. j- A        end;( V& ^' O. u: L- f7 v
end;        -- of the method+ V. K5 P# M" q# C% K  m0 V
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 - d' }& B( _' }0 c
3 H! p+ h+ g/ l9 t2 `, u. E
这是AGV_putin中arrive的method。
1 p2 i& d' W. {. X1 Q' k% p' d) E8 H
当到达物料速度越高时,这个报警更多,
, k" v( Q3 P3 L可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。6 Y- w, E; V$ a% Y
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?% a. R( B" N' U2 m/ |. ?$ t; z
5 f7 w9 R% k  K$ v3 w
另外一个小建议,就是move,所有的move都可以这样
2 ], B- T( l6 G: Y9 d8 Jif not move() then debug end& ~2 X) F7 v! [' W) D4 q# M
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
2 r+ [8 {3 n6 i( c' ?# D( X1 s$ m" yplant simulation中的free libraries有AGV模板,6 l! t) x" ?; J7 V) {
里面也有案例。+ S& t' X* i  p. E& H. P( n
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
8 [0 U1 g1 m5 V$ I# o
$ U$ \$ ?1 u; i  e4 _9 ~我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 . X4 _1 H9 m! }- {% {) ?: J
5 t& l! V5 w7 ~' y# E
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 . `. {' a: z& }9 |
这是AGV_putin中arrive的method。
$ o" Q7 z1 A( A' s
% {# k' v; ]; s( ^) B1 d当到达物料速度越高时,这个报警更多,
9 g6 @# ]0 E7 D  a) E5 S" U
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-21 03:24 , Processed in 0.025693 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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