设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8414|回复: 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'
/ \: E3 I; j) e, s' Q- d. y% q3 _*/
% a! c8 t/ k; P7 gis
* s" h+ E7 K$ C4 P        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
0 C; S0 ~# d9 c9 {  |% G! I% [do3 u8 P+ H0 S: X/ t' `
        Lan := rootfolder.Internal.Tools.AOLlanguage;
, H/ g. r% J7 Y' q# ], P0 d$ l, A( q        if current = @.Destination -- else return: x7 b' |6 b4 L
        then( {' y  B0 z  u6 S
                @.Destination := void;3 P1 {: O% g: \" e3 o
                if @.occupied then) L" o$ X0 N  C+ G& W7 v( ?3 M
                        part := @.cont;! n/ V, T: p' d8 Z+ T
                        @.transpOrder := void;" {* P# A( O" G/ m" n* ]
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
1 |# N* I0 v) ~0 _+ P                                @,root.eventcontroller.simTime);0 u& m4 {) D2 I* _, n
                        @.HasOrder := false;
% E% K! B' b4 A/ F                        @.DrivingHome := true;2 m* j3 @% g8 z% B' _4 F
                        rgManager.tryToStartTransOrder;
" W# `2 x( y3 I' B4 }  ?9 e                        if @.Destination = void
6 c" Q7 B! J( p# N1 Z                        then -- no transport order for vehicle @: `( X/ A7 Z$ Y* n- J
                                @.Destination :=- @+ k1 f/ h. M4 j4 C" M& p
                                rgManager.nearestFreeStation(@,track.~);0 f0 u# n- `: I1 {8 V+ i1 r
                                newDirection(@);   
& P- Q( O# ?  f. E5 a4 p                                if @.Destination /= void then
0 l1 h; h; }+ P                                        @.Destination.NumReservation :=' k+ `8 b2 L- i9 u% f0 ~
                                        @.Destination.NumReservation + 1;9 \2 r+ a4 K- k8 {' u" G
                                end;' Y9 o" q- ^4 |8 \
                                @.CurrIcon := "drivingHome";
$ h1 S5 x5 e. C% Q  l                                @.DrivingHome := true;$ ~' ]; L1 ]! G0 j
                        end;
" ~3 z9 o- f! C  @0 B1 u                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
) T- j" Z2 j6 g( o% C8 O) \                        part := @.transpOrder;/ u: j/ C% u& y$ r. |  V
                        part.move(@);-- load part
: Y, F3 f: C8 I& }                        @.CurrIcon := "load";
2 q$ \! F1 _2 i0 x6 ^                        GlobalDistObj := part.globDestination;
/ j0 b' h* ~' k# X                        assignLObj := rgmanager.rgAssignL;& n+ X. H8 Q# D. t% l
                        row := assignLObj.getRowNo(GlobalDistObj);1 h7 ^) h' Z, H( L
                        if Row = -1 then -- since 704 E+ L) c  r! H$ x& t3 {
                                if lan=1 then8 J+ S' v1 r; l3 `% x. U' a/ |
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
/ L& l/ X6 P( |0 M! N  `2 R+ i                                                to_str("in der Andockstation: \"",?.~.name,"\""));6 Z  ~: d, `8 a! F- u- Q/ }
                                else( A6 i8 t( t% {2 W
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
( W9 {4 E( U/ }8 O5 k  C4 W4 Q                                                to_str("in docking station: \"",?.~.name,"\""));                                4 ^+ L4 E" q7 D. Q
                                end;5 P) Y5 ^+ ^( }5 J
                        else
# y+ }; m+ D* N8 L                                @.Destination := assignLObj[1,row];2 v% u! c+ F3 W: Z
                        end;                       
7 B' E8 w8 b( k" i; r% ?2 h                        newDirection(@);
: e# Z) z5 [4 S2 p                        @.HasOrder := true;
5 J* k8 L& S7 G9 U# g& p  g. G. O! O, g                end;" T5 Y8 n2 k% T% t1 ^
        end;
/ ^* l% J: s3 A. P1 R/ P% Jend;        -- of the method
0 B6 X; m! J$ K5 C+ C( F+ v
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ' ^# S/ l3 {% }9 i4 z

& P1 Y# F7 t, J# @这是AGV_putin中arrive的method。4 j/ H8 E7 m0 ]8 o- ^& e

! B0 T2 a7 |: D$ Y6 J0 E; t当到达物料速度越高时,这个报警更多,' M3 k0 S. \1 G/ `
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
5 V) B% \+ D, M, D程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
; I0 `8 F' P7 @4 i) ~1 c# z( @, E9 n, U  Y
另外一个小建议,就是move,所有的move都可以这样& U. o% W" c% |7 s1 H  s
if not move() then debug end
/ ^  n! l7 Y/ b2 s0 j( G这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。' w5 C9 N: i& ]& ]# H
plant simulation中的free libraries有AGV模板,
  Z9 W4 C+ x3 w5 a, X里面也有案例。/ Q8 f* a" Z$ @, [+ B! @( j- m& K
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
! M4 S0 n% q( u  B! A. u; k$ P; ^4 g, W0 R9 _( o4 M
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 / U: ~0 A' X- [7 M

( F9 X; r. y/ b那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
3 s0 R$ s6 W( H$ s这是AGV_putin中arrive的method。
- H+ _" [; H3 c7 r: R1 J! p& \9 K% X4 E- Q
当到达物料速度越高时,这个报警更多,
" b1 |) W* f, t- X  U  M0 p
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-2 11:33 , Processed in 0.014936 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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