设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8589|回复: 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 V: S  i+ b. `, x( k, u) s*/% Y( A' X' x* N$ c1 R
is9 G% X* H. r% ^* ]
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;3 p% Y5 O7 O! q" F
do
; e" N( T" c% e5 c0 W1 }" r$ B% X        Lan := rootfolder.Internal.Tools.AOLlanguage;
& K# N+ F* h3 ~        if current = @.Destination -- else return! j7 S7 i3 m! G- z2 b1 b
        then
* J2 g/ G5 R- K9 E1 A                @.Destination := void;
9 r2 `7 \4 U9 Y8 _5 e4 M  ^                if @.occupied then
! h* E* v5 \/ d% g" Y8 v- \                        part := @.cont;  C2 [7 W4 ?+ p% z& V6 Z! F) s0 X
                        @.transpOrder := void;/ U' `: @* ]8 G$ a) C8 e
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
, H/ k0 P* x% O3 R* M( d: ?4 A                                @,root.eventcontroller.simTime);
' h4 q! W8 ?6 r- N                        @.HasOrder := false;) Q2 }0 ~" g5 G) ]) m" u
                        @.DrivingHome := true;9 E  h; g8 P& B  k  y
                        rgManager.tryToStartTransOrder;4 Y' G. d3 }& _* U
                        if @.Destination = void
' `, Y. C8 l; ~                        then -- no transport order for vehicle @; K! l! _( H0 a. a$ _0 I) y( C
                                @.Destination :=# j/ |5 O  b+ l& \) w7 k! K8 L1 i% `
                                rgManager.nearestFreeStation(@,track.~);
/ \9 k0 R& ~- w# I/ m                                newDirection(@);   3 x' k& {* f0 \$ `% [( x
                                if @.Destination /= void then( @* X3 m) s- _+ O
                                        @.Destination.NumReservation :=" m. L2 u6 U3 o* {
                                        @.Destination.NumReservation + 1;
$ V4 G# b( [0 a# }0 u                                end;6 J2 `6 f5 ]; w5 Q% z" |8 `
                                @.CurrIcon := "drivingHome";
0 ~$ Z* u5 q: g! B2 e( n0 Z) G4 V                                @.DrivingHome := true;
' V+ {$ \! i* j# f' Y                        end;
/ f7 f8 v) y. F! G4 Y# u  U" h                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
" b# N2 ]: t" J$ F. v                        part := @.transpOrder;
& }: w+ u/ I% [8 N                        part.move(@);-- load part
5 R# Y* B- D  a- d# ?                        @.CurrIcon := "load";
. R( v8 m& a1 y; P7 @* r( z* Z* _                        GlobalDistObj := part.globDestination;
# D4 x+ N2 i  k) m( H& U5 |                        assignLObj := rgmanager.rgAssignL;* A+ e8 f. y, H4 U8 N* e, o: k8 s
                        row := assignLObj.getRowNo(GlobalDistObj);
0 K0 U( e- X. {% A5 B5 Y7 f                        if Row = -1 then -- since 704 m# J  Q  I2 ~+ [4 ?" g1 H
                                if lan=1 then* r1 s3 {: b+ A$ Z7 {
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
$ }2 i+ z9 ]9 R& f8 Y& }) j                                                to_str("in der Andockstation: \"",?.~.name,"\""));
- S' G4 R/ b& F/ {, p                                else5 J" l" y+ d, R# x% N  }
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
+ L; |* ?0 U$ m9 h                                                to_str("in docking station: \"",?.~.name,"\""));                               
. \# Q& |; h1 [0 U/ U! Z7 L                                end;
; r8 t- q5 J2 u3 G                        else
% c7 |. s( }/ e1 e$ I  g9 g                                @.Destination := assignLObj[1,row];: ^8 }: Q/ Y) O- {& w
                        end;                        ( B; Y" A# i4 ?8 W* E' u+ ]
                        newDirection(@);
. U( C6 X7 ~0 r7 t                        @.HasOrder := true;- I( c" |8 p2 o$ o3 D
                end;
0 E  N2 ^1 ~3 y2 U0 l        end;+ D) v" S. ^# \9 [) f. b$ X9 t
end;        -- of the method  t; s- w  a4 T5 z% m! h
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ; I- \2 F% J& e/ d. V
. Q) e$ O6 p) Z
这是AGV_putin中arrive的method。( u; N# f2 R: M

4 }4 J8 l9 T- d) |0 O9 N* J' Z5 x7 s当到达物料速度越高时,这个报警更多,4 P% t4 Q+ u8 r" ]7 o+ ]! C
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
1 k1 \7 ?; U! p' ?; p/ r) c程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?( @& M% K( S* @0 @  v, Y, _

! Y9 r- E3 e# O) [$ S另外一个小建议,就是move,所有的move都可以这样
5 v1 F7 I' T1 U9 o3 tif not move() then debug end
5 c# B& x, {& o9 w: S/ ?$ s# \  _这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。5 |" y$ I! \& c, l% v
plant simulation中的free libraries有AGV模板,
" e  C* @: R; P+ s2 B. A1 g$ L# q* F里面也有案例。0 B) G) E' J9 j- I1 Y. W& Q5 ]$ m
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。0 k  C- Q3 E) U$ e! J
) o3 \5 n) e, `" f" e
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 " O9 h1 K/ P7 O9 \0 i2 V

% L# f1 F+ G+ p0 a; ?那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
: K4 p1 f% g$ u这是AGV_putin中arrive的method。3 Z- b. i/ m' i/ I
/ X1 H. J7 g/ k, k. \; ]- }# S
当到达物料速度越高时,这个报警更多,

3 z. [1 _; ^7 z% `另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-14 04:03 , Processed in 0.020234 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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