设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6632|回复: 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'2 v) F0 x& V. ]) q
*/
( _. Q% O9 c: t  x0 P* I3 uis' g$ V+ N4 _8 t3 o3 A$ `
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
- x+ ?7 B; l2 \" ?- v; o6 _do# b2 M$ s, }& u( p# X$ `) c) T' U
        Lan := rootfolder.Internal.Tools.AOLlanguage;. Z' ]3 y/ X, Q+ t5 {$ O
        if current = @.Destination -- else return, r, b( d9 u" s2 b# O/ R
        then
2 ?. g! ~! h% T( t7 h. C                @.Destination := void;
$ w0 m8 W- V0 n- X, `0 R9 P                if @.occupied then( h# i% J/ L: d( A; S
                        part := @.cont;
5 v$ N4 W2 E% x  [                        @.transpOrder := void;! c2 z$ D" r4 I+ A& f3 o
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
8 x* T* k! Z- ?# L: E) l$ ?/ N                                @,root.eventcontroller.simTime);: Q3 ]& G9 w# Q/ j0 T% U
                        @.HasOrder := false;( I( A% w: K( w1 n
                        @.DrivingHome := true;* H7 T% q& w3 D: }
                        rgManager.tryToStartTransOrder;) G( x8 |6 m7 }* O. L, u
                        if @.Destination = void6 R0 w& f% K( Z/ Q# v* j" P
                        then -- no transport order for vehicle @
% n9 M' {3 ]/ C- m4 |* Y0 k                                @.Destination :=
1 {5 z: I4 I( L. J& e                                rgManager.nearestFreeStation(@,track.~);/ x6 H9 B: A8 Y% j. r1 a9 h  ~
                                newDirection(@);   8 Q+ a; k0 b' p; @1 v
                                if @.Destination /= void then' f; q2 h8 ]4 w) g4 L4 x
                                        @.Destination.NumReservation :=6 h9 f" z& g  l5 I8 U
                                        @.Destination.NumReservation + 1;
6 D) Y6 w9 ~0 f8 R1 @- l9 W                                end;* b% E, X2 d7 ]# p0 E1 Q8 e
                                @.CurrIcon := "drivingHome";5 y5 u; f4 O( M4 Z
                                @.DrivingHome := true;
4 p; X7 W" ^: f7 p% _: o                        end;
# j4 {+ Z$ f1 J& `  Q* E                else -- the vehicle @ is empty, both vehicle and part are in the same dock station. u( [- {/ d6 f
                        part := @.transpOrder;
! Y4 ?+ M$ v5 c2 O6 _5 t1 k                        part.move(@);-- load part
+ _8 [) t* V+ |/ ~                        @.CurrIcon := "load";! L# f; \, ]; U
                        GlobalDistObj := part.globDestination;1 \3 U: B; x/ q* V7 t/ y
                        assignLObj := rgmanager.rgAssignL;; j' Q! E5 c8 P7 F1 i, L
                        row := assignLObj.getRowNo(GlobalDistObj);
0 t9 D, r1 S& W1 O* ?% L                        if Row = -1 then -- since 70
: u2 A* _5 f4 P9 C                                if lan=1 then6 |% G% s- Z+ p8 d8 B. T
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),4 h' B: O4 W1 f% C
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
, i' u& H3 A7 [/ A7 O                                else
8 I8 b+ G, |* F/ |5 g( y. E$ a                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),$ Q7 J9 N; J5 h: s/ c
                                                to_str("in docking station: \"",?.~.name,"\""));                               
: Q/ ^# K1 s# k: \                                end;8 _- E$ ]) n% P, W
                        else, y* y3 s% _. r
                                @.Destination := assignLObj[1,row];
+ s2 t" ]' f& I- Q& h" F# z2 a                        end;                       
' B4 F2 f2 F* ^+ }. @5 W8 W3 ^5 l                        newDirection(@);
' Q2 H' }: L# U8 ?! A( {! k                        @.HasOrder := true;! B! K$ B& X3 C  I5 p
                end;
4 E# F/ w* L6 F  ~, F        end;
' l# E- q3 B$ e7 send;        -- of the method- K& Y7 o$ ~& i/ f  l2 X7 E" h0 n
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
$ F' N; E( A% @/ a
$ X1 c0 O/ H6 ?' `这是AGV_putin中arrive的method。
: l# g" N) |8 G+ d6 C8 {" f. h9 [# w! j: Y& u0 T' u
当到达物料速度越高时,这个报警更多,
$ ^+ Y1 r# E" k* J+ E# e* m4 \可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
+ I2 {6 z9 N6 x) V* J2 S  `程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
4 }/ b. T- _" s7 |3 l9 \, o6 R" s0 q' M) _" t1 v# K3 `
另外一个小建议,就是move,所有的move都可以这样
" T% g" D  v, d7 ?4 j/ Nif not move() then debug end( W# \/ O! Y; p6 c4 P
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。; }  I: j: @+ I" p! A& O1 U
plant simulation中的free libraries有AGV模板,3 Y6 @& ~3 m3 j/ U$ I
里面也有案例。/ W1 ~3 I' g, x$ F5 a4 Z
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
) P. I+ ~7 M, ^" O/ s! k/ a' y* `! @8 `" z
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 / V- y; `0 V' u; R: ]5 q

/ q+ S; k3 o' v+ ]- `4 i' i9 ]% ^6 a, @那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
* x0 C: O! ~$ c0 ^( r( B这是AGV_putin中arrive的method。7 F8 }; p8 E: v. I+ Z7 p" e- S

( @+ \" P) j9 w8 r: a. |( O* `当到达物料速度越高时,这个报警更多,
  \: Y& S9 ?( l/ @  u
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-17 13:22 , Processed in 0.020978 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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