设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8805|回复: 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'
6 P; e; c  W  w" `  M. ]7 k*// g# M3 P9 f" A" ^
is
2 v2 ~, I8 r* M" a$ I: A        part, GlobalDistObj, assignLObj:object;row,Lan:integer;; c( n1 t9 s9 _  g, H
do* D0 E% f4 d. Z3 H9 ?, g$ W
        Lan := rootfolder.Internal.Tools.AOLlanguage;$ i2 x' [3 S" X( ^; S! N. S/ f( o
        if current = @.Destination -- else return
; V% [$ O" D" Z) b        then! o# E8 m* H5 ]* p4 p% g
                @.Destination := void;
1 Z7 G3 y% G# A7 T+ l& H                if @.occupied then
+ s" H9 k) O0 Z( ~                        part := @.cont;" v% e" C3 M" ^& a
                        @.transpOrder := void;- U5 `5 K( k' \& N7 F
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
- l; O6 ]0 E( S9 A5 U                                @,root.eventcontroller.simTime);
' |! R. U! b" J% U; ^9 h: }                        @.HasOrder := false;
( P- L" i2 {) @1 `                        @.DrivingHome := true;
; S3 E5 B$ @0 N9 Q4 [                        rgManager.tryToStartTransOrder;% {9 [$ T4 Y. ~
                        if @.Destination = void
% l2 H) r& h2 @) I* n. o8 }                        then -- no transport order for vehicle @6 g0 s, l% m8 }7 p. V$ {
                                @.Destination :=
. y  ?- t8 q" B  Y                                rgManager.nearestFreeStation(@,track.~);
+ J) w3 j/ v) x! P: W0 d                                newDirection(@);   3 `, f  _% k7 X$ g! t+ T
                                if @.Destination /= void then' p4 a. c7 D1 A/ P' W
                                        @.Destination.NumReservation :=, Y+ Z( f2 l  A" n" s
                                        @.Destination.NumReservation + 1;
% Q3 B  ~9 l+ Q1 }" v                                end;
1 W/ p7 T0 }/ J- ]4 K- Z                                @.CurrIcon := "drivingHome";  J. Z, U& A& @, L& m5 v2 G0 n( o
                                @.DrivingHome := true;
- a+ r! X! e; `                        end;
9 ^6 [  |# j% K/ j                else -- the vehicle @ is empty, both vehicle and part are in the same dock station: J6 Y7 B+ W7 w6 l2 }! b, u: K# b
                        part := @.transpOrder;3 V/ ~! X! [/ N& @' ~5 X
                        part.move(@);-- load part
9 v+ x& _" D& v7 r9 N: o( `2 L- ?                        @.CurrIcon := "load";
% s7 R  t3 i; g" u" K' I4 C                        GlobalDistObj := part.globDestination;3 E1 J; j% ^& k! ~! W) J
                        assignLObj := rgmanager.rgAssignL;- C0 |# L$ T# N$ V  A
                        row := assignLObj.getRowNo(GlobalDistObj);
& v, ^( Q$ f2 n- @7 m: N                        if Row = -1 then -- since 706 S- r. k9 V! i
                                if lan=1 then
9 p/ y! h2 T6 w2 s                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),' T1 I$ P8 ~1 M4 n3 X& {
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
4 L6 e7 ?0 e" p                                else, o: C2 Y! ]" T/ d3 M
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\"")," T7 _3 Z  T# {5 T7 @3 Q6 s
                                                to_str("in docking station: \"",?.~.name,"\""));                               
- A4 P% `) v8 p% \$ Z1 x                                end;% W  z( F: m' k* y
                        else
3 ]8 U0 _3 N8 ^: o                                @.Destination := assignLObj[1,row];
, e# i- ~' a% A7 G; d                        end;                        , f+ X# ?& B5 U6 z$ C& x: W
                        newDirection(@);5 i8 q  ?: \" B9 c# U# }
                        @.HasOrder := true;
2 Q5 D( Q& _/ u6 a2 W$ J                end;" L' ^. g! s( C' v
        end;
+ G+ A0 `# Q) H6 C) ^end;        -- of the method
3 ~; h% V+ O$ @3 H4 N% e
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
8 x+ o% ^' D; M& w# [, g1 E
  n/ Y" a/ T% V3 _2 O+ ]* H1 }" `, U这是AGV_putin中arrive的method。
# E: K% k8 R7 F1 r, r$ r& V) B& }; H  f/ s
当到达物料速度越高时,这个报警更多,
4 O  n$ S. g7 u( ~7 B6 ~1 B5 Z* J可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
; M$ {+ L9 O; |, u+ O. c' U; c程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?$ z% o/ _: D% D! A

: V/ M/ z! ~; n1 f' F0 z' J! Q' S另外一个小建议,就是move,所有的move都可以这样
1 c6 i2 L, n2 N- mif not move() then debug end
4 P4 U: m4 t5 a* Z! U这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
, V1 T0 H$ Y+ ]" y' }plant simulation中的free libraries有AGV模板,. p: a: V1 T9 ^  L' \
里面也有案例。0 \  R+ S& c" }* I2 R1 w4 i
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。( J  r4 d- E6 Q7 i

" z4 b$ N$ ~, y4 S* @我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
) S2 ~; ^) I; g  z3 q
# L* M) n6 p" G; t( h那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
/ j+ [  H. v. Q$ q这是AGV_putin中arrive的method。
: V$ w4 X" x/ O8 M. ~. R2 B$ S0 v
' ]3 E: ~( k9 y) Z5 b当到达物料速度越高时,这个报警更多,
" m( F$ b& o: P2 j% }8 J4 f
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-27 06:43 , Processed in 0.017054 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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