设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6296|回复: 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'; |8 N+ C! ^5 g7 v% ^, b% s
*/
7 B$ ]! D9 K4 ?, t  N. P2 eis% Q$ }6 [6 I9 p- H, |/ e
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
4 h9 U8 ~9 Y" gdo
5 {' Q  @& f4 u  Z) E        Lan := rootfolder.Internal.Tools.AOLlanguage;4 ~( |6 a7 e: \+ v& R# `& w
        if current = @.Destination -- else return! b0 G* K9 ?) W+ o' D
        then+ A  a  A7 n3 A4 |4 l
                @.Destination := void;/ ?7 r9 Y# l7 B( l: J+ y
                if @.occupied then7 c- j; q7 R7 [( a2 F# S, r5 |" w
                        part := @.cont;
. z5 @1 Q# {5 a- T                        @.transpOrder := void;  B# m% C% B. B& L4 j
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
& n4 ]8 l$ J1 T+ i5 v* @                                @,root.eventcontroller.simTime);- `+ K  B; u! |+ I9 L% p" x
                        @.HasOrder := false;
# i5 D" u- l$ b; S, P% a                        @.DrivingHome := true;% H  U: @/ `( F* v3 S. @
                        rgManager.tryToStartTransOrder;
5 b" {" ?9 W& T9 N* L                        if @.Destination = void
5 |% y* b9 Y4 n8 q/ H  L0 e" i! p7 r                        then -- no transport order for vehicle @4 Q/ O, d$ A8 _
                                @.Destination :=
( Y3 f7 N: x8 w2 K+ P                                rgManager.nearestFreeStation(@,track.~);+ f4 P, b) d9 P/ |7 P, C% Z( J
                                newDirection(@);   ( [4 Z+ X- M. O+ W
                                if @.Destination /= void then
0 t$ b) ^, t. d# M                                        @.Destination.NumReservation :=
- C. G, ?+ I  k/ R3 Y6 F# K                                        @.Destination.NumReservation + 1;# ^! y6 f( s) H0 W
                                end;
2 d$ v7 U, ?% ~4 e3 C4 d1 m                                @.CurrIcon := "drivingHome";& E9 V1 @% O/ N9 j
                                @.DrivingHome := true;
7 P# n& Y! y7 b( ]6 C1 o1 V9 _                        end;
/ z* J; Z1 s7 \. r4 y( G                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
4 Z6 k: Q/ i/ y: I                        part := @.transpOrder;
4 O5 {- j7 g$ }* h3 E( L4 t0 T5 c                        part.move(@);-- load part" k2 t2 M% C& U: m) Q% k. Q) Q
                        @.CurrIcon := "load";
: ~5 s! a* ^* f; N4 l' B4 `                        GlobalDistObj := part.globDestination;
0 ]. b- u- ~6 _2 e$ D                        assignLObj := rgmanager.rgAssignL;& n- u2 I# V, ?  d
                        row := assignLObj.getRowNo(GlobalDistObj);
, C3 g+ J; Y( M                        if Row = -1 then -- since 70* c1 V, b( o& s/ ]( J
                                if lan=1 then. k3 E; U9 Q! ~
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\"")," `8 A1 D" U6 Y
                                                to_str("in der Andockstation: \"",?.~.name,"\""));8 _, r( n" s! e+ A  \% Q
                                else
2 e/ Z0 D* L& i2 D* o9 }: W                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),! ~1 h/ L( I! Z8 X. y+ b
                                                to_str("in docking station: \"",?.~.name,"\""));                               
! u/ s4 K$ M6 |" y( O                                end;
5 {; h7 w+ i0 T4 d- ^                        else" u- @8 i0 Z, L1 i2 b- }4 Y7 L
                                @.Destination := assignLObj[1,row];
. x' C! T3 ]" F) I- \- |$ C                        end;                          k" e  I, s& n0 C% I% f
                        newDirection(@);
1 x4 S3 s2 k+ I& z9 p, M' N5 i6 s1 O: z% }                        @.HasOrder := true;
; M9 N0 A: K1 k                end;
& v7 ]9 Z) m% Q% m( h+ d) b4 c        end;
) f" N0 D# u4 ]2 s+ D* B, Uend;        -- of the method
1 k( D4 Z9 ^5 D( h, m, r+ e
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 3 V# D; ?2 j8 Y8 _; K+ I

; t& |- j: s; t* G% T0 |这是AGV_putin中arrive的method。
1 m3 ]6 E( s) \/ Q* Z6 H1 s7 H: h( w7 k- w- N! M
当到达物料速度越高时,这个报警更多,$ R3 _8 t% G: c4 U8 t
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
( j: |- o3 h3 m程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
( J8 P* M9 j/ g5 v6 C: J6 K# N& `) r. ?# u6 E' z
另外一个小建议,就是move,所有的move都可以这样
3 b. `) k' |' `& H) P, bif not move() then debug end
( w3 j& e  q( \: e$ w) v这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。/ c2 O* F  |' y
plant simulation中的free libraries有AGV模板,5 K- _' k3 O. P$ x( c% ^/ @( B3 W4 e
里面也有案例。
  L$ ~% q" z( d0 g我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。2 p% ~5 G7 S) p: ?. Q& @8 V/ m' q

) e8 l$ R* B* s  _我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 1 M) f: k+ [8 ]1 c$ P% j1 a" v

8 O5 q2 E4 ]# N% m+ V. t4 X那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
" c8 o# a) F' T8 O2 t# u4 P9 p: m这是AGV_putin中arrive的method。8 r: T4 l7 q! @1 w+ j9 z- |
$ x' s: M4 g! C# n) K
当到达物料速度越高时,这个报警更多,
8 G7 _( O+ [# r2 V" u! L
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-29 11:16 , Processed in 0.018820 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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