设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8623|回复: 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'  J9 ~' q: L  z& l" d2 |
*/& Y* A* q+ {4 L3 S( d! V
is
( J. ?5 _3 s; p        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
4 p. ^8 }! G& P% A4 ?; t, ido6 x2 h; A% r) e; R# i2 u
        Lan := rootfolder.Internal.Tools.AOLlanguage;
- [+ V* U) K" J1 K& K" u        if current = @.Destination -- else return  R7 ~0 F/ o, N- @9 z  l
        then
/ \# C9 X" k) ?4 e2 n                @.Destination := void;, S& o# n$ n$ v5 V
                if @.occupied then
6 [6 P1 K% i, g# b! U9 b                        part := @.cont;
8 U% Q% C0 w8 ]& i                        @.transpOrder := void;
( V1 {4 Q$ T# N9 j+ x7 l% D5 |                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
/ L0 O$ q0 J; F, {1 I                                @,root.eventcontroller.simTime);
' I6 J0 ~! E  H. @$ G5 c                        @.HasOrder := false;7 b3 C: @( z* f& a$ K) m8 `0 u) i  u
                        @.DrivingHome := true;
2 i; ]5 r7 {9 t( Q2 N  v/ k                        rgManager.tryToStartTransOrder;) c4 f) C( i7 Z6 U  n
                        if @.Destination = void9 X" v2 c, u. W( E; o6 O2 e
                        then -- no transport order for vehicle @
, x* C7 L% V; `# {                                @.Destination :=* Z' ^" V% ?$ @/ S
                                rgManager.nearestFreeStation(@,track.~);" m$ q1 \. [5 g' u) s* r/ f$ x$ w
                                newDirection(@);   
4 n6 n# w8 m9 ^) a0 ^' ?+ h                                if @.Destination /= void then; A9 m# x4 @# V0 k
                                        @.Destination.NumReservation :=
) e7 H4 @% [7 C. P9 h! R: Y# J                                        @.Destination.NumReservation + 1;
3 m/ _( s9 S6 t0 i0 {1 x6 {  A                                end;) A3 k4 a7 ^! l; I& @, c6 w3 q, p  H
                                @.CurrIcon := "drivingHome";: j/ G6 Q: L( y2 D- ~* p( m4 M$ g) a
                                @.DrivingHome := true;! q% [2 v* S# O( r8 B
                        end;
, C+ A  s$ C! c! q( R: c                else -- the vehicle @ is empty, both vehicle and part are in the same dock station8 J$ m( f0 S8 {- ?
                        part := @.transpOrder;
* d8 H4 [1 T) U& x7 ~2 t                        part.move(@);-- load part
' S; h4 u: N6 l7 h4 X5 Z                        @.CurrIcon := "load";* l; \3 _8 J$ g! A8 g. c4 C
                        GlobalDistObj := part.globDestination;
$ A& w7 N- a  P; o$ l                        assignLObj := rgmanager.rgAssignL;. ?1 L8 l% e: ]  n
                        row := assignLObj.getRowNo(GlobalDistObj);" O, k* l0 U. m, B
                        if Row = -1 then -- since 70. i8 M! O* k/ ~' G* O4 A7 O( h, \$ @- v
                                if lan=1 then* @& d1 b, I4 O( A
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),$ D3 z6 d) w3 s" W
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
5 D3 a2 C- `. x- P( J8 S3 `                                else
* n4 ^$ [4 O& \1 Q9 x                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),) ^, [) q" b$ {% C
                                                to_str("in docking station: \"",?.~.name,"\""));                                6 L$ f8 a$ |% }
                                end;
, k3 f/ a* _# O6 P                        else
* \/ P$ @' m0 c                                @.Destination := assignLObj[1,row];
! i# U( U, l' A                        end;                        * t; }2 m* z0 ^
                        newDirection(@);
4 S: Z3 J% W/ U8 y+ V, [8 O8 }                        @.HasOrder := true;
- o' B/ z! x; {: F$ M6 G# c                end;
% s0 C  b8 p1 e- K+ x" s/ }" D        end;
% p6 `6 I7 g1 X: D9 a# v1 K. K& c+ aend;        -- of the method
% a/ A- P) V0 W5 J4 y4 ^3 l0 {
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 - j& e) w8 V5 p/ y  r
# S; ?- @' l, S+ P5 \
这是AGV_putin中arrive的method。- I% K& ?6 ^  E, X
3 t6 W" a/ s7 z! ]' t$ q
当到达物料速度越高时,这个报警更多,& U4 H0 b, }3 L6 K& }- E  w
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。% R8 ^1 d- }' a$ \" t
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
; H( p+ H: L: q4 L2 |  d! r2 z) u0 q/ A9 f+ f7 E7 H
另外一个小建议,就是move,所有的move都可以这样
+ r% ]# K8 M$ C: I/ t% l5 Aif not move() then debug end1 Q4 C7 g& B2 |# b
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
# i. |, K8 p# t' x8 ^7 P3 Gplant simulation中的free libraries有AGV模板,& `5 L. W2 |8 @- r. \
里面也有案例。
% |1 l# s, H/ Y  l我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。$ F- w  T$ k( {; j5 [" }: x* E! Z' V
, a) m# a& j9 r/ I5 L* \& h# k
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑   n& _9 u$ H7 \4 K  ^& s

6 d1 f- u( M, \# i* |" e那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
* M! M) M6 B1 ?+ y这是AGV_putin中arrive的method。
+ i9 H6 J0 K* @7 k, B
" `8 o' ~0 u* |" P" m; a当到达物料速度越高时,这个报警更多,
' \6 G# }% Y2 K# M8 \
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-16 13:59 , Processed in 0.015924 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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