设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9503|回复: 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'
. Y: `9 o* V0 y1 d*/
7 k; A; P4 ^4 Uis
- R& f  k4 B9 R7 y1 h' V- \/ _+ g* I1 G        part, GlobalDistObj, assignLObj:object;row,Lan:integer;) b) y/ N, R5 M: A) {- S% b0 K
do1 w: x) e* n0 F0 E) Z
        Lan := rootfolder.Internal.Tools.AOLlanguage;
" S% z; d7 s/ W% \- ?% K        if current = @.Destination -- else return% f6 V8 }% K* ]7 u: T3 \
        then+ b8 z2 l% ~) ~' s
                @.Destination := void;) s% b( m9 X  B; m: G3 O
                if @.occupied then
% r% s6 w3 |% s5 E4 f8 ~4 g1 P" E                        part := @.cont;( m& h: b  k! b8 r% J
                        @.transpOrder := void;
6 q8 ?. n. u# b1 {, }( @( t                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
  B4 q, Z' g' P6 V1 _                                @,root.eventcontroller.simTime);
1 F& i7 l' [7 L9 L: H                        @.HasOrder := false;; _" X( h4 \+ p+ I2 T% j
                        @.DrivingHome := true;
* D! W% \4 ^6 m                        rgManager.tryToStartTransOrder;6 X% V0 m; l/ Q! S1 s* R, G
                        if @.Destination = void+ t4 w% P1 @; u/ w
                        then -- no transport order for vehicle @
/ Z" z  b& L1 O* m' @) u- N                                @.Destination :=
8 Y7 ^( d% p. t. Q2 R! Y                                rgManager.nearestFreeStation(@,track.~);
4 Z6 F/ ~+ |9 g/ N! e; A: v                                newDirection(@);   
4 G7 ]6 N- h0 a                                if @.Destination /= void then1 ~" v, e1 V9 V5 e: G3 d
                                        @.Destination.NumReservation :=! L/ H, P  Z5 C# m  ~
                                        @.Destination.NumReservation + 1;
  F! l' z& ^9 |0 C: u3 G( q                                end;& y( ~/ d) O9 F9 w
                                @.CurrIcon := "drivingHome";
8 V6 V7 K3 g, D! c                                @.DrivingHome := true;
; \8 X! G4 n  _$ N: s! K                        end;- q& f* A3 o) k* j9 c
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
7 N1 o* m. l6 q, o/ G/ k                        part := @.transpOrder;
$ z  [% F0 F5 u3 }0 l                        part.move(@);-- load part
& ^; p5 E: B9 l" I                        @.CurrIcon := "load";
- P& {. n9 f9 Q1 |. m. u2 f                        GlobalDistObj := part.globDestination;
2 Q+ V8 N8 s6 _; @' g7 Z3 c                        assignLObj := rgmanager.rgAssignL;
8 W8 e6 b1 Y/ T, A                        row := assignLObj.getRowNo(GlobalDistObj);0 f! m) L, U) E6 u" \
                        if Row = -1 then -- since 70  Z1 u: y3 |  d8 n  c( u" i
                                if lan=1 then
- a; e* y; E8 v! ?7 C/ \                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),: M/ d2 K% l/ J0 Q& [
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
$ [$ @. w$ B: ?                                else
6 j" l% \7 q) r; D$ L) v                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),4 T8 N2 e- O5 l1 [
                                                to_str("in docking station: \"",?.~.name,"\""));                                7 P9 a5 j7 U' m  |8 _" y
                                end;
; \! D- h, @) C  b' p. M+ c                        else
+ ?& W7 H: ?* Z" o* e                                @.Destination := assignLObj[1,row];
! A: l6 |; W7 d: G  p- a4 H                        end;                        1 A) C2 q/ x/ e2 S! G' V5 b5 c
                        newDirection(@);. q1 L7 T1 M* K) W7 g# m6 }
                        @.HasOrder := true;
% _% N$ Z4 Q" g# `4 |                end;! q+ y2 R8 p% o5 f) j! w4 D
        end;" ?/ Y9 C: P( f5 q  t1 \; I4 p
end;        -- of the method
" a! }  T6 ?$ B+ N% K" @: F% E$ i4 M
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 0 g+ c( f+ t0 ]- E) L! @- Z' J. E4 R
8 _; S# t* K$ m- W' ^
这是AGV_putin中arrive的method。
2 _$ h2 r9 ]( b4 L# T+ \4 j
% b+ `3 ]" Z0 \7 K* `当到达物料速度越高时,这个报警更多,7 X" }( |  P5 [$ ]
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
5 ~  t1 @; e8 X0 b" ~程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
; p8 y) e- Z$ T8 U& ~% C& W* B! p6 |, K' m  b
另外一个小建议,就是move,所有的move都可以这样# I& A9 l/ B' h1 V+ y# A+ j5 |& _
if not move() then debug end
$ f  d$ ]: i' K) B# v! B8 Q; `这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
8 P, c" @  {, ]( e( _- ~plant simulation中的free libraries有AGV模板,
- J- W( d& V0 {, C5 O0 K. M5 [3 F里面也有案例。+ f. O7 N8 r1 k' f
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
. \- L/ D& [6 w9 d( f3 \  L" J' Y) r+ p. B
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
/ L6 Q) L% X. B* N! x, B
& n& {! \: X( V! o+ B$ H# _. D那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
) m, n& E  ]' x# p8 u0 z* z这是AGV_putin中arrive的method。
2 }0 c, N  l" k3 D
! e3 P" ]9 t% d当到达物料速度越高时,这个报警更多,
7 I) w; q1 R7 u. z  l6 A8 c
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-4 20:24 , Processed in 0.018647 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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