设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9681|回复: 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'( B4 U' d6 P1 I  N# J
*/. m6 r6 Y' c5 q9 r! q: V
is( G' c/ U. u# O4 K6 @# C, G5 `
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
1 |/ s7 `7 v" P8 _1 odo7 s7 w# ?2 x) J/ u2 e- Y, s
        Lan := rootfolder.Internal.Tools.AOLlanguage;
8 M# @* [# s  d* S! v1 }& X0 s( C        if current = @.Destination -- else return
: Y( O& K3 g/ b5 J" a. b        then6 E6 R1 f7 I  t$ F. z
                @.Destination := void;
/ ?% N) b0 J0 D# m; {                if @.occupied then! \! P4 l( W" u2 @3 |
                        part := @.cont;
8 X. Y0 z" H3 V$ n% z  J                        @.transpOrder := void;
5 a6 c. z# e. }- W                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
( o. D5 ~( Z! ~2 W* T5 [2 n                                @,root.eventcontroller.simTime);
9 J2 l4 h9 r. G/ K) f4 s1 s& C8 m                        @.HasOrder := false;7 Y/ e! T. l4 T/ R, o! r$ p6 I1 U
                        @.DrivingHome := true;
5 e6 f5 _. J" u. `' O                        rgManager.tryToStartTransOrder;8 H* h! ~1 I, K! }( h+ ^
                        if @.Destination = void
" U% u$ \# b* Z) e0 g6 A6 L                        then -- no transport order for vehicle @1 P: A' u3 z" H: q
                                @.Destination :=
& ?' u3 E6 c4 e+ o4 C0 |- \% a, o                                rgManager.nearestFreeStation(@,track.~);' [; g6 ~& G3 F7 j  x8 h9 X( }
                                newDirection(@);   
1 j# |/ U+ w* A% {                                if @.Destination /= void then  g' _+ A' Q+ Z, ~3 M. n
                                        @.Destination.NumReservation :=
5 i6 ]& n2 S& _% {                                        @.Destination.NumReservation + 1;
3 R1 c* g/ {3 l                                end;
( \8 d. T( a: G8 }& E                                @.CurrIcon := "drivingHome";
: |' T, K! [/ _% M# F2 Z% q                                @.DrivingHome := true;: ]7 Q! f9 G3 \/ L( f, f: O& o" v
                        end;
$ u+ i9 c9 {* T& e3 L4 H4 H                else -- the vehicle @ is empty, both vehicle and part are in the same dock station4 ?% `8 ?4 H. _/ ~- n7 M8 }3 A
                        part := @.transpOrder;8 V0 a, Q4 L& o
                        part.move(@);-- load part" z/ i( i- {2 g3 }: b& A
                        @.CurrIcon := "load";6 I6 b4 V. j% g8 `. Z
                        GlobalDistObj := part.globDestination;8 F, N( s9 n' E1 |( r0 W
                        assignLObj := rgmanager.rgAssignL;
# C) m/ P7 ]9 l7 }3 C* ?                        row := assignLObj.getRowNo(GlobalDistObj);
# y+ U6 c" U" ^; F$ P                        if Row = -1 then -- since 70
! ]* C4 S) _' T' f                                if lan=1 then3 S, u+ D$ N" Z
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),3 h' K( Z$ h$ C% e6 J5 e$ S
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
& N& i) R- C6 u7 o+ ^4 I- I( j                                else
* i9 H! g% A0 Z7 x6 V                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
, q% j1 _" U' F; H% ]" o                                                to_str("in docking station: \"",?.~.name,"\""));                                7 R4 O  E0 i7 v
                                end;
' ]  u9 N8 T+ p' m8 P( q3 H( E                        else
- S2 c: q+ J5 B3 B: l                                @.Destination := assignLObj[1,row];6 X& |8 c4 {9 e+ p' S1 ^4 K# V8 `# M% b
                        end;                        8 N: e0 o2 b: y7 u
                        newDirection(@);
" m3 x/ ]& G2 F* j4 e/ C# v                        @.HasOrder := true;
- b% ^, W0 Y/ y  |8 Y9 W; M: o                end;
. ?0 O' B  Y/ T- j, P( x0 A        end;
9 [3 S4 M$ u- b, `) Y& E: Jend;        -- of the method; y- z) n: c" W! F
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
- |4 c& W6 i* I5 R
% m3 t( O$ q& e; A$ S8 ?这是AGV_putin中arrive的method。
7 _4 X, F  O8 N: Y/ m% L4 ?9 I8 t1 X* n" M$ M3 g6 M1 b# i0 B
当到达物料速度越高时,这个报警更多,
' z: X( l2 p* o" b$ @可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
. ?# b; Q6 g6 z- \程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
9 @. M! d. \7 ]4 Z+ A0 u4 y. L2 T) Z$ f& B& i6 x" [% S3 d
另外一个小建议,就是move,所有的move都可以这样7 t* S8 u% m4 Q6 b- w
if not move() then debug end
9 K. _- t1 g5 w, l7 W/ }, n. H3 i这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
2 S' d0 r$ }; x# Iplant simulation中的free libraries有AGV模板,% F- O; ~7 ?/ O$ F6 \, ^. r8 e
里面也有案例。
# b  G2 Q' L# L3 h我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。3 t' @8 _+ J' v0 X' H
9 H1 q2 H- T+ x( V8 \) {: f/ D! W
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
" O9 A; Q( o8 O- O7 F
3 P, B2 N7 D( h& a; d2 ]7 G* T那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ; i6 r  s9 O( s) s2 l
这是AGV_putin中arrive的method。
. D. F5 M/ T  C; o1 \+ a7 _
3 Z* h& N, G4 i4 }当到达物料速度越高时,这个报警更多,

2 ^) z+ w4 I: ~, H  E另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-16 21:52 , Processed in 0.021732 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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