设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9606|回复: 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'
, Z% Z$ ~" I3 U) s  p6 [*/
2 b  U' `0 s. v2 o8 S5 A: u( eis6 G; b: J4 V/ {
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;9 _* A/ @: J8 c5 X2 a' U  m; z
do4 M0 R# }" J' [8 Z  n
        Lan := rootfolder.Internal.Tools.AOLlanguage;
4 L; T( `. N! Z        if current = @.Destination -- else return/ i& X9 \  {5 f  i
        then9 p$ P! \# J* [' B9 z8 ?
                @.Destination := void;
& ]/ ]3 c2 m; F# V& Y1 M                if @.occupied then1 {8 @$ r  ~1 t$ I6 V/ j4 o
                        part := @.cont;* D( y* h- N; I7 ~* r; }
                        @.transpOrder := void;
* Q8 T7 m* T7 x                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,, O1 C% o3 t6 j. t6 c9 }
                                @,root.eventcontroller.simTime);
: @4 a) _+ D  f                        @.HasOrder := false;. @* C2 A0 v% T4 R4 ?4 x
                        @.DrivingHome := true;
4 l( c- C% _3 }                        rgManager.tryToStartTransOrder;
0 J9 \3 v' k- z3 p" M+ e                        if @.Destination = void
( j" W* |# D( \  m# V( r                        then -- no transport order for vehicle @
1 |5 C8 v6 l( [) T% F+ L/ Q% e$ Y# d                                @.Destination :=
0 j$ O  _$ e. W1 L7 s, j                                rgManager.nearestFreeStation(@,track.~);: Q3 y& z* Q! o- g. q& ^) p8 c
                                newDirection(@);   6 i% J) A2 s# K+ Z' Z4 u9 ?# i5 o1 Q
                                if @.Destination /= void then! H% G/ @4 N: O  x5 _$ ^8 Z. i
                                        @.Destination.NumReservation :=
0 ?0 v$ E: h$ A0 q0 P                                        @.Destination.NumReservation + 1;
1 U/ O7 q. i, U/ m4 U                                end;* Y5 c9 Q; E) k
                                @.CurrIcon := "drivingHome";
5 Z% h! }" G5 I/ i5 q$ I                                @.DrivingHome := true;  |6 [/ J9 J0 @4 _
                        end;1 P! |+ R) X3 v# c# E& {+ D
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
, L7 d5 b' p4 ~/ l8 a! N/ a7 e, f                        part := @.transpOrder;; W2 `, _! a! D% a
                        part.move(@);-- load part# X2 g- w3 C/ K  X7 _: W! A
                        @.CurrIcon := "load";! H$ e- K, u8 L0 J4 p
                        GlobalDistObj := part.globDestination;
; d9 G1 D( E# ~9 Y3 M5 A                        assignLObj := rgmanager.rgAssignL;* |/ E. K0 U9 }3 A8 I9 h* t
                        row := assignLObj.getRowNo(GlobalDistObj);6 S& U- w% P( D0 [5 W3 }6 v
                        if Row = -1 then -- since 70
! E$ ~0 U0 t/ j# K4 m7 v$ b9 }                                if lan=1 then( H: u, W+ I, n" t6 m
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
* L) v! [- f+ o, X- L' @- F, w% i                                                to_str("in der Andockstation: \"",?.~.name,"\""));0 ?* t5 d0 v# B# Q! E
                                else
' k+ ]  W5 _0 l                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
6 R. O( e! u4 E1 N1 {* M5 z                                                to_str("in docking station: \"",?.~.name,"\""));                                1 |3 j- P. p, M& [) [& P
                                end;
# V# w1 a0 I: `# @& R, b                        else$ M  T( B5 a- h7 L. |3 C. q: C
                                @.Destination := assignLObj[1,row];
* ^, J! t+ U. g6 z: E2 w$ k                        end;                       
" q1 \2 t" h. [6 T6 c; k                        newDirection(@);5 e' N0 o7 B% _9 ^6 l- s& c+ d
                        @.HasOrder := true;
, F" @0 r) L. Q8 y                end;
, D; Q! U/ d$ A        end;4 c. h; B+ p) @( V3 E7 J6 f
end;        -- of the method9 d' S, s" }7 n/ x. k% s9 w
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ( R$ I, `7 j; }( S3 w

: b. [# U. v+ |3 A" C" W这是AGV_putin中arrive的method。
9 r$ Y  n7 y2 f1 i- j
2 r2 p% G' i! B; Z  ?5 `5 m% i当到达物料速度越高时,这个报警更多,
" K6 D, d" u, H% l+ K- l- w" t% D7 X可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
9 w' X$ D; ]5 T程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?& B. N1 o+ x- B6 u, x

5 R* H3 M" m; Z; i) g4 _5 T另外一个小建议,就是move,所有的move都可以这样0 ], Y0 N/ F. L$ P  R
if not move() then debug end
; W4 n! l# e0 c这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。$ R  \9 x# S3 K
plant simulation中的free libraries有AGV模板,1 T3 _: V" `% X9 z6 y' ~: |
里面也有案例。8 R. ^' Q/ M0 p6 e4 [+ v- C
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。5 ^6 {+ H/ b7 @6 Q! b; J

1 Z1 X1 U4 v& e1 I0 d# f我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ; v0 n8 [$ P: i
6 x& X- G; `8 x9 b
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
% l" J, i1 V# a6 i2 C) z% f9 }这是AGV_putin中arrive的method。/ @2 L/ e7 t" h. {& a

* L3 ^# t! L, o8 O: A% d当到达物料速度越高时,这个报警更多,
/ v: I, \! P; B, }  T* V$ \' C3 ^
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-11 07:13 , Processed in 0.026396 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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