设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8511|回复: 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'* J9 ^+ M% c4 G( R
*/
) M* T8 N1 n' h1 ^- ~( @, eis
% u( l1 h' j% o1 e$ o        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
: E: i  A% H0 f. l  [: N8 hdo+ P; Q  Z) {# s* {/ ^; Q- P
        Lan := rootfolder.Internal.Tools.AOLlanguage;
1 n9 U* V0 ~& B& ?4 z" k2 U        if current = @.Destination -- else return3 n6 v( g- D0 ]; D
        then
! Y/ `! n& G3 ]/ F' @- N1 x) D3 N                @.Destination := void;. i* Y' v2 L/ B: X7 X
                if @.occupied then. N" F" M# ]2 G
                        part := @.cont;4 z9 N# K+ ]! M) @
                        @.transpOrder := void;
# J1 o4 G  o; j# Q0 k                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
3 j; e0 A# P, A, H                                @,root.eventcontroller.simTime);. M) h* j/ K3 ?9 m5 V
                        @.HasOrder := false;7 W# [% p7 B7 c$ j6 }" ?* t" d
                        @.DrivingHome := true;# r' `7 ^' j, J! p3 S/ R4 I
                        rgManager.tryToStartTransOrder;: _/ q4 f" @; }" H9 ^
                        if @.Destination = void0 @* T  o# b* I; E+ t: e
                        then -- no transport order for vehicle @& A! c/ ]( N# P6 q2 v! w
                                @.Destination :=
& L6 n; u  o; V" O                                rgManager.nearestFreeStation(@,track.~);
0 v% P+ \5 R' q6 B7 Q2 ^) J                                newDirection(@);   
' l2 g% o  k0 m5 S8 @                                if @.Destination /= void then$ Z+ O6 F& ?% n, L
                                        @.Destination.NumReservation :=
) d3 V  s" N1 F) x4 {1 a. {. [                                        @.Destination.NumReservation + 1;$ h4 w4 d/ u  X3 U4 T, M+ v
                                end;( T# Y% B# V) ^
                                @.CurrIcon := "drivingHome";
: r% J- G4 `* u2 J' J                                @.DrivingHome := true;* K- c$ F. T" i
                        end;3 W! z0 f' h3 }* R
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station0 t; b+ G  m- X; }# ?! o
                        part := @.transpOrder;
7 P- p3 V& I2 X, @  i; G                        part.move(@);-- load part/ ]) n% [- [& L$ U9 h) N
                        @.CurrIcon := "load";
  S( S! q# A1 {, N& ^                        GlobalDistObj := part.globDestination;
) X; z: O  c% L6 Q                        assignLObj := rgmanager.rgAssignL;% E7 s5 }' K; I: k
                        row := assignLObj.getRowNo(GlobalDistObj);9 Q" [+ U0 C5 ^4 [5 N4 y: A
                        if Row = -1 then -- since 702 i: b9 E* {2 `3 n( b; u
                                if lan=1 then- O1 S( H" F- r" X5 b- o! B
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
( ~. y% @1 l4 r; s                                                to_str("in der Andockstation: \"",?.~.name,"\""));( H9 v( V, n' J3 _: F) @& Q( n! C
                                else
. I- \  s* B' O                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
% s" q/ e2 \$ W, t% {                                                to_str("in docking station: \"",?.~.name,"\""));                               
+ H1 a9 K6 R6 k  s: [0 x* S                                end;, g8 ]' A2 f6 z) [, `/ u6 M
                        else
: }9 O# B. L; j                                @.Destination := assignLObj[1,row];* e3 \! g. X6 Y" H' V
                        end;                        & G# {9 U$ i7 H: S
                        newDirection(@);+ B' ^7 _) l. ]. [' {& P) J( f
                        @.HasOrder := true;
' _) O2 b7 S" v) k$ {                end;" @) n9 T- d6 n1 K3 ^% m' ^7 G/ @* L
        end;
- Y4 N4 S& J" Y# wend;        -- of the method
  I8 E5 A5 k( q) y3 L$ {# B4 Q
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 9 K: V5 q4 Q. u- X8 u
1 U- k6 z6 v7 ^6 T+ v9 K
这是AGV_putin中arrive的method。
5 G, x- |- R1 f& _% J" a4 [# k+ o* V4 c
当到达物料速度越高时,这个报警更多,4 J4 u& j7 L  |+ @5 u( z, O) N3 w0 |
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
% o; c  t% N3 G) \程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?  Q+ X$ w$ _8 e1 ?  d. U

) O+ P: I# I4 x6 T$ b; J- S# T/ p! m- ]另外一个小建议,就是move,所有的move都可以这样
* y# y" c# h$ z% s+ rif not move() then debug end
6 n6 a% E' T7 S/ K1 V这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。) d9 ]8 P1 y( f/ A
plant simulation中的free libraries有AGV模板,
  s  X* j( w$ ?  t8 N1 H里面也有案例。
" ?4 l/ t8 ?+ q0 L* [我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
- y! D  n' `" M1 m  ]5 ]5 }5 Z- b: V7 b( h
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
& A" D6 M; g3 U, |7 E
+ I1 \- C% K) A9 m' V那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 : }5 ~  x# d/ _6 H9 X$ f
这是AGV_putin中arrive的method。
' B2 e/ C  ^2 v- |
' h8 ]' Y1 p# j) V当到达物料速度越高时,这个报警更多,
9 t, D9 K- J/ O& ]
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-8 14:02 , Processed in 0.021959 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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