设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6573|回复: 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'
1 \8 k6 \/ e  D0 o& e6 B*/
( Y3 v9 J+ X" U8 V! G3 O* Z% Bis% I% p+ B4 E) g5 ]7 w* X$ o
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;9 j* l3 {2 T4 h1 R
do  [: d1 H# z% X# R1 t$ T9 x4 _
        Lan := rootfolder.Internal.Tools.AOLlanguage;
6 p+ s- p2 t/ y' A- h) X( Y- t        if current = @.Destination -- else return
* b3 r' h# Z" r) n        then; q/ ^& f* q# f
                @.Destination := void;
& g5 B: b4 q' x1 [- B                if @.occupied then* a7 l$ ~! J  h8 i- R* d$ e: |
                        part := @.cont;
) A6 F6 Q- S4 F' A                        @.transpOrder := void;2 r( e+ P( N) z* n: u4 A  B( E- P
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
. h9 |8 D0 T# j) a) S                                @,root.eventcontroller.simTime);% Q0 g; D. H: ]" D7 d
                        @.HasOrder := false;; s0 q6 d, K) O$ \- x# B
                        @.DrivingHome := true;( m3 Y) X* f( b' f2 `. i
                        rgManager.tryToStartTransOrder;
) e! f0 D; ^' g2 W- l& F5 m                        if @.Destination = void
( V3 N- I. p8 f, ^! }: r% x$ Q, V                        then -- no transport order for vehicle @
. U4 C+ i1 @. a  U1 @2 d. l# A& t% A                                @.Destination :=2 P0 R1 T4 b% U' ]6 e" @
                                rgManager.nearestFreeStation(@,track.~);
/ c: a# q5 ~2 _, X0 x) H                                newDirection(@);   
3 W0 m6 S0 c* G- j  b! z) [. l9 r- P                                if @.Destination /= void then. U0 x9 D9 K; |  ~; \5 X; I& Q
                                        @.Destination.NumReservation :=. Z% b* {! a4 x/ D# w: k! h! }
                                        @.Destination.NumReservation + 1;
% P% W3 j! C% N                                end;; ~$ O3 i! v& ?, F
                                @.CurrIcon := "drivingHome";
  [' b& y5 O- c( m& Q                                @.DrivingHome := true;' A" q+ ^. X8 H' ?' ?( Q: L. H
                        end;# I- s  M8 i+ r, F
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
$ I4 Y4 p6 a4 Y( f$ j& c                        part := @.transpOrder;4 c8 D* s7 J) }& I! s5 S' l
                        part.move(@);-- load part" P6 L. u6 c+ N* n2 x
                        @.CurrIcon := "load";$ v5 x5 ?$ c+ z- B: i
                        GlobalDistObj := part.globDestination;% Q( C9 M8 x% K! N' G" u* x' C
                        assignLObj := rgmanager.rgAssignL;) E% B6 v  H& E; H) e
                        row := assignLObj.getRowNo(GlobalDistObj);/ X1 ~% F. s+ m' N5 F
                        if Row = -1 then -- since 70
5 m1 c7 I! |6 V* l                                if lan=1 then3 b8 j* g0 v. V0 y
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
7 A, a* M2 b+ P! y5 D7 F3 T" R                                                to_str("in der Andockstation: \"",?.~.name,"\""));' o' [3 O8 k/ H2 f9 y- u" ]  \: ~: {
                                else
: s, b: X; C  I* H8 e                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
: d* K( s2 S  x- G                                                to_str("in docking station: \"",?.~.name,"\""));                                ; [! @- g% {3 M1 _7 d% A
                                end;
4 H, x; G5 _' f) x2 J                        else
( K+ ^  J# {. I: ?0 ~                                @.Destination := assignLObj[1,row];
# v. ^# ~& u1 G4 @6 q                        end;                        8 E) o# _9 y  y9 m
                        newDirection(@);9 _) d$ m* l- d" B+ j- q
                        @.HasOrder := true;
# F6 t8 w  f  s3 W) [                end;. g1 J. U0 C1 E& f
        end;
' M1 S/ g, f$ p5 Aend;        -- of the method8 @# j2 n$ `& O5 n" G7 S$ f
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
& C7 p5 }5 A0 C; F5 Y8 t" h
: s9 y4 D- t, ]" d4 p这是AGV_putin中arrive的method。
& ~9 G( A0 x9 ?8 x/ l
2 |. Y! @2 i$ i+ z$ [/ b当到达物料速度越高时,这个报警更多,: q4 Q% I9 {* l2 ~! m2 R' q
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
0 U) V. q  |+ E程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
) x' g$ x( A2 E/ G8 n# ~/ n! {( p6 [! L9 h
另外一个小建议,就是move,所有的move都可以这样
3 h2 [3 q* \5 e* l$ Cif not move() then debug end
$ |* i' Z! f3 N% D+ h  ~0 a7 E5 L这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
; D/ }3 P7 O. L  l6 {( ~plant simulation中的free libraries有AGV模板,
) H# b; q/ p0 w里面也有案例。. G2 k5 a9 v( B$ n. ~0 C8 k
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
+ O$ C* F$ A! \  s. z
( o; |9 K% |: ]+ s7 @' d- l我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑   x$ W. G" o4 O/ n2 Q

" R/ ~* C8 s. B% [$ W+ A: L# s那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 4 \( T" [2 [$ R" ?, u1 B
这是AGV_putin中arrive的method。
+ @& \# u2 b9 u8 T* y
7 _; b% W3 [/ ?% h当到达物料速度越高时,这个报警更多,
( N8 |) L! C$ w$ O+ h. x4 U2 d: @
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-13 18:26 , Processed in 0.017828 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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