设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8508|回复: 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'. m" g% b$ B0 d; V2 ?0 J) d( W
*/. B  r% B3 q* e1 [' e- Z. j$ ^
is
9 ^1 S& X/ |7 ?7 L: V  I        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
# v. N4 f) D+ Z% z0 S3 Edo
" ]! Y& M6 b' F' Q        Lan := rootfolder.Internal.Tools.AOLlanguage;2 Z9 Q' u  {9 p8 n
        if current = @.Destination -- else return
  H: J& A. O. Z+ J: o1 s- r6 u* J' G        then4 D1 \7 e. |# i3 ?
                @.Destination := void;
9 E; y, t9 H# d4 S/ X                if @.occupied then5 Z9 @: Q# P( [: X, g! Z' r0 e
                        part := @.cont;
! w5 U0 o  l3 V& V$ `1 N                        @.transpOrder := void;
" N" G- `/ G( h) D! S- }                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,4 x: D! {' w0 f6 {. X+ [
                                @,root.eventcontroller.simTime);
, ^! r0 j8 }/ E2 M% b; E- L/ M1 y                        @.HasOrder := false;
  m8 i! c8 [7 Z  \$ u                        @.DrivingHome := true;; z6 {0 p. X: I- f: z9 V  s
                        rgManager.tryToStartTransOrder;
' O- Y; o5 F) I. h                        if @.Destination = void
9 `* a- M0 K% A, }0 _0 p/ l                        then -- no transport order for vehicle @
' _4 q8 V" I6 y: ~1 H$ w                                @.Destination :=
% R- O& l8 S/ p                                rgManager.nearestFreeStation(@,track.~);
( b8 k& X: ~2 g4 S                                newDirection(@);   
" t" r% D4 x+ e8 n$ V2 H                                if @.Destination /= void then- }; Y+ V( ~, n0 k7 N8 `
                                        @.Destination.NumReservation :=& |0 C4 {% n1 X
                                        @.Destination.NumReservation + 1;
% \- h* _6 j! y  R; F0 X                                end;, ~- @( B6 O9 N7 `# T- {7 z
                                @.CurrIcon := "drivingHome";
+ ~( _( n1 A2 X( Z0 K                                @.DrivingHome := true;) P8 k7 d! b( c: u) z
                        end;* G% k  i5 v2 m' k+ X0 u) \
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station7 B8 }% }  ~; @, a+ R. m
                        part := @.transpOrder;! A" G4 [% B$ v
                        part.move(@);-- load part5 M$ p3 l8 G. T5 h, w: D( z
                        @.CurrIcon := "load";
" L* Z( z% o# X5 N: d- a& N                        GlobalDistObj := part.globDestination;
/ x! |  K# E! u  M! M# X! y                        assignLObj := rgmanager.rgAssignL;
2 C, {% `4 B& [4 a. l2 g/ w* g+ D                        row := assignLObj.getRowNo(GlobalDistObj);6 Y5 \& {- C# B9 b( y# v/ J
                        if Row = -1 then -- since 70: L1 r) P% y/ j& Z
                                if lan=1 then' R, [5 A! N' U8 X+ m3 [- v' h
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\"")," _) S- i* g% C; m  B7 n
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
1 X# ~1 J) H9 J/ C) M                                else
( e# [& _# i/ u/ ~) K4 G! i7 w1 r                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
2 r& {! j: K2 a# }5 Q8 u                                                to_str("in docking station: \"",?.~.name,"\""));                                : u, y- Q7 a) \
                                end;6 @8 @( K# k9 a, M' u! [
                        else2 d! G% y+ u  K1 Z
                                @.Destination := assignLObj[1,row];
% x* K# f' i+ {/ S- X1 c                        end;                        " u1 B& l5 {& v3 h
                        newDirection(@);2 X! x& M! Q  G5 |
                        @.HasOrder := true;/ P4 P  n" q4 g0 D  C" v& g
                end;4 T: @8 r8 e; o+ e
        end;7 u9 e9 x9 Q( S; e% M% b$ c
end;        -- of the method# [2 |+ g. V% r- O6 a* c7 Y
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 , K. r3 x) ]$ C8 Y) ^4 x" m
4 q' [" K3 X3 t9 x4 q3 t
这是AGV_putin中arrive的method。
2 ~. q* s1 ^- g3 e1 M" I, j+ w" x  R' Q: r* \, J
当到达物料速度越高时,这个报警更多,# U1 B* I6 c& n6 X
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
3 v& n  S: R# T& l% a程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
9 S, Q2 h2 E3 c, l
: a; C' R1 @0 Z+ l另外一个小建议,就是move,所有的move都可以这样
5 `8 z0 r  \2 D, W9 Q' j; Dif not move() then debug end' Z4 F( C! E; t, x5 ^9 b4 b4 m
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。- O* z/ x8 ~# Q3 G+ \
plant simulation中的free libraries有AGV模板,
( h- v: a6 w$ G% W8 X" c! \里面也有案例。
1 E  n- W1 @& p/ U: Y我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
: h" c1 q! |% j  `+ `. x4 O1 ]9 z( ^  |* h: e' y
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
3 l: y" X- V' X+ x" I( D
* W- m& O& i6 j8 V那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
/ c+ @: s) K/ c9 y9 ]这是AGV_putin中arrive的method。
* L6 [9 b3 A2 y4 t2 a) h+ T% u7 B* M3 V4 s+ U
当到达物料速度越高时,这个报警更多,
, r, ~$ P5 p6 t2 N! ~: h3 F8 n
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

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

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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