设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8367|回复: 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'
; i5 S& h8 w' w2 T*/# j2 X7 W) S9 r! G& _. i
is( ^. d6 |/ X9 c, s0 E# O
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;) _) j. f' O' y* u9 h, _$ r
do
4 c; N$ |) [4 t* M        Lan := rootfolder.Internal.Tools.AOLlanguage;) @( E! A; u$ I$ d
        if current = @.Destination -- else return
, c( s$ t4 A4 G& @" f0 R+ d        then4 ^# c9 q7 h; N9 [, A/ _
                @.Destination := void;
) F/ U: A0 C/ b/ ?4 |! y3 D                if @.occupied then
+ l; w% ^& `; H                        part := @.cont;
) N- Z7 [$ ]: G" O+ ?" M+ b                        @.transpOrder := void;  ]6 _% A0 w# I3 ]  n. o
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,: M4 C' F% ~! j6 G. x5 j
                                @,root.eventcontroller.simTime);5 P* N! X0 }2 ]8 ~7 i& x. U. u
                        @.HasOrder := false;: k# b8 L5 \& i8 l
                        @.DrivingHome := true;& S5 c3 v5 D/ s
                        rgManager.tryToStartTransOrder;% ?+ o9 ]; X- Y3 R/ I1 `8 n
                        if @.Destination = void1 `- S. {# R3 `# x" l+ X
                        then -- no transport order for vehicle @) K; i7 Q9 W% R7 g& B
                                @.Destination :=
0 x) d/ m8 O7 I$ O2 I) q4 f2 e                                rgManager.nearestFreeStation(@,track.~);
& k& S( J0 K% o, y! y2 |0 ?                                newDirection(@);   ' Y, T/ ~3 U+ s9 {4 `
                                if @.Destination /= void then
6 m* o& N; {0 |" f8 Z4 g                                        @.Destination.NumReservation :=
$ Y2 L( i0 i% f                                        @.Destination.NumReservation + 1;  v! N2 O2 g) A$ G3 N
                                end;" E' u+ U& }" @3 I& R6 E; n- \
                                @.CurrIcon := "drivingHome";
( R5 z0 B  R0 ^  j( X                                @.DrivingHome := true;
8 X$ }- ], C1 r# ]                        end;
. Z3 J  ]; Z6 t0 w8 B                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
+ Y& Y: E$ \$ g                        part := @.transpOrder;+ `6 [+ x1 z  [. y! g4 @
                        part.move(@);-- load part
! N3 K! a  f% _6 q; `                        @.CurrIcon := "load";
7 n* ^5 y# M3 F# y5 _$ ~8 ~# T! B                        GlobalDistObj := part.globDestination;
0 Q+ M; l' `; }; Y) P7 H/ w                        assignLObj := rgmanager.rgAssignL;
! {0 p# X: ?& a  d6 h. N                        row := assignLObj.getRowNo(GlobalDistObj);
; }& E( ]4 C% K% n+ Z8 k                        if Row = -1 then -- since 70
. e2 h1 C8 p1 X0 c                                if lan=1 then
; Z& Q* H. p- ], |; \                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
1 x8 k2 l7 L! Z4 V2 _# G7 r6 u+ `4 T2 Y                                                to_str("in der Andockstation: \"",?.~.name,"\""));- N  \: o( M3 ?$ d
                                else
5 L2 K' z% @& k                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
$ J& }( i+ K" m) m3 h                                                to_str("in docking station: \"",?.~.name,"\""));                               
7 b, O, i' ~$ o3 J0 r5 ~7 {                                end;8 J  j: w6 z: }3 J- s. r
                        else
; B9 s: h. k( b4 Q7 h  Y& [$ o8 E+ J                                @.Destination := assignLObj[1,row];2 F& m4 K% U) V3 @* v. ~. Q' h
                        end;                        1 ]0 ?5 D! c! J
                        newDirection(@);8 O$ X; B6 @2 U% U0 ?; o2 }
                        @.HasOrder := true;  l! k& F9 d8 P- j& J
                end;
' T8 X$ @1 V" M/ Q& @2 b; a8 u4 C        end;; `8 y7 A! A9 R7 }: S0 g
end;        -- of the method/ G/ s- I0 A# i  V5 y" h0 ^6 B
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 " `* S8 J! ]8 ]
  t  k5 F" Z2 N# a/ F3 f9 {* D
这是AGV_putin中arrive的method。6 v0 E% P6 R" @* K* v- W
% L! s) ]" e+ b, G% t
当到达物料速度越高时,这个报警更多,+ i1 H5 o( O( R( g* Y: q
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
9 d* b6 _& |+ o& c: J2 f9 L程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
% ?% |- S  d5 W) Z+ J4 F8 x
6 V) D. G& k  j+ y. o另外一个小建议,就是move,所有的move都可以这样
- b* N  C) ~5 S9 @$ _+ aif not move() then debug end% |0 X$ T9 d! ]+ ^) j
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。: P, K/ U# E3 k1 J$ M8 ]% z
plant simulation中的free libraries有AGV模板,9 N+ q' b5 C* ~4 S
里面也有案例。
" C- k6 e' C$ y1 }% }4 {我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。5 d1 G' ~. i1 m2 v8 E

5 v0 `4 a' x- J! E- }. f" U3 J我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
$ y2 e$ r- {1 n& n# C6 o& f# W2 W
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 7 a, t- E+ U6 Y. ?$ A
这是AGV_putin中arrive的method。
2 }/ T6 e6 `- Q4 u, e0 }0 t* x
! a0 r4 U5 |$ l* ^9 q" w当到达物料速度越高时,这个报警更多,

/ U5 c% C8 F: p9 p另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-30 22:53 , Processed in 0.020896 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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