设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7184|回复: 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  H7 ]+ g4 O+ ~) ~8 }
*/
+ m  C% }1 V% W6 l( I! i2 Uis
) b6 ?) D" T2 Y! X! o# o: @+ ]7 _        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
& D6 G4 H* v3 e1 G- c, ydo
9 x% G) u8 w/ ?% i* k        Lan := rootfolder.Internal.Tools.AOLlanguage;
8 `9 h1 A" ?  `6 {& {" ?! Y1 l        if current = @.Destination -- else return: L. o: R; l) r6 N- m
        then
8 R$ r4 h$ ]: J# L5 ]: @& O) |. x                @.Destination := void;
& t; l, ~7 \" v" e$ O' c                if @.occupied then
% }& N6 w: E' l( t7 B/ K* Z" l; ]                        part := @.cont;1 l& S# ?9 G0 ~5 ]
                        @.transpOrder := void;
( p" e0 }$ `1 D3 u                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,7 R1 D( D4 ?$ C5 ^6 t6 k, s5 s
                                @,root.eventcontroller.simTime);
+ O/ }6 Y+ p' A# t8 A* D* S0 r8 H                        @.HasOrder := false;" F1 a1 h$ @. G$ J" x9 c
                        @.DrivingHome := true;
- o3 o  P. E+ r1 l                        rgManager.tryToStartTransOrder;
+ ^) m1 K/ I: z- F                        if @.Destination = void
  U2 b8 x" w3 g/ p. c                        then -- no transport order for vehicle @
3 m/ ?; G# p5 E( R/ S" X                                @.Destination :=
: O# E7 y* _/ z3 L                                rgManager.nearestFreeStation(@,track.~);
! ^' Y' f+ r. W( o4 r9 R                                newDirection(@);   
' [, ~4 e2 Z6 S9 C5 ~5 H* U4 J6 d; U                                if @.Destination /= void then
8 C% n# x& K- R$ T% @0 f; V8 ~: b                                        @.Destination.NumReservation :=  @' a0 P: z- |1 V/ p
                                        @.Destination.NumReservation + 1;8 f& M$ J0 e4 W, R3 N
                                end;) m( i9 W- Y. d8 E
                                @.CurrIcon := "drivingHome";5 g9 r' F5 L5 c; a
                                @.DrivingHome := true;/ x' ~# h( U& ?) I
                        end;
2 l  Z  B5 t7 f. y! z( ]* F" j                else -- the vehicle @ is empty, both vehicle and part are in the same dock station$ u5 E, e( P/ ~/ ~/ {' k
                        part := @.transpOrder;0 \- A# b0 L# M
                        part.move(@);-- load part
+ J5 D8 h1 Z) o# Q; x6 o                        @.CurrIcon := "load";
1 \( Y4 n! v8 a# Z4 t$ p                        GlobalDistObj := part.globDestination;
' x! g, ~0 x2 x                        assignLObj := rgmanager.rgAssignL;
8 o3 k: |1 D6 U' C% ~: {! H                        row := assignLObj.getRowNo(GlobalDistObj);
5 l4 [  C- s# v                        if Row = -1 then -- since 70; W& f! J; r7 Q# p7 j
                                if lan=1 then' u1 s4 `2 y; ^
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
# m) D* P) O3 N, g. s3 q4 y                                                to_str("in der Andockstation: \"",?.~.name,"\""));& O. Y% G5 p+ K9 |& E/ \9 y9 [; y
                                else, H0 L! O& o& S  u, P( n
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),8 Y, {3 s. n4 M3 |" [
                                                to_str("in docking station: \"",?.~.name,"\""));                                ! y' y3 K& D9 t
                                end;
  `0 h; v. l- ?; Q4 ^- N8 h                        else
& h. o. b: s2 p; }1 F! l                                @.Destination := assignLObj[1,row];
  n& G' `% D0 }! A4 E- t                        end;                        8 n5 Y3 m3 T) E* \
                        newDirection(@);
- P0 u7 u% {9 K1 L- ?" ^                        @.HasOrder := true;
, g: Z) L; ^$ @6 W                end;
4 u* V/ e( k- Q9 o' Y        end;
. ?$ `: h1 A3 f# U! \0 [0 mend;        -- of the method9 ~1 b, R, z9 R% P. J
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
% X0 {3 Y$ y+ \0 B$ a+ x* d5 q7 g4 h, V2 [
这是AGV_putin中arrive的method。- P! Q; h5 w' F4 G' c, \
4 l# M3 r8 o+ O% W
当到达物料速度越高时,这个报警更多,
2 A1 h+ [8 S7 Q5 F+ @7 @* w可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
& T2 Z# N, J/ h& [5 P$ E程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?6 X6 H; n& M: }9 q3 A

2 a" q* f# r, q% o9 M+ w另外一个小建议,就是move,所有的move都可以这样, f: }9 g2 O* ~7 t9 z8 ]
if not move() then debug end
% f$ T2 x& r" [, ?这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。  C) `: k, ?1 y. s# P) Y. S# ?- t
plant simulation中的free libraries有AGV模板,4 d$ f, B) n  j
里面也有案例。& O7 I+ N" x! R" u% g$ o
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。( l! o& _% E# a; C" L6 e- ^
2 B" U% n# w( u9 d
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 5 T2 N6 ^- e# c" m
( x( _& l; K% B
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 * s, r! ^! F/ }, ~7 V
这是AGV_putin中arrive的method。& N) n5 t9 N) z0 N/ p. J6 t1 V
, {' R( ]9 P6 x/ d2 d; v) d1 o
当到达物料速度越高时,这个报警更多,

  @: p0 M, L) X$ L. ]6 Q. ?+ {$ x另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-25 12:35 , Processed in 0.024588 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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