设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9298|回复: 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'( J: ~' N. x' _2 p- V. I
*/
. ?+ x" e& L  h) x( Z1 K' t* @% Ais
- r! _- M; j$ j5 c        part, GlobalDistObj, assignLObj:object;row,Lan:integer;! K$ x" Q+ v1 @3 w& W
do% B5 T" i' H# O
        Lan := rootfolder.Internal.Tools.AOLlanguage;6 L; a/ W7 t2 w! C' j  R( v
        if current = @.Destination -- else return, _2 p( z. q$ {7 Q
        then
9 @. `7 d% i+ N6 C% s! e+ e                @.Destination := void;
) w7 C" `: {' _                if @.occupied then
8 ]* q; A# \! b7 w                        part := @.cont;* s9 k  r5 O- y% K
                        @.transpOrder := void;! p; n* b; N5 `
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,6 O: O; o' X- C: b1 O9 M% q
                                @,root.eventcontroller.simTime);, u1 [: p1 i) \  g0 I* K  `
                        @.HasOrder := false;- H% X' b# b; L$ \
                        @.DrivingHome := true;
. [- P7 ?- ~, W7 P2 A5 O                        rgManager.tryToStartTransOrder;8 B9 [( Z( v9 T& }/ h  S  J
                        if @.Destination = void
8 U  p* [5 Z- x& ~                        then -- no transport order for vehicle @* x  {0 l: Q8 {5 L1 x" ~
                                @.Destination :=8 f) K6 @. \- B9 B! p, M  {  g
                                rgManager.nearestFreeStation(@,track.~);' S3 \9 q2 P. D7 H, B5 l0 F& ~
                                newDirection(@);   
; F- e! J( j, [8 w- T( |2 v                                if @.Destination /= void then
7 P  m1 ~% [" D) n# u! A                                        @.Destination.NumReservation :=5 I( y1 B1 _% ^" \) Q% }6 v
                                        @.Destination.NumReservation + 1;$ M$ Q4 ^4 ~  ~" z4 N+ N
                                end;
+ Z6 s- P8 V: P- W" }1 S* q                                @.CurrIcon := "drivingHome";, d$ N& c" F! [+ E" b
                                @.DrivingHome := true;
9 i/ _) z2 ^8 y2 l) N) v  \5 ?                        end;/ |; ^. t" U- Y# I. g* @
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
2 g$ E; z! o& v4 H                        part := @.transpOrder;
0 K5 t# `6 a3 M% [# E# z. K  v6 q                        part.move(@);-- load part1 B+ J1 S+ P/ k
                        @.CurrIcon := "load";
% X6 m2 X3 u2 o7 F. B+ t; l. u2 r                        GlobalDistObj := part.globDestination;
! Q7 w0 ?' A! |  f: x) J3 L                        assignLObj := rgmanager.rgAssignL;
4 L, V' A$ M3 x2 t5 r1 {4 d- P( B/ m                        row := assignLObj.getRowNo(GlobalDistObj);
6 i+ O9 v! Y9 K) t6 x- ]                        if Row = -1 then -- since 70  k0 z7 _8 ~1 U' Y
                                if lan=1 then: x6 u. i: G" z- H( b' H/ ^
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
0 ]' E$ m/ j7 _  T, Q                                                to_str("in der Andockstation: \"",?.~.name,"\""));/ E4 U8 F9 @+ k, ]8 C6 d* S
                                else
- h9 P4 K5 @, r0 S/ j. x5 ]7 p                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),4 s- h9 Q' L2 ~' z8 \' @
                                                to_str("in docking station: \"",?.~.name,"\""));                                - K4 k& ^! h, D5 q& L4 E( {
                                end;
0 j9 k4 T3 ]* e# d! _. R+ e                        else
* r# a% d, Y3 M. Q8 [  C' w                                @.Destination := assignLObj[1,row];; f, R* B  b# z# Z& T; G
                        end;                       
' A' y5 E$ ]  V) P0 B0 u2 I8 j                        newDirection(@);4 I+ @8 @. K+ i4 l5 d7 G& B# G
                        @.HasOrder := true;/ q0 \$ F) v8 [# U$ e, ^+ b
                end;
) `! L1 h' T. n, P( o4 S        end;* \& y( d/ V7 [, e
end;        -- of the method' }! p$ B9 P# @% C9 R3 X
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑   ~# q$ T1 d7 h/ J" H
- L$ O$ S: r" r$ I8 G
这是AGV_putin中arrive的method。
- n5 `, h# g( l) x( w  L: K: V
5 y/ E6 K: m, u4 z. H' C当到达物料速度越高时,这个报警更多,
6 a, ^- M4 Y5 x/ n+ I/ H8 w/ S0 c4 G可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
2 Z0 Z* v% v0 F0 _' _7 ~6 l程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
- A$ s6 |% Z8 a- L) d
! ~% N' f4 P  N/ a9 W, ]3 V另外一个小建议,就是move,所有的move都可以这样
: u- S  d7 H$ ]* _' Yif not move() then debug end
0 m2 |( @& G  [# S' G这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
& V# a+ y8 {  }plant simulation中的free libraries有AGV模板,4 \9 ~- J+ S0 y2 C) L3 F
里面也有案例。# x6 W. `2 M* f. C1 n! i: D
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
- w& C0 ?. M! y/ k5 e% a: V6 f7 u  c; r' O  R
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 4 t$ t7 b: O* X* F- T4 U7 Z; A& U
, N5 Y8 N7 Q1 w3 |% @0 O
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
5 ]8 l& u: n; I: b3 Z4 n这是AGV_putin中arrive的method。
+ }, V" `* G5 O* n, N
4 j* L  T) Q2 ~$ b4 s8 }. m7 X: Q当到达物料速度越高时,这个报警更多,
& \4 V/ X9 k7 K+ j+ k
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-23 18:28 , Processed in 0.019444 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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