设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8603|回复: 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'* R' B  b1 e( `4 ]' _
*/
# d8 u. t& z! F  ^6 wis$ s9 M1 ?6 h/ T6 M
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
' k+ Q# F) ^: s0 F7 mdo
. o6 a+ l* `" T. Z& T8 t        Lan := rootfolder.Internal.Tools.AOLlanguage;# W$ I! b0 L9 I) P4 i
        if current = @.Destination -- else return
4 a% Y: }. [3 O" u# K; Y        then. X, v0 j1 `) L% A+ M2 U
                @.Destination := void;' @0 S* x8 N+ G/ ]1 V* }
                if @.occupied then, m6 X: w) h% u4 x% ?
                        part := @.cont;
$ V4 M+ v' ~$ l% N. Z+ w2 ?1 j                        @.transpOrder := void;
+ x8 p& Z5 L" x' }2 {8 ]; Z! D                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
( Q; p8 v$ n- u/ K* p3 i                                @,root.eventcontroller.simTime);3 @( u% M" [2 S& i4 P2 A
                        @.HasOrder := false;/ s7 a5 @& m  L, P8 Q2 [
                        @.DrivingHome := true;+ S8 w0 f% y: v- e4 Z
                        rgManager.tryToStartTransOrder;% I9 r: F* B# Q  p* d4 }
                        if @.Destination = void
% o( [! X( L) W% A- _" m& W                        then -- no transport order for vehicle @$ u- ~0 L8 F( h, p, s
                                @.Destination :=
4 S  \- b$ ?: P5 s                                rgManager.nearestFreeStation(@,track.~);
- H1 a& f% L! A                                newDirection(@);   / h, k2 m* S" i' l2 ]
                                if @.Destination /= void then" `4 i4 I+ \+ p  N+ i
                                        @.Destination.NumReservation :=, Z9 v6 m0 t/ d: A  i, ~/ }- P4 F) x
                                        @.Destination.NumReservation + 1;0 x8 c! R+ M3 u$ M8 L
                                end;  ~+ h6 K) D2 [" {7 \2 S4 Z5 O, o
                                @.CurrIcon := "drivingHome";" p/ o- R0 X9 }, ^0 U, B  V
                                @.DrivingHome := true;
5 G% ^  p" }: u: t; p                        end;
# e+ r5 y5 X- p0 [8 u1 W                else -- the vehicle @ is empty, both vehicle and part are in the same dock station4 O. R7 ?" r  H1 A" |
                        part := @.transpOrder;
3 C* v+ @5 ]8 ~" f; G+ B: O9 w                        part.move(@);-- load part+ f5 f+ B6 P/ _. I: b/ O+ D
                        @.CurrIcon := "load";8 k4 l4 ~0 @* T& i9 n5 y! m; P
                        GlobalDistObj := part.globDestination;
4 F$ y( E# Y& w* i; b+ S                        assignLObj := rgmanager.rgAssignL;
& a2 x8 X1 c$ f2 O2 B                        row := assignLObj.getRowNo(GlobalDistObj);3 v, D" ^+ R. i# g) N2 w0 O# U
                        if Row = -1 then -- since 70
5 d  x5 m7 p' T                                if lan=1 then
. p3 \0 q5 F  c                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),2 \& q3 F9 ^  n- y) d6 t4 b* B- s* t, R
                                                to_str("in der Andockstation: \"",?.~.name,"\""));' X: V+ }) p0 m$ T' J
                                else7 B# k& b, u# Y& O0 j1 m7 N
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),! {3 s/ C* N; z
                                                to_str("in docking station: \"",?.~.name,"\""));                                7 C  j% C: y2 O1 F+ H4 M1 F
                                end;* N: b0 ^  [% A. I( O5 O) V2 m+ c
                        else
5 m2 X% g! p* O$ u                                @.Destination := assignLObj[1,row];
4 X4 H- X5 t7 ^                        end;                       
% g" ^6 n* c6 Y1 S6 t/ }                        newDirection(@);
9 q' [' }7 O5 J3 Z) o' N8 P) D                        @.HasOrder := true;
; e$ I; R9 v+ ~; u                end;2 M# t7 h0 }& l" i% \: s3 i
        end;* n$ G( f5 A2 S
end;        -- of the method) X4 ?- t; x6 u/ ?8 ]& v4 r
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
4 a/ [% u( A' k( Y* a' R3 ]
2 ]# Q& g) z: d. E9 ^4 u" p这是AGV_putin中arrive的method。5 k+ K* x6 ~4 l0 d4 `- E
- G% q4 p6 [; V
当到达物料速度越高时,这个报警更多,
( {' p1 z1 E5 g6 ?: c$ q! U! L可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。: J; d6 V- ?# |" G- k9 J
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?8 T5 z8 {, k# I. G
# i1 s* t: K, X+ e! e
另外一个小建议,就是move,所有的move都可以这样
- N5 a" F, |) Uif not move() then debug end+ i, t" ]1 g! e2 k" q/ y
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。3 v  {3 _8 E: o7 E) D
plant simulation中的free libraries有AGV模板,
5 {% ?* F( N0 s0 p1 j8 k里面也有案例。. e9 G* L4 L* n% N) @
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
( @  l3 u' q2 ?6 b1 E. ]
- i2 q1 L- s8 v( R我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ! o* Z1 J% a  q3 C

) K4 l' @; P& V  g1 K5 b. y那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
8 T7 ~. ]0 h9 R- b4 L$ i, O: N这是AGV_putin中arrive的method。
: k  Q% v. m: Z+ G3 G% y$ |
! I5 R0 g# q5 S& \) ^当到达物料速度越高时,这个报警更多,
0 s0 t* }& m& }2 b) N: n! \/ M% p
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-15 01:01 , Processed in 0.017921 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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