设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6371|回复: 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'
; L# }& Q" y% @% ?9 Z*/
& G2 P+ C/ t5 S8 `is3 ?4 S* E. j; }8 H
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
  x% L3 R7 q# |5 X9 e) b2 [do* d8 y1 H( x7 ]
        Lan := rootfolder.Internal.Tools.AOLlanguage;, D) c  {* ~3 |9 K
        if current = @.Destination -- else return, q- W; r2 A- A: y
        then% B# k7 k% y) l) _& V
                @.Destination := void;
2 h( f4 Y5 |( l, d& }8 q! X                if @.occupied then
: I- x/ Q1 ?+ i2 F: s  z) I" u! n                        part := @.cont;. Q) `1 `( A  A. W4 B
                        @.transpOrder := void;2 m' m- f( f0 y" p( i4 g
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,9 l" m; n! t3 \' X- F6 k
                                @,root.eventcontroller.simTime);, f0 b$ q6 H) u6 j
                        @.HasOrder := false;4 S8 l8 r- X5 ~3 u( k9 K
                        @.DrivingHome := true;
9 y0 r) P$ j  I( _8 K6 j9 t$ E                        rgManager.tryToStartTransOrder;; T; E5 E& e' F* L: C- t& R1 a  W
                        if @.Destination = void$ v. U! t0 Y  v* \# P! y) p2 r
                        then -- no transport order for vehicle @7 s& n; _3 C$ {  W+ ^( f- [/ s5 x! x
                                @.Destination :=" v1 j0 ^* ~* T1 M( L
                                rgManager.nearestFreeStation(@,track.~);
# o. R9 @" Z6 o+ \, m                                newDirection(@);   4 ?: T* M% N  m, i- W8 j% g  T, M6 Z
                                if @.Destination /= void then
/ _. u' R$ Z+ B8 p, ^) l: J- x                                        @.Destination.NumReservation :=
$ _; b% U6 A2 k1 ?8 u* r- t1 u. Q                                        @.Destination.NumReservation + 1;7 e* }* E6 K+ R5 p, U! g* K8 O
                                end;
# f, k$ b! O* k& s7 y1 R                                @.CurrIcon := "drivingHome";8 l2 Z: a0 M1 v: _1 s
                                @.DrivingHome := true;8 ?8 h5 V0 e9 ?
                        end;
& n$ s1 O9 {( N8 E1 V$ S                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
1 [8 ]; h& L4 k4 A- P1 m, H                        part := @.transpOrder;/ d! L4 |* _: a- W6 o
                        part.move(@);-- load part
) @1 S3 c5 J# c$ _! A" r0 E2 p                        @.CurrIcon := "load";
' f- D; l3 w3 \% V                        GlobalDistObj := part.globDestination;% M2 v& A/ Y2 ~
                        assignLObj := rgmanager.rgAssignL;$ x" P% B# n8 ?" X) j, n
                        row := assignLObj.getRowNo(GlobalDistObj);
: Y/ b% g) {: i. Q                        if Row = -1 then -- since 70
$ U; K8 {; X0 d% k                                if lan=1 then0 X3 N- ]. N% G3 ^
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
! Y- ~; |3 `' _8 \) p  N7 C) {                                                to_str("in der Andockstation: \"",?.~.name,"\""));1 [  U0 w1 T- S+ ^+ Q* `) [
                                else
& x% M" @3 ]  }; \                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
5 H7 n) Z$ p. A0 ?                                                to_str("in docking station: \"",?.~.name,"\""));                                7 I& Z# l2 L6 V
                                end;
+ c- x9 z' E. ^* x0 x: M4 ?                        else
  U% f+ ~: q+ [6 F. @% K                                @.Destination := assignLObj[1,row];
5 t" S5 i0 O0 r+ N: i- d                        end;                       
+ }8 w' K& M/ Q" x$ Q! F                        newDirection(@);: b+ x0 ^1 v3 F, T/ N2 {
                        @.HasOrder := true;+ Z( t2 x) e2 N% c, x. ~. H1 ~" t
                end;
6 c( s: r% y3 N9 X        end;
/ O4 }2 h0 d4 n# n2 I7 t, W% yend;        -- of the method- g0 k: T7 b) b6 s1 W! a/ v! d. X
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
( w) Q! W2 ~9 z* p0 H6 ^
* K' N  I: A0 x% k7 h这是AGV_putin中arrive的method。
. N; A; o1 ?. J5 l( q
8 M4 t' H# f+ A3 y2 F! ?当到达物料速度越高时,这个报警更多,2 v3 r+ d5 D7 l: _- u
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
! x6 k3 [/ x$ G, V5 L程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?* W8 a' e+ x  A$ J4 z

8 a8 }! F* U, [* ^8 w# Q& }, \另外一个小建议,就是move,所有的move都可以这样. |* @: L! ?  F* v5 z. V* b3 Q' a& _4 T
if not move() then debug end
! ^9 h1 ?# q, @( [+ X, J这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。' M$ D' w3 L" G; }- j
plant simulation中的free libraries有AGV模板,
0 F* e: {# l7 l  b: e, X里面也有案例。' y$ M6 ~$ u% F- O+ y2 F5 S
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
0 ^% m) L8 x! M8 [; X9 i
# W- p8 |- A: ~: ], _1 T( A2 t0 L我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 : S/ }7 Y0 X- \, x' g* M

+ `! S! y/ b( l6 I  F那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
1 d% O2 K% w/ ^0 a: C- q/ Z) u  X! S2 k这是AGV_putin中arrive的method。4 {3 ^- A0 F9 K7 v9 X( }& j' F
# E/ K: s* i( H* |# |* u% _
当到达物料速度越高时,这个报警更多,
( D9 R! C* z" C
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-2 11:04 , Processed in 0.022243 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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