设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10216|回复: 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'
) o/ z$ j& U/ k+ i0 r; j3 J*/. B( {! B- {% }" q! P1 ^
is( m3 S, ~6 O% J  B6 x0 U0 B
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
' K8 z% ]4 p" Q7 ^4 R) jdo/ E$ L% R. R8 V: o- h$ f
        Lan := rootfolder.Internal.Tools.AOLlanguage;9 j: {4 g6 |$ ~9 y: k" n- K
        if current = @.Destination -- else return
6 f+ b( {6 N; b. j6 E! V( z        then1 Z4 k; E. H1 E6 p" n+ r
                @.Destination := void;2 `* A" {# y  K4 }& t
                if @.occupied then+ L& s9 n5 ]- N# L! q
                        part := @.cont;
# `" E+ S6 t" D9 [, ~- l% x                        @.transpOrder := void;
1 Z* j" M' F+ L" E0 ~+ x/ ^                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,: I1 I( V* |" [) h3 {3 r
                                @,root.eventcontroller.simTime);+ w8 r; c, U  |3 S8 S5 w
                        @.HasOrder := false;* ]6 i. q0 _6 {# q3 I5 \
                        @.DrivingHome := true;
' @( ^; e( g5 |6 W( S- ?. ?' f* t, v                        rgManager.tryToStartTransOrder;3 x2 f8 l' N1 _) N
                        if @.Destination = void
# v& E/ J, b( P- U1 Q                        then -- no transport order for vehicle @
5 U: Z0 V' l) _- W5 i7 L                                @.Destination :=3 G5 P- Q' w# ?5 ?! D  c0 L
                                rgManager.nearestFreeStation(@,track.~);8 a) \/ Q# @, O  }& ^  G. `" ]" L' d: D
                                newDirection(@);   % H1 O2 J' X) i# _% K
                                if @.Destination /= void then
: F9 u) x7 Y: ^! S2 m                                        @.Destination.NumReservation :=
6 k7 ?0 o. z( Z3 u* O                                        @.Destination.NumReservation + 1;
( {& C8 ~4 R$ {/ F; v8 g2 e5 Q+ q                                end;
8 N! W' e0 ]- \3 `1 y+ C" U                                @.CurrIcon := "drivingHome";0 m; K1 h9 V: n8 T4 s
                                @.DrivingHome := true;
( y3 E$ _! ^1 s, ~9 O# i                        end;
2 K% ^1 Y' |9 H  I3 E# a                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
8 S5 P3 T5 P6 G' |. K) Y                        part := @.transpOrder;: ?  Z; R4 G% ?* `8 Y5 W  B' N
                        part.move(@);-- load part
- l& t* V0 @2 X$ X5 x- B. c                        @.CurrIcon := "load";9 ]8 M2 e( M4 }
                        GlobalDistObj := part.globDestination;: n! h) S' P% N
                        assignLObj := rgmanager.rgAssignL;$ ?- N2 e" T* p
                        row := assignLObj.getRowNo(GlobalDistObj);
5 q. Q9 t# Z+ J$ J6 M0 z/ Q                        if Row = -1 then -- since 701 y2 K& c7 m1 c' X" x5 h
                                if lan=1 then2 R# i4 g* {/ P) Z0 @1 _$ y& v
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
! Y7 S  }, b& E- o1 ^                                                to_str("in der Andockstation: \"",?.~.name,"\""));
% }% r0 ]5 e' }3 W' i8 u                                else
* W9 I# c6 X" n" d. E; ?- Q                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),' E: X+ R& t0 ~7 h. V
                                                to_str("in docking station: \"",?.~.name,"\""));                               
* }* e: I3 T5 c- A: l                                end;
: J0 {" _( ?; Z! _6 c% z                        else
- o5 o6 H: m8 L3 `9 P4 s8 ?                                @.Destination := assignLObj[1,row];
2 m7 T/ X2 b9 Q, z                        end;                       
0 H5 v3 _, e9 V: G" Z, j; {                        newDirection(@);" {# m7 U& k, h* j: ]
                        @.HasOrder := true;5 o2 Y6 s" N# u' U' h
                end;2 T3 D! v1 T' B9 X8 W
        end;0 y, ]6 c# \  F0 Q. W/ E4 ?" _7 B% Z
end;        -- of the method' y2 y) d$ |9 A  J2 L0 Q
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 $ O2 q' ^) l( G% q- i9 J$ g7 Y. [: o! [5 M

2 a3 J# b; W6 c; k4 C5 }9 E# X这是AGV_putin中arrive的method。
% b- m2 |4 ~/ [, |( K2 [, s; n: j& ?) p7 \
当到达物料速度越高时,这个报警更多,8 y$ e6 b+ |- }- v+ z/ J
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
" t2 |# {" o% J" g6 F程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
% d: ?. K5 x6 x$ x4 K8 `5 ~: U. S2 ?7 y/ j& Z- O
另外一个小建议,就是move,所有的move都可以这样
- H& H/ P& I9 ]9 I+ _# u# M, yif not move() then debug end1 [5 w: C% L/ f% r- G
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。  U: Q$ a1 ?: h2 k
plant simulation中的free libraries有AGV模板,; D* I  t" ~3 M( S
里面也有案例。0 V6 c( ~' N9 n0 Z9 d. f8 N
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
: @* \1 a" H/ K! s4 V2 s: y2 p. [9 P, |& b8 r
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
# J* `! J& B: q) R; ^6 q7 r! S9 i! R4 g& x
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
3 g' A' ?: A: m# j* g这是AGV_putin中arrive的method。2 O8 P- p, p9 O. @  G5 L6 m) {& u1 L

2 H9 H3 k% X3 @0 m当到达物料速度越高时,这个报警更多,

, J& K7 W) @# A4 O3 l; P另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-20 21:18 , Processed in 0.021925 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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