设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8606|回复: 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$ g9 M! z( S( |2 ^7 W3 ~
*/
& l+ O, N# }8 R: [is
( a. ?& H1 g, B+ i9 T9 D        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
" Z2 Y  |  _9 Fdo( u1 J, d) E- Q% ^  u
        Lan := rootfolder.Internal.Tools.AOLlanguage;
1 x1 A8 t3 O* J        if current = @.Destination -- else return
# k! e" C* Z& ~# H        then
9 t* G8 X$ z, L" U# ]* U+ ?                @.Destination := void;
. Y+ E& b/ t7 }; ^) f$ K+ T                if @.occupied then% ~7 Q8 B$ M/ ?/ r+ O/ ~+ T: w
                        part := @.cont;7 p9 x1 ~% F& \+ y6 E- C5 a
                        @.transpOrder := void;
/ n) K* l+ T2 e( }" y* b7 I6 }                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
1 i/ w! G% S2 C. [                                @,root.eventcontroller.simTime);' C* V' ]3 H; X2 h
                        @.HasOrder := false;4 y9 Q1 k! a, c) x" d' @5 y8 l
                        @.DrivingHome := true;+ A* f) _# _  K' m6 f4 b
                        rgManager.tryToStartTransOrder;2 B1 ^" X8 K2 [- Z0 s# P+ ]
                        if @.Destination = void
6 L" ]- w# R4 h3 t3 A                        then -- no transport order for vehicle @
$ B! j. K7 u& v& y* y9 u' Q                                @.Destination :=
0 h+ \! d# h: k% Y& Y$ U                                rgManager.nearestFreeStation(@,track.~);
! C$ Z0 I: u) V% x% K) ~$ b5 L. k                                newDirection(@);   ! o2 V, i! |9 ]- y) c/ ?
                                if @.Destination /= void then
) d6 K0 S' m( a                                        @.Destination.NumReservation :=6 w: P- o- D5 N
                                        @.Destination.NumReservation + 1;, z; F% Y' A" T; `- H4 Q7 r% |
                                end;
. j5 z8 m( Y( [  I: H3 |                                @.CurrIcon := "drivingHome";9 h3 i  D8 |% ^' E9 I
                                @.DrivingHome := true;0 E" h5 W5 c: b, \* Z1 N  \
                        end;
+ s7 }# K( J' k; I# d) `                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
; W4 G- x  E( o3 {                        part := @.transpOrder;
; @. d( a4 T' F9 g# S' o/ \" N2 i                        part.move(@);-- load part! Z$ R( J+ }, _. q' E  ^6 R' g+ m
                        @.CurrIcon := "load";# N; y; N! z; c6 Y! [
                        GlobalDistObj := part.globDestination;- `* F8 U0 D0 m; U5 E
                        assignLObj := rgmanager.rgAssignL;
9 j* X5 J9 m# F& c7 m' X) g                        row := assignLObj.getRowNo(GlobalDistObj);" F2 r& @9 }" A# {3 ?) q! a
                        if Row = -1 then -- since 707 z5 i! h' f# ^% X
                                if lan=1 then
. @$ |( P6 [" h7 Y* f                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),/ ]4 E- A8 I, H
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
7 y8 D5 u0 U' P4 @4 V+ c6 R                                else
9 a" S. `$ }1 y5 a- B# ^; Y# ~                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\"")," ]& z5 j1 T6 P, a$ }; C/ M: \0 M
                                                to_str("in docking station: \"",?.~.name,"\""));                               
% T  X2 v: c3 A+ \                                end;) ?4 V# Q7 D+ o0 v( ^4 D% k' b0 x  z
                        else) C- n6 t% e* h( c  e! n" I
                                @.Destination := assignLObj[1,row];
" x8 }2 C$ k; N                        end;                       
0 Z( h7 h' u: ~/ U/ E                        newDirection(@);
; K) }' k: m! n& Q. X9 k                        @.HasOrder := true;' _( i) d  B9 A8 N3 d
                end;0 l( i7 l* J" B5 J; Q, x
        end;
; I! h# ^1 N5 b# M4 A' v& aend;        -- of the method/ L2 p  t( N! r3 K0 f7 c7 W
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 1 g) C" ^' \% [  y/ ~5 h
- ]' p* H! ~6 }7 `$ i2 ]9 N
这是AGV_putin中arrive的method。) e3 \2 G+ B" P8 P- \  o" b
6 b7 w0 `+ M2 h; ?
当到达物料速度越高时,这个报警更多,
  }, R3 u7 Z/ @9 W" ~& k; ?: t+ }) }& l- F可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。; M; X2 t) L% h. R3 x5 {) P
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
0 h+ S5 Z2 L* Z' t9 a9 P/ w# r
5 w8 T7 l% A$ b& k8 g另外一个小建议,就是move,所有的move都可以这样7 \0 Q2 m" n6 f$ H) {) K
if not move() then debug end
$ i  |# R' Q0 l( F这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。3 Y! w' P1 [6 E5 h( _: D
plant simulation中的free libraries有AGV模板,
6 ?) j. g4 x% t1 {3 K5 [- j- T$ S里面也有案例。
* d) Q; I* f% w% ~我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
$ L6 h/ d1 ^/ [& w8 [3 A  E$ y
7 \7 U4 x3 a1 `3 O' M+ L' V我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
9 n; M/ X. h/ l/ A& |9 q/ {; E% a) h* p+ E* N5 T, H
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
0 F0 d4 G. ?$ h& T% [% }" L1 L这是AGV_putin中arrive的method。4 ^) {- f& i: Q, V' ?1 O

8 u/ R: H+ o$ l9 y8 d当到达物料速度越高时,这个报警更多,

. A1 j  O& r+ y4 M5 j, N' C$ i另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-15 07:20 , Processed in 0.018325 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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