设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8365|回复: 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'
! `  K" |: j; C*/
& J! K, R; j+ U, o) Jis
: \. F( r* y3 O! T4 n6 I$ o( @# {        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
3 c+ z/ l7 ?$ S' q4 _' ^* y8 \do
/ ]8 o. K, J) r1 W+ n3 ^* k+ k        Lan := rootfolder.Internal.Tools.AOLlanguage;
0 ~4 R& h/ z# Y. {  M        if current = @.Destination -- else return0 ~$ K5 l. e, @  w5 y+ U6 ^
        then
4 S% {; J/ r; W4 _                @.Destination := void;" z4 a+ J; K- |2 p2 E5 q. |
                if @.occupied then
/ n' h% T5 ]  v/ |* R                        part := @.cont;
6 _9 L" ]2 x' M0 r6 o                        @.transpOrder := void;. Z* n! E" y# `8 b  O+ v
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
( a- A% s4 x; `0 o3 m( n                                @,root.eventcontroller.simTime);
2 t1 }$ B7 F" s0 a$ v/ d5 d                        @.HasOrder := false;9 H) T5 R, P4 ^2 {& {
                        @.DrivingHome := true;
: P0 Y3 D' D" C" V. _                        rgManager.tryToStartTransOrder;9 [0 G' W% E% ]( V9 _& [7 V3 [
                        if @.Destination = void
5 X- R! _' r5 R& f                        then -- no transport order for vehicle @4 V$ @3 V0 S% o' j7 v4 s' s
                                @.Destination :=0 s1 X3 K! _: q* v; a( N8 r
                                rgManager.nearestFreeStation(@,track.~);7 [2 f3 j6 y! D6 z6 g0 ^8 x1 ~
                                newDirection(@);   1 {/ O9 _9 ^* T: c3 r
                                if @.Destination /= void then& _( n3 s4 I7 u
                                        @.Destination.NumReservation :=
/ a! P$ N- u8 t                                        @.Destination.NumReservation + 1;# `, R  Q: ]# A2 S' d  Q
                                end;4 r9 f6 a1 @( V" f% k! C
                                @.CurrIcon := "drivingHome";
# E# K+ h; t( {( \3 W! r; h                                @.DrivingHome := true;
. M* S0 K# |% }' o- f6 E# l8 f                        end;
1 b' ~6 l' p& R5 X                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
. b4 T  H7 Y8 D: X6 E                        part := @.transpOrder;
; {7 {% C% f# g& p                        part.move(@);-- load part% K* h. x1 a- k1 ~/ ~3 q% |  f
                        @.CurrIcon := "load";
! e& R6 c( b3 T  P( C1 q# ^' K                        GlobalDistObj := part.globDestination;; ~. h! i- D( c
                        assignLObj := rgmanager.rgAssignL;
: {" K6 J9 x4 [$ \                        row := assignLObj.getRowNo(GlobalDistObj);
5 {/ W9 f2 n/ Q+ A$ w' p* H4 n                        if Row = -1 then -- since 706 ]$ M/ E: w2 L" u
                                if lan=1 then
; e( V0 G# y! {) Z7 H0 z) W                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),- b, Q6 `! X: N8 C- l4 X
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
" n5 [' g, C/ X' K* O9 D  N5 L                                else- W% g9 ?: B0 j- H# j
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),) N  F# L1 s# l/ t+ `, X, k6 f
                                                to_str("in docking station: \"",?.~.name,"\""));                               
8 B4 Y% w9 K. a" `+ O                                end;
# ^. O% p( T4 j$ [- O% A, P6 |' N                        else
, z- s' p( g# n: e! C4 g5 p                                @.Destination := assignLObj[1,row];
1 d4 F' y+ p" @$ L                        end;                        + F, q/ R6 Y: w
                        newDirection(@);( Q3 d* u8 z7 o* i) H
                        @.HasOrder := true;0 c* n6 U6 w4 v
                end;8 B& ]  W1 Q  m; Z7 X4 `
        end;# O# i8 o0 l% S" [5 q
end;        -- of the method* r' ~" N* P% d/ ~
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
% }" i  ~' w0 A+ I: D- U& ^* H5 S: {: r$ r9 K( V4 w6 J- W2 ]
这是AGV_putin中arrive的method。2 g& E9 p# r" `) `

6 C: J$ i9 I6 a' }- U& `! p当到达物料速度越高时,这个报警更多,
7 G: l0 G9 Y. S可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
) I- h( Z3 e# K# B8 x# `- h2 Z6 }程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?$ J4 d' \) E/ O' K

6 ^/ K6 N- Q  V1 r另外一个小建议,就是move,所有的move都可以这样* N  B2 p7 X( s
if not move() then debug end
8 R% S* f. {, R这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。+ `, V2 k) U1 j: s
plant simulation中的free libraries有AGV模板,
: q( t* I. g/ L, i里面也有案例。0 c  u0 H7 L- D/ N! Y
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
. f7 M1 |  U1 X$ p. r  S# e- ], ?, Y. h1 A5 h% y. P& f) S
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
4 ^' b1 r4 J; f; |: s! _7 Q0 m. ^* z1 ~9 O5 {1 o9 o% Y9 b
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 4 x0 P3 i/ e# Q5 r8 D
这是AGV_putin中arrive的method。
" p; d0 N! P; K" }+ I; }  a  o
  \6 s9 w% ?; {- s3 O" }当到达物料速度越高时,这个报警更多,
( ]3 a& G2 [* v$ j" x7 [
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-30 18:34 , Processed in 0.016862 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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