设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8808|回复: 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'. {3 e. q7 ]( f
*/- x2 p3 r3 L7 `/ ?& i
is, z- g: v, G/ u8 ~- \& r! Q# Z+ R
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;3 M: I2 G3 l9 H4 z
do
- p( w; }" D. M3 z$ q- u        Lan := rootfolder.Internal.Tools.AOLlanguage;5 Q1 |6 U4 f7 e: {+ F6 D
        if current = @.Destination -- else return
, Y! ^9 ~" W# A, o/ ~  r1 `( K        then
8 G: ~: j& U; W. G2 N% W( ^                @.Destination := void;9 @/ i! H3 V/ F% l
                if @.occupied then) N/ X) I: a  W+ P* |. C
                        part := @.cont;
/ v0 c  p/ \; w1 t8 U. G                        @.transpOrder := void;
0 B% @' q* `5 }: i                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,6 E9 v1 }7 S! o! o
                                @,root.eventcontroller.simTime);; @4 V: g- P$ A
                        @.HasOrder := false;1 {5 K) ~' K7 k! p" X4 v$ V6 I
                        @.DrivingHome := true;9 v) f/ Y) X' S  I2 q
                        rgManager.tryToStartTransOrder;
% O$ I3 j6 Z- ~2 K5 M                        if @.Destination = void0 g  E8 g* F( [
                        then -- no transport order for vehicle @2 R' F8 d- R8 G5 }8 I* O
                                @.Destination :=
0 K; @3 q, y* j                                rgManager.nearestFreeStation(@,track.~);) j* j. m2 n! f6 [: Z, r- {7 m
                                newDirection(@);   
+ M+ z9 e% i% i                                if @.Destination /= void then% g9 f4 U" G5 O. R( C, A
                                        @.Destination.NumReservation :=
6 A7 u' {9 O- f                                        @.Destination.NumReservation + 1;
/ j9 n& ^6 M+ t7 r8 S* N% U; x                                end;1 X# c! Y3 Y4 I+ R3 ?- G$ `4 V
                                @.CurrIcon := "drivingHome";
( P+ i8 Z/ w. y2 ]& o                                @.DrivingHome := true;
2 R, Q2 r# }# j$ a( q& y) W                        end;+ j3 \& U& A0 `: ]1 _+ H
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
! s% V% ~4 C, k4 W% _1 l                        part := @.transpOrder;3 j! |5 u3 w% k/ q
                        part.move(@);-- load part, [* {' y3 x' i+ `
                        @.CurrIcon := "load";
$ ]# k0 u; P4 S                        GlobalDistObj := part.globDestination;+ F% S$ p/ l- q! E. t- H( T! \, Z
                        assignLObj := rgmanager.rgAssignL;
" `' B! |8 u- a0 L& S                        row := assignLObj.getRowNo(GlobalDistObj);  \) `* Z3 z  Y# ]1 v8 g9 E. K) Y
                        if Row = -1 then -- since 70
' Z7 N: }& a  o8 J* ?8 Y3 Q                                if lan=1 then
5 y0 K; i: K) M5 P+ V) E                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),' x' j6 x  Q0 a* ~" Y' s. x
                                                to_str("in der Andockstation: \"",?.~.name,"\""));3 I" l1 ]) I9 ^  B, Z. z3 D0 P
                                else* P0 s5 ]3 T  U9 P
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
) M. U7 x. v0 I" o1 N' O' T; ?                                                to_str("in docking station: \"",?.~.name,"\""));                                / k3 j6 @) ^5 }9 G! I' ~6 N
                                end;5 S8 A( ]: l# \3 P/ l
                        else
( D4 }8 Z( ?0 `4 d+ E                                @.Destination := assignLObj[1,row];1 T, b( o. y7 l
                        end;                       
8 k( ~9 h* }8 R  f; |& w2 X% D+ ]                        newDirection(@);
' j8 ]+ }( [2 t, T" e/ q                        @.HasOrder := true;
  u4 h5 G9 Z( y1 e! O                end;
/ f, d0 T! W5 ]2 i  a. e% {        end;* j7 ^, o: l9 p0 Y7 B2 ]
end;        -- of the method$ ?9 a- a1 M4 Y2 j3 o8 Z4 M
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 4 |" f; R8 l! ^5 O' f

5 }$ I, B! T7 w+ h/ a; \这是AGV_putin中arrive的method。" M/ f0 M  b! i% s, G& X' |& b

: ?9 R! q6 G2 q3 ]9 s$ S当到达物料速度越高时,这个报警更多,
( n8 M; b. Z9 p5 ^- N/ K可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
7 T9 p7 F; ^! |8 E1 a' [程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?: i3 c' l# G. S) t
3 n1 ~2 l. W) N2 q% D* ^
另外一个小建议,就是move,所有的move都可以这样: |& Q% f" m7 k5 D4 p
if not move() then debug end" l3 f* z, V) O
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
1 j/ M7 A" d" Y7 u& Mplant simulation中的free libraries有AGV模板,
1 F: h( r& _" m$ n, E! h里面也有案例。
. y# T9 k/ Y! S# p, O7 P8 Q我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
) g7 o8 K' v4 A+ m  z$ c2 s$ g# ^4 c+ w' g, d0 n% i
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
; ^8 l, F% A+ u+ C: z6 h4 V* r# L
. {& g: d. ?3 i2 A% ]: H那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
% p/ ?6 T7 d7 K5 M这是AGV_putin中arrive的method。
6 g& y. W( g3 {" Y! O' `- s' @. \* N$ b. c
当到达物料速度越高时,这个报警更多,

1 \$ i  \5 J4 I& _' l! o& a另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-27 11:37 , Processed in 0.017870 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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