设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7431|回复: 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'
# F% F2 }8 A6 X5 [+ J! n8 L9 Q*/3 `3 E1 O& ~" F/ k  |% ~5 R" K
is1 q# P0 I! X) r" ]! [9 f1 e
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;5 x- y8 ~3 {5 R1 ~; l
do8 x, j; R3 d( r7 @
        Lan := rootfolder.Internal.Tools.AOLlanguage;
( d; j5 W4 B5 F, o" k        if current = @.Destination -- else return7 t* J; v, [$ n+ }/ \6 U3 a
        then9 T0 r' e# W3 Y1 R1 f
                @.Destination := void;# g$ h' \3 d! P' L* u0 N
                if @.occupied then0 r. N& Y3 L- {- x0 G
                        part := @.cont;) V  H/ W2 X: b5 {# x5 l) c4 A. ]
                        @.transpOrder := void;" g. N" @% {$ _* J2 e
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
; [; q5 ?7 V8 u! I, o. @                                @,root.eventcontroller.simTime);
% u4 p$ X, a  M; e: T! p                        @.HasOrder := false;+ H. ]0 O9 ^: Q# b% _8 t. S3 b  U
                        @.DrivingHome := true;
- `# C6 W% y8 l) W                        rgManager.tryToStartTransOrder;
9 z8 W1 g: E2 T+ b                        if @.Destination = void2 N( E& E# @) {' d% O# a
                        then -- no transport order for vehicle @0 d: X9 T6 k* G3 O: y0 L) i8 m% }
                                @.Destination :=
- ~6 k  Q0 V8 f* D' N* m                                rgManager.nearestFreeStation(@,track.~);8 L7 X  i; ?7 y3 k
                                newDirection(@);   5 N* Z2 u2 f" I8 P) m; t
                                if @.Destination /= void then3 f3 r- j& L6 b' t' m$ G) E
                                        @.Destination.NumReservation :=
, j* i6 s- s( u/ ~: x2 i' ?                                        @.Destination.NumReservation + 1;
5 K2 d" u$ b1 q1 N0 A# }                                end;
; v  n8 k0 S) L1 g9 p% y# g                                @.CurrIcon := "drivingHome";7 r' g0 c' Q7 N# w! N# Y9 Z# L' D8 @/ ~
                                @.DrivingHome := true;- x4 x1 C1 ?& A/ m& Y6 l- ~
                        end;
) g" G3 d3 N8 y1 j+ \( H                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
: N. k( P- W) S3 q( A0 y8 k                        part := @.transpOrder;( K( @3 h5 h* ?. S3 G% Q) {
                        part.move(@);-- load part
  d8 a% y5 ?' A8 `& n6 O( |! o                        @.CurrIcon := "load";
1 E. p  G: T7 l$ x, n$ i4 n1 B                        GlobalDistObj := part.globDestination;% P' D9 Y! L, j* C+ s* \1 ~, n
                        assignLObj := rgmanager.rgAssignL;
8 |+ N3 q+ r+ ^# ~' R; P; g$ i                        row := assignLObj.getRowNo(GlobalDistObj);
/ z4 S: U- h4 k7 v                        if Row = -1 then -- since 70
4 w" j0 M0 a; B# h  |                                if lan=1 then
' m; R0 E! V% M& p* h5 \                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),* S' W6 U! ]% w% \9 F
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
) u% k5 b. Z  x3 {% V9 ]                                else4 {% K( E+ f6 \# Q
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),& _2 c4 r; Z1 a" X: u
                                                to_str("in docking station: \"",?.~.name,"\""));                               
  f. q: J) T; y                                end;- q9 U9 o5 h( V# L
                        else/ }7 C; ~; c% i
                                @.Destination := assignLObj[1,row];$ d+ U: Z9 t  V3 V: p$ H4 {
                        end;                        # _4 M) J' p2 q4 o% a5 m& z
                        newDirection(@);* s% Q  b, X  I
                        @.HasOrder := true;
* `, X+ V6 b8 e: L" A# E  `% U; ~3 s                end;
4 `7 O' w. j, n4 r. ^        end;
1 ~8 L0 e3 E' k/ Aend;        -- of the method5 C% M+ D* p& m
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
9 }; l& Z1 i% I4 M
0 g- N8 i2 `3 [. ^& g这是AGV_putin中arrive的method。
+ t2 {3 ^0 O* ^9 g% v! S
7 z" h6 B( ?! O: A. [7 Z当到达物料速度越高时,这个报警更多,& P. n" b& b; P, h7 w7 I
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
/ d7 `3 `8 D$ C+ _  @4 A程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
& R* k- s1 d% s6 L4 I; V8 u! u* q' ]: e4 w8 i7 d* I
另外一个小建议,就是move,所有的move都可以这样
0 Q* X; W2 z% o- X2 {if not move() then debug end0 K  p* J7 T( P9 M  b- M
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。8 u6 Q: G. ~. O3 W8 z0 f# q
plant simulation中的free libraries有AGV模板,
: [9 m* S8 ^. w里面也有案例。- s! |& ~: ~) g# c) q3 u
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。3 N: S, a/ ], c0 R& ~

& p% H- z' s, L2 o: D我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 : M6 W& S6 j/ b/ o4 s* ^
3 D' r2 m: H$ G, d4 i$ L( a
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
+ f- [- v+ G$ `; p这是AGV_putin中arrive的method。
; y% X4 V* v8 \. I
9 H: p( S) h  p: ?当到达物料速度越高时,这个报警更多,

/ R; Z( J2 R+ @7 @1 J7 _- }1 ]0 B另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-11 03:24 , Processed in 0.023881 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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