设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9110|回复: 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'
- }* T" N( K+ X6 g/ N7 q: O# `) \/ _*/
8 _+ s/ j! p' ~' t3 w7 [is
- p+ ~: k, H+ `3 |        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
$ {  ~7 G! ^, E/ e0 n/ Wdo6 ^* h+ K& u1 ]+ H2 @3 ^, k0 m% d
        Lan := rootfolder.Internal.Tools.AOLlanguage;
8 x9 r& a0 O  ^  l  D        if current = @.Destination -- else return$ f. g( t; b1 M" I0 j! G& `2 G
        then* S* L& W9 p3 t" D9 T4 K
                @.Destination := void;
0 {3 K- X( A2 R# f                if @.occupied then$ T. z% V+ K! {" X
                        part := @.cont;4 f' s" i: k, W* Y8 b. D
                        @.transpOrder := void;' [3 n- L* a5 p, I5 e
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,0 n) @1 I4 I) N  t" \+ I. o
                                @,root.eventcontroller.simTime);
1 M% }' n" c1 T" p                        @.HasOrder := false;
3 ]+ l/ D  L" y: Z4 d& c                        @.DrivingHome := true;1 z* D+ t7 G+ C& Q0 \
                        rgManager.tryToStartTransOrder;+ ?! _1 W3 z, z2 q; r& I7 v" `
                        if @.Destination = void
$ r& O+ y, C+ T. L9 I" C$ q; g                        then -- no transport order for vehicle @
7 l& A; A! n- L- n* A- K/ }9 X                                @.Destination :=
. Z; N7 [# F" y8 o$ P5 Z                                rgManager.nearestFreeStation(@,track.~);
7 }% [* R7 y* R+ C8 h                                newDirection(@);   ' l* I. [- z; Y- D; R
                                if @.Destination /= void then
0 ~6 Z7 V. L0 ?                                        @.Destination.NumReservation :=$ q$ c6 Z% f' e' [
                                        @.Destination.NumReservation + 1;
5 Y( M) l9 c+ E9 T' b0 r: {) u+ [                                end;& _! m0 K8 A6 l) {
                                @.CurrIcon := "drivingHome";" ~) G) `' R$ u
                                @.DrivingHome := true;
( G- T0 R( W4 Q0 ~8 k/ U3 W0 ]                        end;8 }# u9 w" \! R1 H! }/ q2 [1 y
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
! W6 d6 E, H) h% H" ~: m- J; t                        part := @.transpOrder;3 f/ k9 D. u+ C* g1 T  c
                        part.move(@);-- load part
9 ?; ?' }/ A) v  |1 l7 T+ i3 n                        @.CurrIcon := "load";
; L* S$ J7 x& C                        GlobalDistObj := part.globDestination;3 w" `7 O- R8 H/ n" r
                        assignLObj := rgmanager.rgAssignL;
& f, h. L: {& |. O( c                        row := assignLObj.getRowNo(GlobalDistObj);
4 d+ }5 h8 ], f. m9 o  v# L                        if Row = -1 then -- since 70- c: `% j! V$ X1 T( U
                                if lan=1 then+ {4 d0 K& Y+ T  s" F
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),0 r- E* r0 g) i0 Y! l2 I
                                                to_str("in der Andockstation: \"",?.~.name,"\""));/ M2 p* C% v# w0 Y& ~
                                else  M4 V  q: G) l7 m( `
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),. U+ _' @+ d2 U0 }2 A% T3 \
                                                to_str("in docking station: \"",?.~.name,"\""));                                9 w8 t6 L3 |% R# E
                                end;
8 z+ Q' t9 e( I( {4 O5 y% E                        else) t$ e  Z1 S; C0 Q5 ~4 Y* i3 Y
                                @.Destination := assignLObj[1,row];# L. O3 b$ W: ?& A" D/ J
                        end;                       
" |- _  g. I. b7 U9 \. d. t' Z                        newDirection(@);
; Z$ E8 N$ R% \3 P7 Y5 g                        @.HasOrder := true;
5 v: L' O; F! n. W; U                end;0 Z0 u5 P" k% r! ^' o" f8 S/ ~
        end;1 _, m6 }- {$ ^* u* G) d! z5 w
end;        -- of the method
/ p# w( P3 S  N/ S2 w
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 . E1 M7 ~9 Q( Q% Q! h
; V' ]% w; @" ~$ U
这是AGV_putin中arrive的method。
7 n; G) `" k6 d
: @* t  B& w- f4 |  l当到达物料速度越高时,这个报警更多,
1 S1 }; ]; ]4 f  A) W可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。$ [# g2 \: f% c+ g5 w
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?! P5 ~6 j' G9 V' [) o, E

$ l1 G, W1 J! O/ s另外一个小建议,就是move,所有的move都可以这样
8 ?$ c$ x7 a4 H/ V" Gif not move() then debug end
, ~: L- S$ N! t& [- M# f这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
4 Y+ f2 e+ W1 Z# r$ O9 `* Hplant simulation中的free libraries有AGV模板,3 E( X- H% ]) |, F. K. ]
里面也有案例。
8 Y6 J* _4 x4 C我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
3 v9 e: D6 O, C, L  W% n2 k% Z0 Y& B  |8 A/ ^  o9 S/ u
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
4 i8 ?* I) B" G* w( _# b; d" b
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
( t. R, |8 x0 H) j+ S这是AGV_putin中arrive的method。1 C" I) K) F8 w* h. w5 s
  T4 [* b# I, K
当到达物料速度越高时,这个报警更多,
* |" p  f' [+ H' K% f
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-14 06:01 , Processed in 0.016123 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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