设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10143|回复: 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'
! E/ }. K$ p% O- A% c* i9 f*/
0 J/ b/ |7 P+ k3 M. mis2 m) e- u. t6 X2 W( \# z" }* K
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;2 X7 ~/ j: @2 Q
do' r7 Y1 K5 M0 k* o
        Lan := rootfolder.Internal.Tools.AOLlanguage;) f$ f. X$ m0 T1 V: ~
        if current = @.Destination -- else return  V; Y7 T7 u: g' i0 l
        then
# N: f( E. e0 q! x6 e& G                @.Destination := void;
+ q0 ~, q& P5 Y( {                if @.occupied then/ C6 q3 W1 @& b$ E
                        part := @.cont;& v6 B. V9 W" F  B5 |$ w- p( q  Y
                        @.transpOrder := void;
1 P3 Q' l' u, h2 o9 @! L% S! |4 U                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
# V' s4 x' a/ E                                @,root.eventcontroller.simTime);
" |* I' x' _% F, A                        @.HasOrder := false;
7 O2 t  Z% N% I/ \2 {( E9 }/ V) k                        @.DrivingHome := true;, S# z$ j7 |3 m
                        rgManager.tryToStartTransOrder;; i8 E$ J# B. P9 o5 e6 g5 M
                        if @.Destination = void" c+ }1 W! t1 ?7 ~7 b4 n4 y
                        then -- no transport order for vehicle @
" z% D8 u9 V6 k1 b! w% N" t) ~                                @.Destination :=
3 B) d' T! p' b1 \                                rgManager.nearestFreeStation(@,track.~);$ I( j4 I) @  R/ f& {
                                newDirection(@);   
6 n+ {+ r1 x! e" B* I                                if @.Destination /= void then8 P8 d2 n/ s0 E5 H) e/ I7 c4 \) g
                                        @.Destination.NumReservation :=9 y6 L1 U$ r9 G2 F) Y
                                        @.Destination.NumReservation + 1;% r: B( U; q2 x( K
                                end;7 A. t" L7 ]' q" m9 g
                                @.CurrIcon := "drivingHome";4 a! F& v7 m, V( D5 T
                                @.DrivingHome := true;
: J; M4 q$ I2 s) {) S; @                        end;
3 q. m+ b& C6 q1 c% f2 w                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
. t2 ~( W! Z& f: N. X+ ^; N                        part := @.transpOrder;
) ^; j* g& K% \6 {8 L6 T                        part.move(@);-- load part$ P) }! `' `5 i
                        @.CurrIcon := "load";
6 L/ p: F9 [+ @! i/ p                        GlobalDistObj := part.globDestination;5 q9 b9 ]  U3 ?, y) W) Q7 \
                        assignLObj := rgmanager.rgAssignL;: ]. B  Y) n. V7 w5 z
                        row := assignLObj.getRowNo(GlobalDistObj);
8 p5 @6 U* k  l' a# z                        if Row = -1 then -- since 70
% d$ c& r$ w( J( R                                if lan=1 then6 k' D8 @8 ~* w" T" T: N
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),- [* V# u1 Y( t3 B" P: b
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
0 C! M/ ]% }2 i; h4 t                                else
8 X; x9 M4 n6 H) E& Q" {                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),8 n. }* B$ Z( t* s" R; i' e4 v
                                                to_str("in docking station: \"",?.~.name,"\""));                                  i1 b& K6 y) r& s" a% Z. |! o+ K
                                end;; X  `% a" R% g3 R
                        else6 Q8 ?# \- f9 I6 h
                                @.Destination := assignLObj[1,row];
* h* I1 g. r+ G                        end;                        : X! i- d! C: t6 o" Z+ H  w
                        newDirection(@);
: z1 j( h  F4 G- d+ ^                        @.HasOrder := true;7 W2 K* d$ J3 c4 S4 h, U
                end;
& q* T( f4 j3 @$ L  K6 K        end;& B, V8 i$ d7 |% a
end;        -- of the method5 A* y5 E/ F  T' v( m& [
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
" N8 ~2 g5 s, |
0 `1 t, ]' ^/ `5 E# `- @4 R  K这是AGV_putin中arrive的method。
' m7 s8 h9 B, S: Y- B$ g# }
) x0 `6 m( e7 W: D6 K4 M当到达物料速度越高时,这个报警更多,
; ?9 y1 x. c' |可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
" k: X8 }' I" a+ |5 d程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?/ j8 l+ ]3 b: x+ @1 L$ ]- k/ L

2 K  T- z- t2 d/ `9 x8 H# [4 h另外一个小建议,就是move,所有的move都可以这样
' u# x3 m. N4 K' h$ |if not move() then debug end
1 Y: H. z( @6 N& c+ I; Z. y- @) W- m这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
) \" A7 }8 y, ]; A$ c6 B9 {plant simulation中的free libraries有AGV模板,
# z  m: n  p1 N3 r" f里面也有案例。' l7 N# b) V1 K: ?) s  u: F0 H
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
" g# R" h* C- b! X
3 ?5 R1 V4 t3 _; c+ U+ J/ R. d) {我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 1 Y: Z& m3 ~% b" k0 {" a* S

% w) V0 f2 Q( v( j4 W/ \那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 . I% ], j" x# w0 B
这是AGV_putin中arrive的method。
7 x6 H9 D" J% B1 E) ?
# P, p% h% B7 a: _: q% M* w0 Y4 s+ ]: v当到达物料速度越高时,这个报警更多,
( t7 G: B# M$ p! J
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-15 23:17 , Processed in 0.019009 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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