设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 4847|回复: 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', L3 |2 n# `5 f0 M# f8 T/ |+ z
*/
, y9 f" {* P5 d  P, T' M8 xis
7 A. I8 f/ Q9 n3 A        part, GlobalDistObj, assignLObj:object;row,Lan:integer;' a7 v; O/ v6 a; J6 d) e  @
do
! j5 i) r& {: F2 Y  w  r        Lan := rootfolder.Internal.Tools.AOLlanguage;
! B, {' I+ G: J        if current = @.Destination -- else return
- \: t6 s8 u3 D- D$ c# f        then: K- T+ u- P) x! W9 ?3 i( b, J
                @.Destination := void;. T* o+ u' [7 J2 w8 e
                if @.occupied then
0 ~1 s2 P8 r. V, ]6 S  y8 X                        part := @.cont;0 J1 }6 Z, `- \+ p
                        @.transpOrder := void;7 ?0 E0 F5 ]7 A  d
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,# B+ h: t8 n3 U: b
                                @,root.eventcontroller.simTime);
: K1 F2 ~- g, }8 a                        @.HasOrder := false;. W+ L! c$ R5 R' `: g9 D
                        @.DrivingHome := true;
/ [# e( n7 b5 `5 a1 m                        rgManager.tryToStartTransOrder;2 K) x. U0 l( @6 I2 y* y8 o6 p# j
                        if @.Destination = void
$ D( a$ P& D" K9 a7 G: M# x% P0 C                        then -- no transport order for vehicle @
) q" [! o5 U1 N& S                                @.Destination :=& I( m0 e: n0 i) W& X* y
                                rgManager.nearestFreeStation(@,track.~);
& p0 ^6 w3 J6 I3 b# N                                newDirection(@);   4 }4 }- I- g5 }8 U/ a4 @" R$ {
                                if @.Destination /= void then% T/ H( n' ~, _  s* b- U; f6 @: z/ a
                                        @.Destination.NumReservation :=$ I3 w( q4 q3 j2 O5 |
                                        @.Destination.NumReservation + 1;
$ l. Z* `" A1 v9 f2 g0 M  e/ i                                end;- K8 x' U2 m4 d/ A
                                @.CurrIcon := "drivingHome";$ ]. _! D+ c& r( W3 H/ r: K1 W
                                @.DrivingHome := true;
, _& {7 y/ H% M4 T/ }3 V                        end;
8 [- v: t6 C& M  W0 T+ F0 z, x8 M                else -- the vehicle @ is empty, both vehicle and part are in the same dock station3 T- E1 A. V& X% y" v. Q3 |: _
                        part := @.transpOrder;
" |: \' M1 E* L% S                        part.move(@);-- load part* y8 ]: O  N1 h3 K
                        @.CurrIcon := "load";5 G) s% x" J' L' H* ]: H. e9 a- \
                        GlobalDistObj := part.globDestination;
( {7 R: N* Q( U% B. `                        assignLObj := rgmanager.rgAssignL;
8 \6 {9 \3 }, r                        row := assignLObj.getRowNo(GlobalDistObj);
+ X4 H# \+ n6 f# ^                        if Row = -1 then -- since 70
" T8 O8 w+ W3 F5 ?  E5 @3 G8 M+ S                                if lan=1 then; o  L/ o* ?! x
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
5 j# v- w( G; l2 w" R* B2 U# Y                                                to_str("in der Andockstation: \"",?.~.name,"\""));2 U" d/ H7 t, n9 ^. q3 X5 X3 ~
                                else$ ?( H& B0 f5 u$ {4 r4 x" {
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),: j; L! @/ a5 n) v9 q  I
                                                to_str("in docking station: \"",?.~.name,"\""));                                ! t* A8 V2 i( ?; E, b- w# o0 H# G0 j
                                end;
  P3 u1 o* I3 u* L2 E, e                        else
1 n+ X) o! b1 a5 ~9 e4 U7 C                                @.Destination := assignLObj[1,row];
: F) @& c# V7 L9 J7 W9 b                        end;                       
) b: P% X) F# G4 F9 S; W4 p, X                        newDirection(@);
& q# h7 U5 a: a$ X. f( \                        @.HasOrder := true;- x8 D+ o- u% F  T
                end;$ r3 g" T& z2 ~% Z3 @
        end;6 B  p1 ~- b& b2 ?  p
end;        -- of the method
# j, O; b2 c$ U- o$ K$ K
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
+ D7 b6 z: P5 l) j8 J+ p( n9 D6 m$ c9 U3 u, n
这是AGV_putin中arrive的method。
7 i! s( N" |# V- _4 d. ]8 U) w" g% e3 j8 `( C$ f
当到达物料速度越高时,这个报警更多,
: I8 B1 a. `1 h8 L/ Z可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
. d& ]2 K5 W* k5 s/ v( _# V程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?2 Z1 L9 f2 E5 q" t- R7 F

5 {$ E8 z( q0 O9 A( \" K另外一个小建议,就是move,所有的move都可以这样4 h6 `0 u3 t3 M7 C  n* {4 Q
if not move() then debug end  V% X: ~' }! _4 s8 W$ T5 G4 ~
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。5 c) B3 g) s. a$ h( Q( i/ d: c
plant simulation中的free libraries有AGV模板,2 ^8 m" Z6 p0 x% B, S8 B
里面也有案例。
" p* @* ?, Q1 c! s4 ~& P我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
9 B) |7 i# u6 W# d
% ^5 D; s3 q. l3 Y! {我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 $ c0 q5 R' g; i- ?

4 t7 b/ k. N! `/ X那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ! T5 W+ l2 q$ ~' Q6 ]& m
这是AGV_putin中arrive的method。
% \9 d' Q! I3 q% E+ n
7 c6 e& A- f5 C# c当到达物料速度越高时,这个报警更多,
1 r- c8 G- L6 U
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-8-29 03:54 , Processed in 0.016613 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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