设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9845|回复: 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') E! n; ?. _# U' v+ k- C& m
*/
& W$ @2 v' m( a9 }: m3 nis/ C" [! Q3 m8 k  T; ]* K
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;5 t1 q0 m8 n/ [: J: W# }6 [
do
+ ~; P: N" u+ `; q9 A1 X        Lan := rootfolder.Internal.Tools.AOLlanguage;# s6 x3 Z; C' M. H
        if current = @.Destination -- else return
3 m& B  ?3 J! _! C7 ~3 ~- o        then$ c. y( G5 z. e7 r7 M% j
                @.Destination := void;
! K% o; o" _" k% h6 V                if @.occupied then( F  y1 z4 g& c# ^/ E1 T
                        part := @.cont;
6 A% j' I( W9 d/ X" Q                        @.transpOrder := void;1 `/ G1 [+ i. C# J$ i8 w- s6 Y2 \
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
( a) e5 n2 V: [                                @,root.eventcontroller.simTime);
% Y/ h* T% @# E6 D6 G                        @.HasOrder := false;& F9 Q1 D1 S1 i. B+ k" V3 `
                        @.DrivingHome := true;6 R# @& a  g0 M' E, X
                        rgManager.tryToStartTransOrder;: D" N9 U+ I9 M& Q
                        if @.Destination = void' n1 {8 L: D: G2 I' L+ [5 q+ r9 k. Y: G
                        then -- no transport order for vehicle @
6 f  s' F& X8 K3 G: Z: n* S5 H7 k                                @.Destination :=
. X8 c; p+ b/ W; c2 d1 B                                rgManager.nearestFreeStation(@,track.~);3 y* w! a' v7 Y
                                newDirection(@);   # |' R2 W: b5 P) F/ i
                                if @.Destination /= void then$ e( o) d4 V: a
                                        @.Destination.NumReservation :=* a2 z9 z. f$ A% A. x, d$ o8 g
                                        @.Destination.NumReservation + 1;' B* U& K; r0 p1 R' C& x
                                end;$ n  Q) i' [2 _* U8 O3 ?/ }, f* @
                                @.CurrIcon := "drivingHome";9 n* e* ~/ W2 d) ^3 \! e, G$ Q4 g
                                @.DrivingHome := true;  O1 q; s: ?3 G8 G/ f
                        end;
. V/ D! j7 Z" T, {2 t; Z2 O                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
- k. e# |" N% r  B/ `1 ^9 m                        part := @.transpOrder;) h; k) X  q( `" C
                        part.move(@);-- load part
/ e: W" I' x$ L  f  {  t) N                        @.CurrIcon := "load";6 r/ D2 `% s: b' z) T
                        GlobalDistObj := part.globDestination;
: _" H- U5 h( U                        assignLObj := rgmanager.rgAssignL;  S+ k4 U4 R8 N
                        row := assignLObj.getRowNo(GlobalDistObj);9 n4 C! ?2 d. v* ?
                        if Row = -1 then -- since 70
$ n: P) j; J9 o                                if lan=1 then7 Q3 b# s2 I% t! _  X0 z( C
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),) N6 X7 K' c9 d7 v
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
% U2 X+ B8 f0 h/ x! f, y' ]  d/ B                                else5 t0 Y2 Q( G7 |3 S  C/ M1 T
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),8 f0 N2 p" H. i; q7 s' [
                                                to_str("in docking station: \"",?.~.name,"\""));                               
% n7 n! ^9 k/ m. K  h                                end;+ }" g" x; d3 u8 Z: ^& H
                        else
$ q/ j9 ~1 r  F8 {7 e1 O% B                                @.Destination := assignLObj[1,row];
* f8 h' H# R+ ^- ^! }7 t                        end;                       
, a# c5 {4 c& g& d1 Q& h                        newDirection(@);. z& d3 m8 g# F9 N1 Y& G  q& z
                        @.HasOrder := true;
- c2 _$ Q6 D. w3 X7 a. y0 R) c2 z                end;
# v! B/ z2 q  k  M/ r- k* U        end;
( j( p  z7 X+ S. zend;        -- of the method
( w  p2 U0 X( @
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 $ B% @' |" [5 k; _
4 W. }0 e# ~0 P% m6 l' A: n
这是AGV_putin中arrive的method。1 F2 e0 O: Z' R: w+ c& F3 `

" B6 g3 C7 h- y! {" }) [( A当到达物料速度越高时,这个报警更多,
3 l% H! J# `: K1 t7 w可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。" B# t% f, E; X9 J0 E0 z5 f  a; Y
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?2 z- F8 K# U, H! q4 Y2 i2 r4 }- _

. f* U" J; t  c另外一个小建议,就是move,所有的move都可以这样$ e2 h/ Q* t4 b8 v
if not move() then debug end
4 U7 O, z& t" }1 N7 L# o6 j0 `这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
) x* a4 g( q$ S" Z2 v, y1 [plant simulation中的free libraries有AGV模板,
# d3 E! C2 b1 u% d) Y里面也有案例。$ a0 r; O+ q9 _
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
: Y$ ?& e* m. d' V1 ~! j9 `1 Y2 Q0 q% b' |: o7 Y4 x0 V4 C8 ]4 f: F
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
' t, W+ U  C* D* O$ P* c9 ?, g( \. N. p1 l$ R
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 5 r1 D: t3 }5 P7 t0 u2 l. T
这是AGV_putin中arrive的method。
, w# q, I9 ]  E( M: e* u' K+ |$ O6 \6 b) M2 ?* T
当到达物料速度越高时,这个报警更多,

; Z! w* w5 T$ i) w另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-28 21:01 , Processed in 0.018631 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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