设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6584|回复: 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'1 q2 E, x! W( k2 S
*/
1 A9 @% }; ]! dis
/ _- D1 l: i# S. ~! X. L        part, GlobalDistObj, assignLObj:object;row,Lan:integer;. o* D( L+ I  U- Y1 ?7 j( I
do$ y; y9 s: }0 G- O/ c  [
        Lan := rootfolder.Internal.Tools.AOLlanguage;
. ~1 R( W/ \# @1 ~        if current = @.Destination -- else return% v0 v' I3 v7 y" K6 F* t
        then  T/ K1 P" ^3 K5 `$ K% A6 r
                @.Destination := void;# p' a7 P* g: O' o/ B5 L' u. N
                if @.occupied then
- l3 f" K6 g$ p/ g, g3 y7 b" d                        part := @.cont;
: c* p3 p; S  k  ^- J2 D, |                        @.transpOrder := void;
1 k6 Z$ B8 _, a% m2 _( r% g( U                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
- J$ \+ W# R1 a2 h+ _# N                                @,root.eventcontroller.simTime);: N. u8 Q  z2 X: b( O8 ~
                        @.HasOrder := false;
6 v5 g8 h, }, t3 q6 x                        @.DrivingHome := true;& Q! L( F6 R8 m& b
                        rgManager.tryToStartTransOrder;6 G& k& R2 l6 t0 ^; d
                        if @.Destination = void
" O8 e  }( O# B. z: R8 E                        then -- no transport order for vehicle @
* Y* [% q) l7 f# o  g* }                                @.Destination :=) i: i5 z! G. O- A8 J
                                rgManager.nearestFreeStation(@,track.~);+ G3 W! U" J$ V& T% c* K: J5 `
                                newDirection(@);   + X! Y0 ]/ m4 S
                                if @.Destination /= void then
: f$ }" P& r: e% P+ G. v: {                                        @.Destination.NumReservation :=$ s! Z2 B0 N7 Y9 e% q
                                        @.Destination.NumReservation + 1;& C, z4 @2 a4 V. s; W" s& c
                                end;  G% @3 i. S; k. _$ a
                                @.CurrIcon := "drivingHome";+ U- Y$ L( s0 Q9 w; n" T/ |
                                @.DrivingHome := true;
# _3 X4 i  F1 T' A4 i                        end;* R" z3 |" v: K% e# X( [
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station* V& D% H  I/ r8 }" f
                        part := @.transpOrder;
* i4 q+ G1 u% b6 X7 h6 Y                        part.move(@);-- load part
9 \- z+ K4 d1 I, l* X6 m                        @.CurrIcon := "load";- W: T. D: Y9 y
                        GlobalDistObj := part.globDestination;
5 V' g0 a& u/ K, D                        assignLObj := rgmanager.rgAssignL;
% [' m0 L; k5 @. P% r7 M                        row := assignLObj.getRowNo(GlobalDistObj);
; W( t3 F. }0 z& \                        if Row = -1 then -- since 70
6 r+ x" N. ]9 n& r2 m4 V5 a* q                                if lan=1 then) w$ n" ?- h1 x5 [
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),2 N$ P1 `1 ~$ x6 _$ ~5 [
                                                to_str("in der Andockstation: \"",?.~.name,"\""));6 p' }1 }4 z9 R: `" E+ k
                                else! \7 P: y2 Q7 h- }3 q
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),3 ?8 k5 X) Q' t& ^3 ~# `
                                                to_str("in docking station: \"",?.~.name,"\""));                                . }( E1 X+ c8 `* l# g
                                end;  p7 L1 `7 B7 c
                        else
# }) b! y( }3 C9 {, S- \                                @.Destination := assignLObj[1,row];; _% f3 |. ]! H, Z  B% _+ f" i
                        end;                       
6 C' d* y4 f9 F; w$ w- N                        newDirection(@);: Z* X, {$ j( Y+ }
                        @.HasOrder := true;
5 N( W8 I7 w" ~2 b. H& Y, H0 d                end;; T$ c6 v. c$ O5 ^
        end;
' G( N0 P8 n# {+ O4 ]: Jend;        -- of the method. R" L6 f1 l* d5 @6 S: p  z
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
5 b9 i9 ]2 k4 @, [0 |/ l' L, }! x" W4 O- N- `# n+ g- x4 k
这是AGV_putin中arrive的method。
+ x' w- B9 y! k. s" y- G: @: H! S' d: H0 f: Z7 L
当到达物料速度越高时,这个报警更多,0 d+ a* Q) W8 X. _0 c7 m3 I
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。# o, A5 J5 f3 c: D* j. a
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?5 E# [3 @" V/ j" a$ A

. P/ L% l3 b) m6 Y% g另外一个小建议,就是move,所有的move都可以这样
/ l9 b' q: C, g9 U7 p  Gif not move() then debug end: T* C3 \) R- S0 O% D: o# s
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。- |0 Y, c* V+ b
plant simulation中的free libraries有AGV模板,( n* ]% \, U5 l1 q# F* l% w
里面也有案例。- A# H7 J( K* e+ d: s
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。. E6 ^. [: F. p8 k- V+ g9 C

; ~# b: G4 F  q% u; n. L7 j( k我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
  k/ z+ o  L3 D
$ Q3 M/ H5 s* J- r. B% G那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 6 I5 s1 ?! Y" {3 U3 }7 x, N
这是AGV_putin中arrive的method。
+ e( D1 n$ q1 I6 s5 `5 o4 M. T
1 R. u0 {5 s1 T当到达物料速度越高时,这个报警更多,

) h: l7 x4 X0 X! o0 g另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-14 06:57 , Processed in 0.017776 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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