设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7108|回复: 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'% T& S- s9 ^' a) m% W) _
*/6 g7 ~) y" B8 X
is5 @: V/ Y. z3 c( R
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;) y% A/ O- U8 H9 X
do
* d5 W3 H  X& ]1 u7 ]8 m7 i        Lan := rootfolder.Internal.Tools.AOLlanguage;/ f7 B' L6 ?/ V( W
        if current = @.Destination -- else return
: ]1 o  L" u2 P( X: N  g        then
  C6 r  m& R# r1 ~                @.Destination := void;: K. D& ?  j0 I9 z5 y' e
                if @.occupied then
- i( F4 ^: {! a                        part := @.cont;: c+ C1 t8 Q% p3 y& {8 _
                        @.transpOrder := void;0 r0 F4 `( @8 f" T( ]
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,- @) F$ B) w4 l* Q* n8 ^0 P
                                @,root.eventcontroller.simTime);
9 i0 j5 }. |0 O2 _# j                        @.HasOrder := false;
1 K; c, D0 v# I1 G. c! i- O                        @.DrivingHome := true;' g. L8 o4 F" l+ k
                        rgManager.tryToStartTransOrder;0 p2 z* {. h0 L: O) k
                        if @.Destination = void9 L3 N+ z; Z8 r' }! U8 ]; y
                        then -- no transport order for vehicle @
4 T; z8 p  g; |* [                                @.Destination :=5 b# r7 J% L2 p5 [6 Q  m6 X
                                rgManager.nearestFreeStation(@,track.~);0 L8 A9 E1 ?# E0 D$ C1 ~/ h8 c, \7 A
                                newDirection(@);   # w; I( M' u  F( {
                                if @.Destination /= void then
4 M( }3 ?" d# l                                        @.Destination.NumReservation :=
$ B% [7 ?. J* B& w0 h, w6 Y                                        @.Destination.NumReservation + 1;
6 g+ }$ d9 d& l; b8 c: E                                end;
1 Q6 ?! |; I* I- M& i                                @.CurrIcon := "drivingHome";- O: a0 N% d3 c5 o8 y# b+ H
                                @.DrivingHome := true;
. Q$ e6 C' O5 @                        end;" K: [3 |$ _, U% r' x
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station1 ], i! Y" F" [3 J. i2 X
                        part := @.transpOrder;5 \! H4 e5 ?3 O$ u: _5 {
                        part.move(@);-- load part# v2 O5 b$ u0 q4 f0 J6 I6 u/ m) T
                        @.CurrIcon := "load";3 t% \% A2 @* j3 x  i% l! D
                        GlobalDistObj := part.globDestination;2 J  D2 C! F% ^8 D/ C/ K! j
                        assignLObj := rgmanager.rgAssignL;! D9 H( A9 K9 q. r7 {
                        row := assignLObj.getRowNo(GlobalDistObj);# \1 ]" G4 K2 V; z6 t
                        if Row = -1 then -- since 70. i2 J9 ?+ |% E' T' U1 Q( ]
                                if lan=1 then/ h) \# l6 L- a# o
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
6 |! ?/ K  S8 x3 c9 f5 [, o" c                                                to_str("in der Andockstation: \"",?.~.name,"\""));
) C- h$ n4 ?' R5 }. v0 u" q3 {+ Z                                else
' p/ V$ _' j3 y6 Z                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
# x7 e( _( Q+ `- n: P                                                to_str("in docking station: \"",?.~.name,"\""));                               
* d9 Y& D6 G# O  U( k# T                                end;" P4 X( u7 V/ q8 I, N
                        else) O( |1 x) G5 G2 W- q. C5 w* O
                                @.Destination := assignLObj[1,row];
6 W) F: a* p% b) p$ _! q, S* A                        end;                       
+ v: C! R( k* Q, ~                        newDirection(@);; b0 [: L# Z0 W/ h1 F
                        @.HasOrder := true;2 y1 z, `( K. H% q
                end;
+ J$ o4 ]9 c) W% V& ]# \        end;
3 O5 V; N% p  O8 ]end;        -- of the method
0 |4 J/ m8 m* ]4 B. ~/ e
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ' w% Z5 V0 I* G$ r7 b

% r0 e: Z) G8 ]/ J" ]8 Z/ Z这是AGV_putin中arrive的method。
* f" K# b/ A! a+ C# o7 e+ v8 f- I& F4 I2 U
当到达物料速度越高时,这个报警更多,
+ E4 G4 ?" V, Q3 m( M" a: W可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。, ?* q0 v( G0 u
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?3 r- _+ ?6 f4 X  A. u# N

; C' X' r4 g  ~" \另外一个小建议,就是move,所有的move都可以这样$ n$ Q, `% W& v" \0 F9 f6 s" O
if not move() then debug end! S: w+ s' g% w4 V. k+ k
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。4 t8 F' }8 m! U' m9 @
plant simulation中的free libraries有AGV模板,
/ h7 P8 l* O; F7 z7 J' Z$ H5 N里面也有案例。
" v4 N1 S5 m" N, l4 w7 S8 Y# U5 V我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。6 m6 G6 Y7 p+ m6 u
# k9 O+ o, G1 j, T. X' k
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 6 e) Z" u  P& f$ {* G, F: P
2 g4 r/ g/ m. B" a
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
' \, t) e2 n0 O) j" n/ ~这是AGV_putin中arrive的method。; _2 V3 o" H- I( {& }0 ^/ P. y' `
% A8 R1 J$ I! H* c) E  ^
当到达物料速度越高时,这个报警更多,
1 x- g0 s4 c, O! W0 C, i+ M# L: \
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-18 20:18 , Processed in 0.019067 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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