设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6797|回复: 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'
* B" C) E3 j! a; G*/
% t0 r- |  ]* Y& \is
- o9 |/ b6 W6 |        part, GlobalDistObj, assignLObj:object;row,Lan:integer;" P, |1 l; c  d. a
do6 \5 _0 _9 c& Q) a/ h
        Lan := rootfolder.Internal.Tools.AOLlanguage;0 G, E2 A0 [0 l- ]& J
        if current = @.Destination -- else return* k) J! k0 _2 ?0 T* x
        then) p! c6 N) N1 V) }0 G# y
                @.Destination := void;; [/ ]5 {" k; m4 }+ I
                if @.occupied then3 k, t5 ^1 }; N/ {
                        part := @.cont;$ |5 n, H. p6 G7 w- ?( T& L+ ~
                        @.transpOrder := void;
: S, o# ]: @6 H  ?- p6 F  o, _  d                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,+ E/ C: o8 k9 N# t* F, T
                                @,root.eventcontroller.simTime);1 Z+ n2 I& @, P" K1 L8 F' U( X
                        @.HasOrder := false;
/ d, o- \, m. s4 x& [7 e3 j4 o                        @.DrivingHome := true;4 l; q: t3 {1 W! M$ K
                        rgManager.tryToStartTransOrder;* `, Q6 ]9 k2 k% X/ Y' n
                        if @.Destination = void
( C1 j$ s8 b) h, U$ x" q5 x                        then -- no transport order for vehicle @
( e  V  a% W2 z5 m                                @.Destination :=& u" H3 q( n  P4 Y# Q
                                rgManager.nearestFreeStation(@,track.~);/ m' y9 P$ n  n9 j: E7 K
                                newDirection(@);   
  g2 U2 e1 p+ m( O( d$ k                                if @.Destination /= void then. f) t9 b0 Y- j8 _3 @# G
                                        @.Destination.NumReservation :=
$ a3 r0 Q4 \7 _) S& N+ o6 B; \7 D                                        @.Destination.NumReservation + 1;4 a% Y4 }/ i, C7 h( y3 e
                                end;
. B8 l* z. G9 B6 i3 K                                @.CurrIcon := "drivingHome";! _6 T: N- A& n+ y, K$ ~
                                @.DrivingHome := true;1 R4 i0 j% h$ t
                        end;5 t) _8 k- w1 Z# g
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
+ R" T4 _9 F3 I5 ~                        part := @.transpOrder;
* ?$ c3 M: K( B$ |# o5 W) U! S                        part.move(@);-- load part
2 U3 W5 x5 z# X0 ], H8 U" W) C4 N                        @.CurrIcon := "load";
& ]  m- w/ J: {3 j( e                        GlobalDistObj := part.globDestination;) a4 i. ?. t8 r% R, w# X
                        assignLObj := rgmanager.rgAssignL;
* V# R7 C: Y/ o# R                        row := assignLObj.getRowNo(GlobalDistObj);
( u3 D4 \' [. p7 E                        if Row = -1 then -- since 70
, e5 k/ A( e" Q+ W8 n' ?! T( V                                if lan=1 then# n  E( G- V  c/ ]% `- D4 u
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
% S8 v9 W# L. d5 z- {& _                                                to_str("in der Andockstation: \"",?.~.name,"\""));3 m& `- }( J* D7 g
                                else- x8 m" R* G. g% I5 V" C- F) u+ w
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),; W7 `, ?8 p5 _- j& t' p0 v3 P/ p: ~" @
                                                to_str("in docking station: \"",?.~.name,"\""));                               
2 i0 z5 F/ `) l) p( S2 o3 F. q, ^                                end;3 K; _/ f  a% c9 M# x
                        else0 `7 w0 s! ^& [: [
                                @.Destination := assignLObj[1,row];
' h% m* V( z6 R6 t                        end;                        / l4 T- F1 S& \2 G1 O5 Z& T' A1 z5 b
                        newDirection(@);1 n7 n: \. S0 C+ i5 K! Y
                        @.HasOrder := true;- T/ U. D4 W- l9 C4 D0 X
                end;
! ^9 G# L7 `7 G* B0 R6 j" Q        end;
. C) |1 q. ]3 A' q; dend;        -- of the method
/ t8 C5 Q' q8 I& j: R1 u. @
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
) w7 z2 }; c2 z8 s; [* _& [2 F. [' L0 Z, F0 I% [
这是AGV_putin中arrive的method。7 d; v% t  m$ G
; a$ ?; B# e0 h2 v. P+ O& P
当到达物料速度越高时,这个报警更多,  h& l5 E5 T" g+ P
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
$ `/ P! J- p2 M+ l! d. ], P程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?. F3 m2 r; ^: v& q  X: ~9 W  S

" O, h! h% f8 o9 K: e% {* q' \另外一个小建议,就是move,所有的move都可以这样
3 O9 `( C; }% _0 a2 Uif not move() then debug end
& Y6 I2 d) a8 s  d8 Q" ~% b这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。  H5 ^% j* w; E/ o
plant simulation中的free libraries有AGV模板,- E- t5 `* ]% Z+ t  T
里面也有案例。
  T" F; C. X- l  R% n) U我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
8 L& d) a/ k9 P. L9 @% e4 ]6 z1 O  N# Z8 O# N' Q
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 # Y3 e. p( R# p" d% I6 @. Z( o  L
8 G1 y4 o, V& `2 _$ j
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
  t  J- E; N- \这是AGV_putin中arrive的method。% z4 t5 O3 |) A$ j" ^6 B
" ~9 h/ B9 {! R
当到达物料速度越高时,这个报警更多,

- B4 t- H1 ?0 J' v- A/ N另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-27 06:41 , Processed in 0.024183 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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