设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7689|回复: 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'! g# ?: X1 E8 w8 S
*/+ K+ C- L8 O  e$ N% n5 [9 l
is) x6 N6 j* |2 l- e/ U4 {# b/ K) X
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
0 W! A1 }4 W1 p( Fdo$ h0 D+ ~8 l8 o. f
        Lan := rootfolder.Internal.Tools.AOLlanguage;3 ]6 f7 S' X. j0 A" Y
        if current = @.Destination -- else return
3 C& K2 w! j& H, @* |7 C        then
, D8 m! `+ E: a; r                @.Destination := void;
: j: Z# |4 Z! Q$ E7 ~* V                if @.occupied then) I, {* Y( [2 m* d! B
                        part := @.cont;
, X8 y! g& G' W* M7 d                        @.transpOrder := void;
. T5 y, H1 k- n% d6 S                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,0 E2 G, Q% i+ h% S0 K  U* p: _0 }
                                @,root.eventcontroller.simTime);1 |. s# t* z0 V1 q
                        @.HasOrder := false;
( x5 u. R3 p. ~; r                        @.DrivingHome := true;, \/ ]+ I7 I. P: ?
                        rgManager.tryToStartTransOrder;8 a) W" Y) x3 u
                        if @.Destination = void; t; A% a9 T9 R
                        then -- no transport order for vehicle @
7 T- N$ O# |& j- C                                @.Destination :=
# {5 j2 J! x7 {2 q: Z1 h! p$ K                                rgManager.nearestFreeStation(@,track.~);
+ d  M, Z9 ^, K8 G! @9 s3 f" g4 @                                newDirection(@);   
+ h2 P! w" W8 s* g                                if @.Destination /= void then
3 d' q# K6 w2 L/ j7 W                                        @.Destination.NumReservation :=
0 i, {: P3 r7 ]& x) R/ w                                        @.Destination.NumReservation + 1;
7 p# `; T, |0 r2 C( {5 o- n                                end;5 G7 y" A$ n" J, I+ N2 h5 [+ D9 G& L
                                @.CurrIcon := "drivingHome";
$ u* b. f8 y6 u$ r3 T                                @.DrivingHome := true;
1 f1 x0 P6 Y$ K1 M6 a# h* Z                        end;5 b5 j$ l; M+ n; q1 o0 @& V$ P
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
3 e% t, O0 x2 J' t* {4 n                        part := @.transpOrder;6 r) z4 _; s" }" \# C7 y
                        part.move(@);-- load part1 n! t9 G- n" |
                        @.CurrIcon := "load";
( `2 u7 B: W: z9 Z: b, ?8 e5 i                        GlobalDistObj := part.globDestination;
( V7 O( V. F: }1 Q# b$ [                        assignLObj := rgmanager.rgAssignL;/ x. k; k" f. {
                        row := assignLObj.getRowNo(GlobalDistObj);
* \$ x+ ~$ h0 \. z+ s) Q1 J                        if Row = -1 then -- since 70. q* @% f& \8 u. H. K
                                if lan=1 then! T& l0 d# q1 g+ F
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
1 x  J+ f) D0 d6 T                                                to_str("in der Andockstation: \"",?.~.name,"\""));
9 K/ Q7 A. k4 }+ N0 H0 Z                                else
: B9 U. d1 e9 N2 K                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),4 J4 Q7 t3 C5 y6 u. n" Y' H
                                                to_str("in docking station: \"",?.~.name,"\""));                               
- _5 F6 L9 w( q8 T2 \" Z7 K) Z0 ?3 ^                                end;; x* }2 p" ]1 G- ]
                        else
. ^( X0 t3 M1 `, S' s, F9 o6 P                                @.Destination := assignLObj[1,row];
$ |+ i" e/ V/ P& `0 D; A                        end;                        " R+ }# g2 m* ]  H0 t5 A
                        newDirection(@);% ^( |) \7 z, a( |/ N. O$ H  C9 W
                        @.HasOrder := true;* t! [) ]3 d7 X. z0 p
                end;  t0 }$ z* V: ], L! m2 ?
        end;/ G& |! s* I7 t- {+ A( Z1 M5 J6 g9 W
end;        -- of the method' q( y7 Z' u: m0 b1 h
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 4 X& {) _! L0 h0 r8 K" V  D: c
) e6 d, d* U9 Q% O2 c5 I
这是AGV_putin中arrive的method。# {. i8 U% t& G7 A
5 i9 M/ _" e5 e+ X4 J$ U; A
当到达物料速度越高时,这个报警更多,
) z' s, i. m5 H, r% e1 K/ F# ~0 w. u可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
7 E' {* n7 `  s0 X程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?3 E) ~& U, N; l% f' x! K

) j4 s  q4 i; d2 `0 Q' g* ?7 S另外一个小建议,就是move,所有的move都可以这样
1 \3 F0 b0 _4 t6 z6 k1 S$ ]if not move() then debug end
' e$ `0 b" s# }3 S9 r4 o+ J这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。1 H( H: M- W8 `7 \5 J
plant simulation中的free libraries有AGV模板,, d4 c2 u# R1 Y* d$ N1 f$ n
里面也有案例。9 H. s0 J8 H/ S4 G3 Y. N
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
+ u  n! m! |1 _, K1 L* A' O6 S+ v) d/ N' i6 B6 V0 H
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ) K4 l- f5 r, A
4 k  H* @) o6 H- F3 R( R
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
% Y; D1 z# t6 I6 W0 X( O. a5 ?9 n这是AGV_putin中arrive的method。* U0 B6 F0 F9 j6 F5 M  E. B

4 p/ i8 x  t0 m4 x/ J* H当到达物料速度越高时,这个报警更多,
+ ^) \2 o: H5 h. j9 f$ p9 a+ r4 u: X, H1 b
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-24 08:24 , Processed in 0.018412 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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