设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6914|回复: 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' l. c, _& q*/0 B% H0 \# Y7 c$ r
is
" B- o( Y  B9 E" ]$ Q        part, GlobalDistObj, assignLObj:object;row,Lan:integer;& c: E3 I4 m1 C# Y
do
. O# R& }  I  `& [: x- o        Lan := rootfolder.Internal.Tools.AOLlanguage;
; J, G2 h8 |! q4 ^        if current = @.Destination -- else return
+ v8 f# E6 T0 y( g  T$ f2 H        then
' e  v4 q) Y( G1 S6 _( D3 y                @.Destination := void;
$ G7 i& X. T* }- [) ?9 P! q4 I                if @.occupied then' S) |0 \  `0 M
                        part := @.cont;
# R$ t! V. f2 \0 _$ z! p" b                        @.transpOrder := void;% W* v- z" I$ F8 T. v
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,$ h+ }! x* X9 F% K: f
                                @,root.eventcontroller.simTime);' V2 f  l% Y. N& O3 w2 m# }9 D! Q
                        @.HasOrder := false;/ ]* x6 f7 s1 S! b) W( I: H3 v
                        @.DrivingHome := true;
9 ]6 r4 {$ g9 p                        rgManager.tryToStartTransOrder;" m8 K3 y: l) t
                        if @.Destination = void
' ~5 Q! x! }/ y6 x% N% S/ J2 H" i                        then -- no transport order for vehicle @
) e% d0 i# ]/ C8 `( J' [, n                                @.Destination :=
9 w1 w$ s1 q) {, P, K2 L                                rgManager.nearestFreeStation(@,track.~);1 @: ?" S) ?5 Q. p: J0 t* o
                                newDirection(@);   * }5 {. m; G$ _
                                if @.Destination /= void then
/ k/ J: Q0 X$ R7 ^! Z                                        @.Destination.NumReservation :=
- Z. @1 L4 _; U7 s' r' p                                        @.Destination.NumReservation + 1;
" `) x5 w" O: H& x+ V                                end;' d, x5 T2 j- U0 U% X  @
                                @.CurrIcon := "drivingHome";
; Y* W) h  A1 M( w) x                                @.DrivingHome := true;+ l+ s* o! r: D0 R+ t
                        end;
% p# W! B' u% m5 Y: w                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
/ @1 o/ ^  Z  l3 ^  _- T0 o! D                        part := @.transpOrder;
3 @# t! x8 @" }                        part.move(@);-- load part
) t4 v5 V) ^5 {* j  g- D% {                        @.CurrIcon := "load";
& O; S# M7 U* @8 a  Y) z* ~                        GlobalDistObj := part.globDestination;
  C0 q$ z+ h# B3 f                        assignLObj := rgmanager.rgAssignL;
( ?* A, Q5 J$ r& h/ M6 ?                        row := assignLObj.getRowNo(GlobalDistObj);: p2 u# H) f, D* s& g
                        if Row = -1 then -- since 70
& k) w' r% f  |- C6 B: I. f3 N! ~/ T                                if lan=1 then
# E8 d; [' _# Q: _, w: o' O+ A  p7 w                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
2 A! }6 S! O# x/ W3 o' K4 Q9 R                                                to_str("in der Andockstation: \"",?.~.name,"\""));
+ G; u6 F& _' u0 c" O5 Q                                else
, [9 z9 M9 m" Z3 M$ L* a- j                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),, Z+ l4 \+ M, i* }
                                                to_str("in docking station: \"",?.~.name,"\""));                                1 Z3 x% L: m2 F0 S6 O( N( S6 d0 m; y
                                end;
4 }4 q1 Z% ?1 X                        else5 ]$ ?; d5 @3 Z* t0 v
                                @.Destination := assignLObj[1,row];
; A# n: v/ c( k4 x" v8 t, g3 C                        end;                        8 F! x8 Y: m4 E) K6 x
                        newDirection(@);9 z  H8 J9 t% \- j* x6 f5 \  M
                        @.HasOrder := true;" E) O- @3 f" Q; Y& f
                end;
+ O0 R3 r# x* F. A' P; @        end;! S+ `% j" X: h4 h9 a1 Z
end;        -- of the method6 p/ Z. z' Z% o7 D; J
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 6 D# w, _# S8 J/ Z' [8 q% O, Z
' z! _1 h7 ?- x. t  l- m" h
这是AGV_putin中arrive的method。  m3 d6 l" ~2 A& M  ^
8 l% j4 w. Y! \" h3 p4 E3 B% ^
当到达物料速度越高时,这个报警更多,6 e6 k3 Z2 f6 r9 Q5 `) l3 |
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。/ q/ P" r8 \; \4 l
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
3 d# x. F/ @. `6 P) J
; E0 ^# j; U) J$ R' S: W: k4 ?另外一个小建议,就是move,所有的move都可以这样
/ h! ?& C3 P2 \/ Aif not move() then debug end
6 O' ]8 E: }4 ?3 E9 ^0 S这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。6 l! y! ^: A& Q* `8 x
plant simulation中的free libraries有AGV模板,
( ?1 H; w9 ^0 `3 t! G/ p( Y里面也有案例。
! F- t) b; M; j/ @7 v( Z我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。/ D" G5 E- c$ c$ S  k

" L" a4 Z4 n! B9 f4 a& f我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 * v$ _8 S( s. m  _5 Z
' i: s! V) D& {' [
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
' a/ M$ P2 z3 C. m1 U) \' g这是AGV_putin中arrive的method。; M  e1 {0 _% _/ K
' |% B  i5 K9 @$ {  o' i. Q
当到达物料速度越高时,这个报警更多,

+ _& g3 Z" Z( R& k另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-6 15:18 , Processed in 0.020550 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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