设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7869|回复: 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'. d5 ^9 i( m( @8 o0 P
*/  z( ]/ q% e3 o: g
is
( L8 o2 T0 o+ D) n        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
9 k% g* Q0 `6 N, l, R2 U5 Hdo
) w2 G$ Y( q$ b, k        Lan := rootfolder.Internal.Tools.AOLlanguage;; u5 r/ V0 A+ y! i4 t5 n' [
        if current = @.Destination -- else return
6 G0 K# I0 ]/ m( F# w        then& d# ~8 B2 Z0 n  k5 c+ U
                @.Destination := void;
+ m5 b# e" g- D: G% q                if @.occupied then
3 t& B$ V- p* Q; g2 @3 b                        part := @.cont;3 @( x% B8 {/ q' n
                        @.transpOrder := void;
1 a2 {, H9 L( ]# x                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
- f9 R& q* q" t+ N9 b3 F5 G2 ~                                @,root.eventcontroller.simTime);
( y+ a# d8 f- N+ m                        @.HasOrder := false;' u6 v8 J; Y8 b8 F$ V9 t% l. L
                        @.DrivingHome := true;
' h$ N+ @  T9 }                        rgManager.tryToStartTransOrder;- l+ {5 _( P# c
                        if @.Destination = void
( n. A2 l8 E+ p0 A* ?% _# R                        then -- no transport order for vehicle @
9 e( F! h& H6 ]* o9 n7 _                                @.Destination :=
2 G- V9 a4 {3 j& i                                rgManager.nearestFreeStation(@,track.~);# I1 R. z6 I0 w+ ^  @$ Q; m) B
                                newDirection(@);   
" o, j7 t$ Q0 B# [% {                                if @.Destination /= void then! I* p5 W9 B% O
                                        @.Destination.NumReservation :=
; r$ r* `; x- }0 c0 `# @5 K                                        @.Destination.NumReservation + 1;: [2 g3 G: i1 F" K1 y) w
                                end;; Q1 e. j. \( H" U
                                @.CurrIcon := "drivingHome";
+ }( U% h4 W- ]; {. M# ~9 D! Q% t3 D                                @.DrivingHome := true;0 D- v: j5 ]6 Q1 R9 T
                        end;
' O- [( H: Z$ D# K: b. i% O                else -- the vehicle @ is empty, both vehicle and part are in the same dock station: g. J" L8 d! M
                        part := @.transpOrder;
1 ]# I0 v, B# r  U: y* k1 s# A                        part.move(@);-- load part- q4 L  }& G- g( M! s/ j( O
                        @.CurrIcon := "load";
- b; G7 K% {7 z  g+ X+ w                        GlobalDistObj := part.globDestination;$ Z" b/ M2 b5 a: d
                        assignLObj := rgmanager.rgAssignL;
4 N3 h1 Y( X, |9 O                        row := assignLObj.getRowNo(GlobalDistObj);# S. |+ S4 K! s% ^0 \
                        if Row = -1 then -- since 70+ {0 d5 ^1 k9 x/ M" u
                                if lan=1 then$ I& F4 S1 ]7 M2 O' w& i
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),) Z6 X* W. Y3 n9 \& X# O; v
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
8 Y: H4 l% W; T: V4 B                                else  q( X9 Q7 z! y; k: V  ?$ L
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),9 F7 C4 ?5 N$ ?( D8 |  q
                                                to_str("in docking station: \"",?.~.name,"\""));                                . ?7 z3 D; R0 O7 e. C3 E# j, J' V
                                end;
- ~# _: p% n7 s5 ~- l                        else8 Z9 ]! r" n. k1 R% Z5 c" M
                                @.Destination := assignLObj[1,row];  y4 H* @1 ?5 z; {; W
                        end;                        6 h+ K' B5 C4 E$ ~) [5 W
                        newDirection(@);, z5 m3 @, P% Q' g  P" b7 s
                        @.HasOrder := true;
/ b* ]) ?0 V; L- J2 @! V8 E1 z& L$ w1 ~                end;
. g! S* x! E/ c* O/ ^        end;
* Q6 P  D5 L( ^, j) @# nend;        -- of the method. A& B% P9 W' Q0 t  _4 I4 s* g; r7 |; c
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
# v- |+ g$ ?# C' _' p+ ?& |3 o5 y- q* X* p& i. @2 N
这是AGV_putin中arrive的method。
% j- b* X6 _4 A0 u( }! \
0 @1 R$ `6 O2 E9 k- m当到达物料速度越高时,这个报警更多,
6 a1 g) d# M, M9 v& ^: l5 i5 o7 {可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。( n1 J; q% p1 }0 S
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?) j" s7 M0 x" C
1 p! Y& y, r/ R' Q9 I, N2 q" _
另外一个小建议,就是move,所有的move都可以这样) s5 y5 ~" K) y& y1 n7 S. e1 Q2 V
if not move() then debug end
6 z( d- y/ y% E# X4 y2 p2 V# O这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
- h& f# _* c0 a- Pplant simulation中的free libraries有AGV模板,
1 O5 @3 b0 a& ?# P9 z, D% \2 H里面也有案例。( D) i, |  i8 r" ?% ?' ]% N' |
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
1 @! O" }" ~3 {& o7 }
$ h' h8 X  C6 Q7 J; X( Z7 ^我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 7 q9 I6 w( m+ y9 P. x7 ~$ ?

& M+ K- u# e& V1 a( A那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
2 y3 S8 s. z: _: m/ `5 q) a这是AGV_putin中arrive的method。1 q6 K1 X; r. w5 f7 Q
$ P+ F! e: e6 f& @' j  j
当到达物料速度越高时,这个报警更多,
2 _# E0 |& \& e! t( q7 o& `) a: K
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-2 15:28 , Processed in 0.018400 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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