设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8736|回复: 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'
. _# x6 R# ~1 N0 t4 q, w% u*/
& l& c; c- ^4 w6 L$ q# b6 R) ?2 Q8 ~is( K3 t  n& I& I8 d- {' q" \4 c
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;$ b. H  \2 Y5 v2 y) [( C2 n
do
: ~% y$ D% r  v4 m0 F. W        Lan := rootfolder.Internal.Tools.AOLlanguage;
0 [, C* l7 I% W8 ~) Z' W        if current = @.Destination -- else return+ e( ]( B" G3 E- \
        then
8 l# M7 ~' [. I6 @8 q" J4 g                @.Destination := void;# W( o% u$ O" O9 z
                if @.occupied then. [' ^3 K- I  p+ N
                        part := @.cont;
2 l4 c9 }! {5 D0 U: {3 T                        @.transpOrder := void;
0 Z5 L# R1 y; o+ M% H                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
. U0 v4 R6 t: Q) g3 Y$ C+ f                                @,root.eventcontroller.simTime);  u" K) [8 \* O3 M4 D# m$ ~5 G# p. P
                        @.HasOrder := false;& z/ x# D& K5 e% J5 J- w
                        @.DrivingHome := true;
  ^7 Q: p  K5 K- r3 l+ V                        rgManager.tryToStartTransOrder;
; |7 c7 i. S% w5 d3 P                        if @.Destination = void# @7 L( E. u: a2 ^& R
                        then -- no transport order for vehicle @! f' y8 T8 e& H$ z- q; Y/ o
                                @.Destination :=
0 a. h2 V. J' e' G: e                                rgManager.nearestFreeStation(@,track.~);0 w% i* P5 N( l2 `2 n- m9 V
                                newDirection(@);   
" S* P: H1 D* x( c# a2 H                                if @.Destination /= void then
3 q. F6 t, F3 C8 m                                        @.Destination.NumReservation :=+ _" @. a# {: n
                                        @.Destination.NumReservation + 1;2 q* r  x; F+ W4 L3 c
                                end;
' x2 V; K$ y8 T: m7 M& y                                @.CurrIcon := "drivingHome";
0 i7 S* t9 ~/ O  s% p2 h6 n                                @.DrivingHome := true;
1 K8 x8 d* J: p5 w& l7 A                        end;- G$ h( Q0 a. ]1 j  m" F- ~, ?, U
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
9 O( n( Q6 I% U* }                        part := @.transpOrder;0 P. S# t+ d9 j: ?6 x
                        part.move(@);-- load part" F4 ~% T  q# F) M. q" U
                        @.CurrIcon := "load";$ r3 D8 Y9 f% m' m1 z- H8 K
                        GlobalDistObj := part.globDestination;
, E) y- }0 Q' Y1 t% e                        assignLObj := rgmanager.rgAssignL;
) `7 q; @7 A! ~" m% ?                        row := assignLObj.getRowNo(GlobalDistObj);% J+ Z2 Z* h4 m! N; M' f5 J% W* y
                        if Row = -1 then -- since 70
; p4 a* c( @; P$ A  X; [9 g5 m1 j6 r                                if lan=1 then
' S' ]7 I2 |1 |, R  C# l2 k                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
6 U. D( M8 _" ?* |8 w+ A$ e                                                to_str("in der Andockstation: \"",?.~.name,"\""));: V( c4 Z8 M# u: k& X
                                else
. e0 ?, R! D& K- k" A                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),9 m  }1 x* o- q6 o
                                                to_str("in docking station: \"",?.~.name,"\""));                                " ~" Y6 F: E( ~0 }8 C- H
                                end;. W$ G8 `$ B( T5 ^6 n
                        else
! W1 o! g& P( @                                @.Destination := assignLObj[1,row];7 p8 ]) z1 v: {0 J
                        end;                       
# a$ Q4 _( J5 o+ ~, d* a! l. A3 E                        newDirection(@);- _5 A, o( G1 T) S8 T' ]5 o3 y3 }
                        @.HasOrder := true;, N1 W  e' N' \; w2 K) G5 J" g8 C
                end;6 a- l: x, ~, y
        end;' L+ B. f+ v+ ]$ R  b' T' P
end;        -- of the method
7 r/ V2 _* E% V' W
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
9 o+ E% A( A4 |  a! f" H
) f" P$ Y" W3 v: w这是AGV_putin中arrive的method。
2 Y7 l; q, B; C( }& i9 L+ H+ h/ ~; K2 Y7 j% ~
当到达物料速度越高时,这个报警更多,7 v4 K. f7 R# z4 D7 C
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。7 ~; Z  R; s1 F( |% Q
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?7 `$ q5 n8 K% y) u2 p
# o9 n' O% A  C3 x& z9 v& M
另外一个小建议,就是move,所有的move都可以这样
9 Y" _! s1 Z, Mif not move() then debug end( p5 [$ H& Z9 x
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。& L' z& u* n/ O7 D
plant simulation中的free libraries有AGV模板,8 w8 ]( o: M2 y, L
里面也有案例。) `  O, l* |9 s3 S" E. X* v
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
% i3 s) x- u# F# H( W
. c6 {. f/ y0 y/ @% ]( G7 e我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 # X2 f( H; S( r
- A$ ]; }1 @7 W9 A/ X0 b
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 & J2 |" o- I* }- O/ C
这是AGV_putin中arrive的method。
; F0 n4 |2 \! S6 Y# x. T5 @# A8 x, g/ m% g5 S
当到达物料速度越高时,这个报警更多,

$ z, E( E3 s- a) J- b另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-23 09:59 , Processed in 0.016629 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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