设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8393|回复: 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'
7 v" |& d& O  g& t5 v( J*/" T' u: P, m% z9 P, L
is4 H1 ]: _2 P8 d9 U$ N6 ^5 `
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
& w* d" n1 q% \+ ], _$ Mdo- @* l' b; Y; R, H
        Lan := rootfolder.Internal.Tools.AOLlanguage;
+ T- j3 r+ y: u" N        if current = @.Destination -- else return# Q: Y* \3 j8 g; i: R
        then
6 R; s8 k" B# C9 ]# d: u" f                @.Destination := void;
1 V/ l! G0 w$ Q) i$ `                if @.occupied then
, Q2 c% d. Y, F5 c/ {                        part := @.cont;# D; v* f) J6 p' P4 B4 ~( m( \4 s
                        @.transpOrder := void;3 ?) t! g, E3 [, u
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,# }" K, d, ~" g4 B) }
                                @,root.eventcontroller.simTime);
9 p4 [% m, Q4 [1 h. R7 B1 Y                        @.HasOrder := false;+ f9 o% b7 M  T- _& F
                        @.DrivingHome := true;
7 _9 U0 l% b/ R0 {7 n                        rgManager.tryToStartTransOrder;
$ S. Z  R8 B  Z! ]* U                        if @.Destination = void
% R4 l' E2 ?& D& E* D                        then -- no transport order for vehicle @
$ m! Y! n) `/ {* q                                @.Destination :=
) d* L8 l5 d- M+ k! n                                rgManager.nearestFreeStation(@,track.~);/ h/ c7 G7 d; o4 Q7 Z8 x; G5 c; r
                                newDirection(@);   
4 Y+ B6 q! Y( e5 t  W3 j. ?' X$ g                                if @.Destination /= void then5 |0 y" r( X4 g9 v0 \* ^
                                        @.Destination.NumReservation :=
% i1 C6 g: I) J                                        @.Destination.NumReservation + 1;
; Z- o8 H- m9 N; ]+ q                                end;
" ?6 l5 A8 i  l- E0 c9 F                                @.CurrIcon := "drivingHome";* f7 m% E$ N1 v6 @+ g5 A$ U, m
                                @.DrivingHome := true;
' j. s" G, i7 H; l                        end;
" K. v9 _& u) ^2 B' w                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
* w- J" G1 [  e                        part := @.transpOrder;
* o0 H, {& X9 t- x6 Y8 |7 k                        part.move(@);-- load part* C; L- P' Y" `- C+ s8 K/ F
                        @.CurrIcon := "load";
! j/ U/ A2 t- `' c; R2 ~  g                        GlobalDistObj := part.globDestination;
$ Y# \  s# |' P+ L                        assignLObj := rgmanager.rgAssignL;! }9 o7 O* H) _4 H4 s7 E* J$ B  [
                        row := assignLObj.getRowNo(GlobalDistObj);( x5 j8 r( u; m; A# F! h9 n& C
                        if Row = -1 then -- since 70
5 R& r6 S" y6 Y" F0 G. v/ c# q) ^                                if lan=1 then% b5 B# M2 g1 H5 p
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),; l: X) N* r( d! k
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
2 p5 O9 j& M) L9 a+ I6 l7 h& x7 o5 X                                else* ?5 I5 j1 E! Z& Y
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),5 S4 ^' y& x; |
                                                to_str("in docking station: \"",?.~.name,"\""));                                ) |8 ^( w& i6 T. x
                                end;
3 O9 C& I$ x5 Q: x; G7 v& L                        else
5 I- W. Y: T: g' H5 n( A  n$ [                                @.Destination := assignLObj[1,row];( W  f: d9 y  B. J4 x. g
                        end;                        8 ~/ S6 I- g) d5 [% Q+ l4 u
                        newDirection(@);) a5 H3 {) ^+ j
                        @.HasOrder := true;: J, h! m* {0 Q  m5 l& p
                end;. X9 l" m( H, L: c6 v; p  J
        end;
% A; Q+ x8 {2 W1 w% `4 d+ pend;        -- of the method
- l8 h" [3 e6 _. I! k% L
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
/ P" Y7 y, Y0 J9 S. f
. c- v- P; z9 f$ z2 G( e这是AGV_putin中arrive的method。
2 ]' P* Z2 [+ ^4 }' P1 a: E3 N' C. H) B* X
当到达物料速度越高时,这个报警更多,
; ~* }: M3 t- y/ N3 k+ d$ j可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。- C- p9 ]# f- i8 R6 @  T
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
8 x; E/ p5 p% G  F% e$ v7 |% j7 y; l
另外一个小建议,就是move,所有的move都可以这样6 Q) m+ q) Z% Z+ M( b! a
if not move() then debug end
% G- b7 f/ d  i, j这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。3 n( n0 ^" v( V# a
plant simulation中的free libraries有AGV模板,' Z$ Q7 m6 ?) w5 m5 ]2 r+ j  i
里面也有案例。% p6 \2 v, r0 `, P/ s# d9 b5 w
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
* P+ b1 C( l  ?0 M1 z; P. T2 ], \3 T2 V/ _5 `
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
( c% `9 S, |. K. Y) l) G
  M7 J* A2 W  c3 _那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
* w& U. ~% j2 Q( n5 v这是AGV_putin中arrive的method。
8 D$ {" g  P1 W6 ]
9 f& x6 F  V. W当到达物料速度越高时,这个报警更多,

! V8 }- L6 `* D/ N. P% P2 W另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-1 09:20 , Processed in 0.019952 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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