设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6009|回复: 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'
: i! ~& H& v+ S- `, [2 F5 L, \*/
9 z% P$ {* s. _3 ~is
5 S  ?# q2 V2 A& a        part, GlobalDistObj, assignLObj:object;row,Lan:integer;/ Y  V# r6 B% w( u6 P- I
do8 s) R1 w5 i- y9 G
        Lan := rootfolder.Internal.Tools.AOLlanguage;: T7 D1 q! h# M& o5 F& t5 f+ C
        if current = @.Destination -- else return" i/ e2 v" Q# v# }! {$ }4 o  i
        then
# k  t7 t7 w$ N# G7 _9 ]) W3 D- D& `                @.Destination := void;( z6 w- [: c) n9 ^4 B
                if @.occupied then/ q* n/ P% C! X* s% c& \
                        part := @.cont;4 O, k4 D9 d; F: r' b
                        @.transpOrder := void;* N  P+ H4 X) i. Z
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
7 q8 s  [4 P. [" O# f& [% Y                                @,root.eventcontroller.simTime);
, l* H/ K2 N/ `" O! M                        @.HasOrder := false;
0 I( e7 g& d: Z7 K                        @.DrivingHome := true;
0 h) ~; e# F/ i- r3 v- O                        rgManager.tryToStartTransOrder;* D; C9 l9 e, w+ n
                        if @.Destination = void
& @% e0 f7 n3 ^, s8 b! k                        then -- no transport order for vehicle @8 J- P5 G2 y8 x) D: r- y1 k
                                @.Destination :=
& J4 [, I4 X& q$ i9 A. R                                rgManager.nearestFreeStation(@,track.~);6 n' Y. {/ p1 g6 v
                                newDirection(@);   2 X& a, y/ o1 m- m9 L
                                if @.Destination /= void then
9 V& b2 Q% y3 V- W- l# Y2 d                                        @.Destination.NumReservation :=, s. M3 w  G2 O# a2 h1 y
                                        @.Destination.NumReservation + 1;) x: U: |0 h, T$ m0 Q2 [
                                end;
; M1 A4 m$ F7 Q                                @.CurrIcon := "drivingHome";, D( i/ J( B  k* T% z8 D
                                @.DrivingHome := true;
6 K6 X; Q) `3 J5 ]                        end;7 ~+ x9 x6 t2 j1 \5 O* o9 P
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station. c- t$ Q  P. Q& O3 m/ v
                        part := @.transpOrder;
; t$ y( j& l/ S. n                        part.move(@);-- load part" x5 {' W# J. C3 F
                        @.CurrIcon := "load";, ?( ^. }' R) Y" {
                        GlobalDistObj := part.globDestination;
  D  M2 S: k9 q5 r                        assignLObj := rgmanager.rgAssignL;
- L. R$ J. B5 _; z8 K" q, a5 F                        row := assignLObj.getRowNo(GlobalDistObj);  v! n0 z1 N7 R) b' j5 J
                        if Row = -1 then -- since 70
7 @5 `3 k! Z) o: A                                if lan=1 then
$ Z" z2 r& Q" h' w3 s8 v6 a                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),7 L% ?8 }" n- ]  _+ ]0 r
                                                to_str("in der Andockstation: \"",?.~.name,"\""));1 e/ ?9 [8 O% j
                                else: j$ i+ L' u2 M% i
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
/ x; J) S  c( S( {0 m$ G/ a                                                to_str("in docking station: \"",?.~.name,"\""));                               
. |2 [' m$ C% ~/ q                                end;
8 ~. p1 `( ^1 b* |% p0 m                        else
+ w7 ?8 }; l; S2 @0 s* M- h                                @.Destination := assignLObj[1,row];
) A  t0 X3 ^1 l) [+ x; H5 I1 y                        end;                       
! J" N) b8 [( ]& k                        newDirection(@);- X: L" ?9 c! Z
                        @.HasOrder := true;
8 W6 f, f) {% D5 \+ y                end;6 b2 Y, p% ?# o& P
        end;
$ Z. w& E8 l  h- Pend;        -- of the method
7 Z3 n" G* S- n: f
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
: R0 R# h* [6 x
, o: a# M* l/ z. B; ?8 ]这是AGV_putin中arrive的method。
. M& z  s1 I! r; R& Y8 I: y* ^! H
$ L1 r2 u, K' w0 I当到达物料速度越高时,这个报警更多,
/ F6 M1 F+ Y; y- N# g可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
" g5 E' |8 U8 `1 w程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?+ I7 f+ ^9 |" q9 R

. g- K. x! o- Q  y/ Q* V. W另外一个小建议,就是move,所有的move都可以这样
0 Q2 S* t0 c* {: X& ~7 P' L/ mif not move() then debug end
6 G& d" C! `1 m/ u! z& }; U这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
9 i3 n, P- \% p+ p( [plant simulation中的free libraries有AGV模板,
" f" X; N: R$ a/ W里面也有案例。
3 n: X" f) Q7 Z9 g我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。$ F7 H, c2 j. j2 Q2 A- t

! I3 [& _/ t# a+ R+ k  h我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 4 }* {6 [" w0 x: D0 L9 H" Y& t  B7 e
" e+ w9 E% B0 s0 ^( v
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ) W1 j! ]' ~. t6 W) p
这是AGV_putin中arrive的method。
2 ^+ i5 ~! s0 z5 f5 a* g
# J2 s. Z7 e& ?+ N  t当到达物料速度越高时,这个报警更多,
1 D: E1 a, d4 ~
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-12 17:41 , Processed in 0.020384 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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