设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8100|回复: 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'
; o9 o/ F0 a( |: h+ S*/
+ b6 T5 f; x7 s3 i/ X& g0 Q& ~8 zis
" e" B4 W0 i7 ?5 ]8 ^- O        part, GlobalDistObj, assignLObj:object;row,Lan:integer;$ @/ G+ C1 X( C  Y) [+ J
do) K' M1 v2 ^$ S( |7 S1 ?' R
        Lan := rootfolder.Internal.Tools.AOLlanguage;
+ F- v9 o+ R& h* _, U4 d: n        if current = @.Destination -- else return
' {$ _) B  e* A2 F! W, Q        then
$ y  x) ?1 A9 ~2 f- y# z, f% q                @.Destination := void;0 |2 p( T6 M* J4 K$ ~/ h
                if @.occupied then
' C4 \' u2 N8 ^/ R  Z0 a                        part := @.cont;
0 J3 u5 g& n9 J+ r  f4 m4 k                        @.transpOrder := void;( K/ t8 m$ P4 W; E, g: O8 u% v
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
9 v' o2 d4 r$ T/ S3 {) u0 C6 Z7 f                                @,root.eventcontroller.simTime);
! `# a" n1 q& N2 a# q, j                        @.HasOrder := false;
/ ]! [8 R( D  U9 `$ k                        @.DrivingHome := true;* {+ ~8 a0 j7 l2 s1 O
                        rgManager.tryToStartTransOrder;# X7 E8 t" j: X1 H6 ~- \/ D
                        if @.Destination = void
' J# F2 @6 C$ G9 H                        then -- no transport order for vehicle @
6 ~& O) \9 J1 G. x2 a$ h) y                                @.Destination :=* r+ n7 g% s5 l; E/ b/ u
                                rgManager.nearestFreeStation(@,track.~);
9 @% L/ h9 W; w* C0 P. m9 m                                newDirection(@);   
( b+ K# c& r9 K" {                                if @.Destination /= void then- O0 O/ X3 |% P2 {, _4 s
                                        @.Destination.NumReservation :=
9 R2 o3 S# ^- H+ d7 Z1 e7 b                                        @.Destination.NumReservation + 1;& f/ y6 g0 _" q4 C  t9 I2 i$ ^
                                end;( o) P( J9 d7 ~1 C  ^$ w
                                @.CurrIcon := "drivingHome";
* S' E3 `8 B4 O4 Z( L                                @.DrivingHome := true;7 R  M3 r5 O; u
                        end;5 `7 }0 d3 Q3 w" a; u/ p' x: o
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
5 O, Q1 q3 O8 K4 D% {2 z                        part := @.transpOrder;
  u9 J7 F1 o' ^( ]. i' m                        part.move(@);-- load part
! h0 G0 h! P4 R$ f( O' I# o$ T# l                        @.CurrIcon := "load";9 ]1 Q3 U/ ?" A( h, m
                        GlobalDistObj := part.globDestination;
" R. T! @5 y1 d8 S% ?1 r$ a5 w3 T                        assignLObj := rgmanager.rgAssignL;
- w7 p1 P  X2 @- O                        row := assignLObj.getRowNo(GlobalDistObj);) P" v" Q3 K' B/ F# Q) z$ F
                        if Row = -1 then -- since 70) m4 |# @% K  z
                                if lan=1 then2 q& s/ ~9 H( I. W: e* ~
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),7 I- |3 |' [8 I! |. \- G9 Y1 b
                                                to_str("in der Andockstation: \"",?.~.name,"\""));/ r+ o5 d1 j1 o4 y5 W
                                else
# S. f" h: `8 |6 @1 M% }                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),) C* L8 Z" ]9 V: t: A  |
                                                to_str("in docking station: \"",?.~.name,"\""));                               
: u. Z6 d; ]  C4 `                                end;
. O- `+ H9 r& _$ S2 z2 o& [                        else
3 ~5 U; F0 e' i; x. c+ M                                @.Destination := assignLObj[1,row];
- f- [0 G% W3 \% |" z" C  b) F  l* h                        end;                       
! S7 S; ^& b( S) c: ?                        newDirection(@);3 O( D3 V3 c$ e8 G5 g$ N
                        @.HasOrder := true;
8 E% ^# [+ \) Q2 p! |8 M                end;
3 n6 S! ?1 p* Z        end;3 Y% o5 j' }" N2 E7 O% O: M1 B
end;        -- of the method( \5 {9 f5 J( _7 Z1 |
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
7 ^5 A6 ~3 G  |8 K: {" L* R; M& v6 {6 W2 N
这是AGV_putin中arrive的method。$ h$ W; J$ ?- s; k# U# W1 _

0 m: B2 x! A: K4 B0 j5 N当到达物料速度越高时,这个报警更多,& o4 y( O# B+ V1 X( D. r& W
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。: Z% N% S7 W8 E0 f# A+ D
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
# Y1 G: f$ v% ^1 |+ Y) u: f5 R
% s! W. A9 W; W/ ]% B! z另外一个小建议,就是move,所有的move都可以这样- C* n3 m+ u' q& I1 W% ?+ q
if not move() then debug end
9 L1 J5 E' r/ I% M0 H; Q4 w) S2 F这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。  l: j% B' \5 S4 `& G
plant simulation中的free libraries有AGV模板,
' U4 B3 H. D0 s: C/ @里面也有案例。
* U( ^4 O; n! X2 P我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
$ Q* y8 Y, b# u/ S2 F) Z6 r
. k. T6 Q% @! x' ^6 j7 C" ?我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑   K( w$ W) x! {: }  M, c# J
) @& ~" N" d5 [
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
: M9 B4 [  J3 t3 ^0 `5 H0 [& w& a这是AGV_putin中arrive的method。8 w% K! @6 m  n

8 Z8 h# p+ u1 G# `. m) c当到达物料速度越高时,这个报警更多,
5 h5 h3 O  w! q. T0 n' s
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-14 17:12 , Processed in 0.020266 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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