设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9604|回复: 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'
# P6 x8 b1 c, E*/7 e( B  k( V- f. I/ n$ |, S1 N
is
* y3 f8 ?0 Z& ^        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
1 d1 Z) s' W* H2 Q2 C+ O( g( j4 Pdo  h9 `8 `3 p1 r* [
        Lan := rootfolder.Internal.Tools.AOLlanguage;
( T/ z* J1 a3 a4 {        if current = @.Destination -- else return
5 v1 l  i0 m4 a        then
7 x6 e- `9 e0 \                @.Destination := void;
1 J, O6 }$ e' r5 C" U& Z' e5 J                if @.occupied then2 |' u' y- S- W1 v7 l7 w, a" P
                        part := @.cont;, y" a; S9 l5 G" D0 F% ?. Y8 k& G% V
                        @.transpOrder := void;' e; P3 t! [* d: Z0 E
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
, o% F% u1 |1 \' j) E3 N0 X                                @,root.eventcontroller.simTime);
, |4 e: s4 F  A! ^( u( ?8 B) d9 d                        @.HasOrder := false;6 L" }4 d, x% N6 J# S* c! M
                        @.DrivingHome := true;
$ G/ j! g, A. x, ^0 n                        rgManager.tryToStartTransOrder;
5 D  ]4 H$ t. R7 D                        if @.Destination = void
6 |4 d* ]; t; O  J; Q: F& ~                        then -- no transport order for vehicle @
# x% ^; @( r6 |. `' R6 f' G                                @.Destination :=. _  `# |* P- ]. e+ g
                                rgManager.nearestFreeStation(@,track.~);! K8 H7 N5 M& u5 m+ h/ E
                                newDirection(@);   
" f) ~1 J2 c) N! Y$ d                                if @.Destination /= void then
/ z. X3 S( [, @- y                                        @.Destination.NumReservation :=5 p% S+ H. ]5 t7 Z
                                        @.Destination.NumReservation + 1;* u# R) w  ~6 T7 T& G9 ^& K
                                end;
! N. ^9 f) R, e9 W/ C* q! g                                @.CurrIcon := "drivingHome";) j4 v9 k; P2 u
                                @.DrivingHome := true;1 }& I* J7 t) V" _( A$ i
                        end;% c7 Q8 r2 s/ N+ P% O9 E3 r" a
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station4 q9 I: K& Z1 k% L! t1 j9 h% K
                        part := @.transpOrder;( m( |  E7 h: L. C+ D( k0 H
                        part.move(@);-- load part
+ u% }  b, [! g. _2 H+ N& [                        @.CurrIcon := "load";
* d# q2 _! G  G                        GlobalDistObj := part.globDestination;
. Q2 I1 Q+ T: ]  o% s% ^                        assignLObj := rgmanager.rgAssignL;
) b/ A; h/ ?  m                        row := assignLObj.getRowNo(GlobalDistObj);  p! [8 t. a/ B! c/ |$ N
                        if Row = -1 then -- since 70. f2 u8 H, _4 C; j! u* y% z
                                if lan=1 then
9 n6 Y! A  q& K2 j% Y1 f2 o' Z" b                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
3 ?. }, Z* ]$ l) U1 p  j* R. Z( l                                                to_str("in der Andockstation: \"",?.~.name,"\""));
$ i9 a1 ?! t8 g1 S: O8 \                                else
) O; i" w9 G- {+ F7 o                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),5 k$ J  `& @6 A  Q0 `" x, E( a* n& c
                                                to_str("in docking station: \"",?.~.name,"\""));                                & W' ?- a6 ?# C8 s
                                end;0 {# w/ D# C5 L
                        else
3 U( D1 {6 F( _5 I/ i! ~0 T) t, O0 _: I                                @.Destination := assignLObj[1,row];6 v8 v: O4 r& y. \
                        end;                       
3 _$ W3 j+ e2 D4 u+ B" w/ M+ Y" p! k  I                        newDirection(@);4 U" Q) V0 e  I; }
                        @.HasOrder := true;; T: t2 P# r6 }. e
                end;, `* Y! e+ W8 O( U2 W; H# N( l
        end;7 }7 Q# y( P  O5 h, H/ G% A6 v
end;        -- of the method
3 K2 o6 E2 E  a) ~
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ; W: l+ @% [8 J( V

, z5 G" a/ q% a6 k0 K这是AGV_putin中arrive的method。
/ |) Y# S$ K$ l  |; |" B! `' ~; z$ ]) U+ g" J& r1 v; Y
当到达物料速度越高时,这个报警更多,
: H! d( @5 L8 o+ c. `- v可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。/ p; w/ k% G$ c5 _4 c
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
1 N- g0 ^# V3 [
) M8 }# J- r4 a0 ~! @另外一个小建议,就是move,所有的move都可以这样4 V( N" Z( J( M- j" I
if not move() then debug end
* W+ c4 g0 c, q( n" G* I这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。0 ^7 A0 f8 R7 b8 {
plant simulation中的free libraries有AGV模板,# C/ y2 Y8 f; p2 H
里面也有案例。: X& q$ ?% l' c  u( L2 Q0 M6 t
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。2 ^& h% I; i. J6 c1 s
9 ]  ~' m* X5 i5 f9 I# z, H* t  ?$ u
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 , {' c3 L8 }% R" c1 A* z8 L% H

0 h2 ]3 Z. i9 L- I0 Q那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
& F& ~! l1 _+ p- S4 o% }这是AGV_putin中arrive的method。
1 R( l2 V, K1 Y( j
* p4 B/ q1 N! V! \% C4 q当到达物料速度越高时,这个报警更多,
" O# c. q% o' F# F
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-11 06:16 , Processed in 0.024047 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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