设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8956|回复: 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'5 e: I4 H1 D+ p! z/ H' a* g
*/8 y* d* c  g( m, ]' B5 r0 ~5 |
is. {4 ?5 f  S9 D1 E$ V8 A" _
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;+ {( ^) p6 J, W8 K+ e) r
do
% K$ U3 o8 Y) E$ L" {$ b- q% E        Lan := rootfolder.Internal.Tools.AOLlanguage;
! N3 `3 P% y7 O        if current = @.Destination -- else return
' _! W0 l) Y6 K( }8 F, t        then
7 e% F3 P& n! `) K. ]                @.Destination := void;+ B6 Q' E" B/ \) S- J
                if @.occupied then5 V' v- C( [2 X, w# t: }4 F
                        part := @.cont;1 |5 r- L* I/ S
                        @.transpOrder := void;
; d6 z: L0 E3 z; \                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
& i7 e: P5 b9 Z& r; U0 Z                                @,root.eventcontroller.simTime);$ Y9 Z: \+ n8 [1 _6 m/ F# `
                        @.HasOrder := false;' L; [9 }  I0 y) x2 ~
                        @.DrivingHome := true;
- E6 E( N. J2 O2 @6 J4 u1 i3 R                        rgManager.tryToStartTransOrder;0 R7 E# {- {$ i& M- @# ]+ ~
                        if @.Destination = void
" G  w7 n* x# u- N                        then -- no transport order for vehicle @, n7 S" `1 }  ?. Z! e3 P
                                @.Destination :=
) S) t# n' _# E6 f' e                                rgManager.nearestFreeStation(@,track.~);
" E4 M$ `- q9 j4 Y1 e4 ^7 X  N                                newDirection(@);     u+ W+ D7 [4 c
                                if @.Destination /= void then. Y; E7 ^4 B( W9 i* }
                                        @.Destination.NumReservation :=2 h5 e' v6 Q/ s# \" F
                                        @.Destination.NumReservation + 1;
5 ~. u8 s3 g4 {8 C/ _                                end;
) |! `& x8 F' C) z) }0 Y- N2 j! N                                @.CurrIcon := "drivingHome";
$ j, r0 N4 w: h8 f) x/ M& I                                @.DrivingHome := true;
$ u' ]) \* l) ]7 E5 r: @% M                        end;
* R8 C7 e* g! O6 o: t0 j                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
* p/ w8 t3 G' @3 n- @/ B. y7 W1 F7 g                        part := @.transpOrder;6 b( A! Y' d* S8 M) \
                        part.move(@);-- load part3 {* P; `* t7 s  z3 {4 g
                        @.CurrIcon := "load";
1 A5 V; z; h; `+ N                        GlobalDistObj := part.globDestination;5 @2 M& e# p3 A" [- E$ q
                        assignLObj := rgmanager.rgAssignL;
. ^" ]% ]" R# [3 C. T# P# L* q6 s! N! D4 L" N                        row := assignLObj.getRowNo(GlobalDistObj);
+ ^4 V  m. }2 h2 y0 H                        if Row = -1 then -- since 70
! z' L: [0 J. o5 p1 N6 C                                if lan=1 then
2 F: z; \& ^; W! W! M3 a                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
* f- T9 e/ w6 X7 ^                                                to_str("in der Andockstation: \"",?.~.name,"\""));
$ h8 B  r6 X0 I7 a+ J' P4 P0 z                                else0 V* x( `# q# h7 F: I
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),6 {/ ^5 i, D* `) W" N( Y" v
                                                to_str("in docking station: \"",?.~.name,"\""));                               
2 z3 T( ~6 i0 D/ Y2 o. i4 O                                end;& j- n$ [. v8 X6 y3 x* ]' }( t- r  c
                        else& K  L! V, ?1 _+ t
                                @.Destination := assignLObj[1,row];
1 u$ Z5 i  O$ R, R                        end;                       
# C  C2 d) T% C4 s, f6 Z/ U6 x$ h                        newDirection(@);3 r/ P4 |5 |- G( i5 z2 \# W, x
                        @.HasOrder := true;1 Y3 a+ a" A: j5 j
                end;
. P' t: n2 r0 Y& x        end;
: _/ w5 j1 P, L" Xend;        -- of the method( C( c1 V: j: d- |# z8 y
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 - V) t* `) q/ w( [

& J/ b( K# L, q8 d这是AGV_putin中arrive的method。' N5 D. T; m- ~

( S% T1 I" S: y" ?4 e当到达物料速度越高时,这个报警更多,, Z9 f3 t  |* |' O4 A1 j
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
9 O. U+ L0 l$ E3 l. _; P  S程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?( H3 M) s" L8 Q2 k. K# O6 p

3 T: V6 [" Q4 ?4 ]/ P) ?" b另外一个小建议,就是move,所有的move都可以这样& [, z- |8 @1 y2 G& |7 ~6 s$ X6 H) s
if not move() then debug end* q3 A1 J. v8 a
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。. z% H3 d) @& L# c( G* ]
plant simulation中的free libraries有AGV模板,
, e5 [- Z4 b% @5 v里面也有案例。
0 `$ w/ L3 S7 Q8 f我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
  g. w; `! w& o9 U
% m" z' {6 Q5 f& ]* {我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
- I: m4 v- r4 D: u' s' l, e( S1 f$ I
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
* s$ H, P- A+ X$ A这是AGV_putin中arrive的method。. ?5 Z9 a9 b3 x$ h6 W) C6 K$ r

% c+ Y1 j$ N! ^% c7 P% @当到达物料速度越高时,这个报警更多,
2 q, T5 f9 I$ m/ p$ y# Y: [% f; v
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-6 08:40 , Processed in 0.016414 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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