设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9357|回复: 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'( g: _8 W6 {, v$ a
*/
0 V" k  K# {3 V' r8 c) cis  y; E8 H3 [- t2 H3 v' ]
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;- U" c; ~# H/ l! P  V3 a' Y# i: {# Y
do) |3 `1 x0 `  q; I
        Lan := rootfolder.Internal.Tools.AOLlanguage;; F* P6 O7 Q: g. f1 {% A
        if current = @.Destination -- else return
2 J0 D8 o4 u/ T1 Q        then  N( G0 S# V5 ^3 X6 }2 S/ _4 @6 \
                @.Destination := void;; ~, z( R3 k4 B0 ]/ M% ^
                if @.occupied then( b- r8 w: @2 D
                        part := @.cont;
. z* @3 _) m8 o+ x2 e                        @.transpOrder := void;
+ T$ i/ h7 }) D( ~" u                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
) U; h) H+ N, ~( m                                @,root.eventcontroller.simTime);
" D$ i2 C% i! U: l                        @.HasOrder := false;8 J& J) m7 \9 }+ u
                        @.DrivingHome := true;
* a, M4 y9 \# T! h. Z- X3 U                        rgManager.tryToStartTransOrder;& w( w$ g/ q( [+ t& I
                        if @.Destination = void2 g; @! }' L' W" \/ I) e( ^
                        then -- no transport order for vehicle @. }5 l, ~% k9 N0 E, `! G
                                @.Destination :=
& n1 v5 o6 t8 m* u' E( `                                rgManager.nearestFreeStation(@,track.~);1 d, B* ]: I' d
                                newDirection(@);   % H) F! e6 |" [& C* w
                                if @.Destination /= void then$ g1 [, @# }- q4 s
                                        @.Destination.NumReservation :=
: }; A0 ?7 O5 q# W7 l3 z0 E3 T                                        @.Destination.NumReservation + 1;- r1 w, r+ W3 ~3 F6 i
                                end;
9 q: x, O4 Q, p, B                                @.CurrIcon := "drivingHome";& ^7 X5 ]3 i' s/ F. L
                                @.DrivingHome := true;* E$ K9 D/ D' @5 `
                        end;
2 H- w# M* l; o  j5 \* b/ P2 ?                else -- the vehicle @ is empty, both vehicle and part are in the same dock station6 M6 Z1 X; r+ B/ V) \
                        part := @.transpOrder;: D7 a5 B: v. K+ I! ]  n  [& p
                        part.move(@);-- load part  W9 X5 [& h% f, q
                        @.CurrIcon := "load";5 {; Q' `! ?; B" i9 |
                        GlobalDistObj := part.globDestination;
) j( B5 ?" G3 O- J6 {( T5 ^                        assignLObj := rgmanager.rgAssignL;" \, S$ @  b4 K, Z2 H6 e5 r
                        row := assignLObj.getRowNo(GlobalDistObj);! R$ R: _' i# x/ i
                        if Row = -1 then -- since 704 K+ u1 l7 t6 m3 h4 a
                                if lan=1 then
% N$ @( P6 i4 O9 x  ]5 R                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
) }8 I/ u, h, Q' N" T* @                                                to_str("in der Andockstation: \"",?.~.name,"\""));
) ]6 Z8 P' g4 l" f8 U                                else: [4 ?( n: d) z6 f/ e- c# d
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
) H- ]2 n/ o4 m# B                                                to_str("in docking station: \"",?.~.name,"\""));                               
. ?* S* G: j, i1 J$ W5 \                                end;
$ }# l, H$ s/ S                        else( P) C8 J0 d6 d: s/ S! b" ?8 I
                                @.Destination := assignLObj[1,row];/ j7 }- j3 Y: _  W5 x
                        end;                       
# h! ^9 x: n- w4 b" \                        newDirection(@);; h+ t2 \- `% N# ^
                        @.HasOrder := true;! R; t" n$ @  [. A. E" X, i4 u
                end;, s$ T1 T" z, P3 g5 T6 A
        end;
- K4 t# D1 \" ]: n1 s" l" Z( H* uend;        -- of the method$ n- N, t* _8 }8 k
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
9 t6 n0 z% o* v( V) [; T+ n( _' m3 i" O2 Q% m. U& v
这是AGV_putin中arrive的method。
0 o2 a/ l' O3 T& r6 {2 O) T* q2 B1 _( ]9 `( k* g
当到达物料速度越高时,这个报警更多,/ F& p+ b) e8 }) }
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
8 N  R, m0 S4 V程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?/ x" h* c' k, G! s
# {4 T% Z, O9 E5 E) l
另外一个小建议,就是move,所有的move都可以这样
$ |2 e; ?  H6 ?% d" mif not move() then debug end; A$ ^" l; g$ m- ?! d
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
- s% \2 o+ E$ _  Y* m9 Dplant simulation中的free libraries有AGV模板,
2 T/ m; q1 m$ I! c里面也有案例。! A; F% @" l& t" }
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。. C: y9 b7 S  D: m0 B
# M) e- V4 p1 ^( k* z4 g8 d
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
1 I) Z- k5 w" a. `5 d1 t: `4 s) A. R* w" |
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
4 p/ [: [! t" h这是AGV_putin中arrive的method。
3 ?4 m7 ^. n  ]8 T6 Y! N* G
4 t- I4 J% W0 I2 f/ J1 \/ S当到达物料速度越高时,这个报警更多,

+ q) A& j8 R* E另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-27 13:57 , Processed in 0.020967 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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