设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5494|回复: 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/ x7 v# e5 P1 E3 O
*/; g$ D7 C# g$ _7 x( Z) y0 R  t& x
is
, {: S6 c; S2 N7 t8 g8 \& p* G; ]        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
5 O( A8 A% q! c+ ?do; |& ]3 ]# @9 q3 V9 U
        Lan := rootfolder.Internal.Tools.AOLlanguage;
0 n& X# {& H/ t        if current = @.Destination -- else return
* c" I3 q$ j5 g: i, F        then/ N; i# z/ D" q
                @.Destination := void;, w: c3 D8 ]/ A# @& F
                if @.occupied then
) i2 G  I$ T, o/ o" W3 n                        part := @.cont;
* g, j; v; _  i: V3 Q' X                        @.transpOrder := void;
) m4 A( ]6 s3 o9 T                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,4 _. k/ X6 Q4 [( ^1 o4 q5 K( b
                                @,root.eventcontroller.simTime);
0 g$ g, a& X% Q# [* a                        @.HasOrder := false;& S" {% S8 N$ }6 m5 p6 H# e
                        @.DrivingHome := true;/ E) U  Q3 y5 |
                        rgManager.tryToStartTransOrder;
2 f3 g: I7 A  H5 }$ o- E; T& }                        if @.Destination = void2 c3 F( K3 s2 J% D5 I2 i; p
                        then -- no transport order for vehicle @4 E- K  p% ]5 [
                                @.Destination :=: C7 c8 ?( O' m
                                rgManager.nearestFreeStation(@,track.~);9 ?; P4 E5 d# q/ D- z) W/ z6 }
                                newDirection(@);   
; Z: B2 F. X, H1 s# `& S3 }( o                                if @.Destination /= void then7 c1 @. A5 `: X) }6 Z% A3 H
                                        @.Destination.NumReservation :=
$ O, {$ t& u! e) I: c& K                                        @.Destination.NumReservation + 1;
' z& S, L# R; m4 K8 z  }+ F$ Z                                end;% Z& ?* H8 w  f( S" ~- O
                                @.CurrIcon := "drivingHome";5 a# n% h* A7 @! W2 Y. M
                                @.DrivingHome := true;
* }1 @4 b5 O! T3 c! j, h- M2 S                        end;
6 w5 `+ p: e; n' {$ F$ `                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
) }# D/ J2 |% S% U; ~) L0 h                        part := @.transpOrder;3 ^$ [4 x$ M8 N! h! k
                        part.move(@);-- load part$ l- D7 }" g2 U& B% L. h! l
                        @.CurrIcon := "load";: e; Q: N1 s- ~9 @4 }
                        GlobalDistObj := part.globDestination;
2 _: o  |8 r9 u$ v  D  k                        assignLObj := rgmanager.rgAssignL;
, A4 p, ~6 e5 I2 f2 h                        row := assignLObj.getRowNo(GlobalDistObj);( X. X4 M5 x! V) [5 |2 @" I' O9 r
                        if Row = -1 then -- since 70
9 G5 q* n+ E) `# i                                if lan=1 then' U) Q* K3 `4 z8 V) ]7 g: `: s5 H
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),% U7 c8 G# V% q0 v
                                                to_str("in der Andockstation: \"",?.~.name,"\""));. v: D- ~# N! e% L. c+ T2 H& y5 g" S
                                else, G% J5 z) C; F% B
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),3 v+ V, O* L; T  t* ~
                                                to_str("in docking station: \"",?.~.name,"\""));                                  h. U9 U- w, D$ G
                                end;2 L2 @% L. O# g% V4 x& T. ]
                        else6 w+ g1 ~* P& ?( z$ X5 |
                                @.Destination := assignLObj[1,row];
- p7 d1 A8 }/ O                        end;                        & T$ x5 I2 J% M+ W  Z% X
                        newDirection(@);; f9 h; w8 @" M1 W/ g
                        @.HasOrder := true;
! Z: T% Z2 C5 L0 e7 _% i. P) N7 W                end;
4 q5 r; i' I2 w9 f1 E3 H        end;
1 t, ^: K0 _8 G& Aend;        -- of the method+ u% e6 I" H( n# r' J* B% p& ]
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ) j8 O+ _. T2 G# f
9 H0 y, X, C- w2 b
这是AGV_putin中arrive的method。5 f0 ]! @( W& M  K. ^" o

. G2 ~' q* M) l0 E6 S; B7 @当到达物料速度越高时,这个报警更多,
' w( P: j. {" U1 E# t5 q可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。: ]6 T$ W& Z) ^# r
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?3 ^5 i0 C/ c( O, E! P" B# m

) o& z. m+ N. D1 [: u" i. \% {" ?另外一个小建议,就是move,所有的move都可以这样8 k8 I3 Z- O" b/ ~5 x% t4 N4 ]
if not move() then debug end4 C) n7 b7 l9 x) `, U& Q9 @
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
% Y, V1 J5 Z" V* J* Fplant simulation中的free libraries有AGV模板,
* i( g$ _5 J# n: y里面也有案例。4 \- I- l9 P. [$ p9 \
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。0 z+ ]+ A4 u4 g& v. [/ K

3 C9 T. p0 p3 K- h; l我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
- E; @: Q" j+ Z+ Y0 T# `& ^3 \4 S% u9 }. I
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
3 g% D( H- H+ |* Y% L' ~这是AGV_putin中arrive的method。4 \6 n6 U$ K- d5 m

* Z9 g' z7 {' _# A8 z+ g- U! Q当到达物料速度越高时,这个报警更多,
: n" |$ ~/ H" b2 S. c
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-11-27 23:02 , Processed in 0.017354 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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