设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10015|回复: 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'
* k2 @, T4 D1 J*/$ o* \8 [+ E/ q" e" e# k. H6 p
is0 w8 q1 m" B: S0 Q& r4 N
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
" L( t# h( M  R/ ~$ u; c' b, ydo
2 T3 ]4 L9 \* _  |3 L+ B; @# m        Lan := rootfolder.Internal.Tools.AOLlanguage;' f# _) k; K7 F6 t
        if current = @.Destination -- else return0 D4 f0 R* R# N, c) |# ^
        then
) I4 V' i" q4 z7 \( x9 H: C                @.Destination := void;# Q/ p" U  {( W2 y0 O4 o4 N
                if @.occupied then
9 N4 ^8 n' ~4 D* b. j1 S                        part := @.cont;
0 }' A7 x# I2 C                        @.transpOrder := void;' n& u! T* X3 p6 f; }
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,3 B1 l8 b5 y$ m! O6 i
                                @,root.eventcontroller.simTime);
3 v. `' n1 m* j. A                        @.HasOrder := false;. `8 s  _* l  W+ _
                        @.DrivingHome := true;2 p+ [) W- g2 ?' v2 _( B
                        rgManager.tryToStartTransOrder;
; Z+ w/ ^/ Y& T; \5 X                        if @.Destination = void
; c- U$ ]. C6 N  }" H& f& |                        then -- no transport order for vehicle @' M1 v. I3 N& E8 L8 s& N5 R- f
                                @.Destination :=! R; |7 J7 N4 n. r! U+ K" c
                                rgManager.nearestFreeStation(@,track.~);
2 L1 m  u7 X0 {9 `* V9 K                                newDirection(@);   
8 d% `4 ~  V* g  o7 Q8 b4 D                                if @.Destination /= void then# C+ k. `* @- @+ m, X6 G; b
                                        @.Destination.NumReservation :=* ^6 K6 T% \2 j' e. J/ {
                                        @.Destination.NumReservation + 1;
& U4 m/ L- O7 [& U+ F# h9 L                                end;, @0 v: s6 r) d# T+ d& o
                                @.CurrIcon := "drivingHome";: y' @$ K: d& x- l$ x. J8 w
                                @.DrivingHome := true;
: e+ w9 V7 w) F/ w+ @9 R- P; N                        end;% S; K3 q/ g7 V6 ~1 k, @
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
( w" E3 x$ I4 q% h- j0 ~                        part := @.transpOrder;
& a( o' c8 w1 ?5 \                        part.move(@);-- load part
- s: P9 B. u, \  A                        @.CurrIcon := "load";" r9 _& Y2 d& d* R. R4 q
                        GlobalDistObj := part.globDestination;0 i. u* v6 {! {: `' K/ x% L! [( {' N
                        assignLObj := rgmanager.rgAssignL;
% u* b+ b" w8 V3 |& Y5 u: `; ~5 b                        row := assignLObj.getRowNo(GlobalDistObj);: }% M: {5 l8 D" ?. p
                        if Row = -1 then -- since 70
# \2 {+ L- @; H                                if lan=1 then( j0 D; e4 d! z( U
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),0 r3 y' V, n* c1 ?# q+ h6 W
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
0 z/ g2 h" n6 Y+ p& A/ I# p                                else- E+ F6 B' D% p' ?+ L* s2 x
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),! ]; \7 [$ p* l! S7 n: V
                                                to_str("in docking station: \"",?.~.name,"\""));                               
# h) c; {+ Y! @. I  V2 E7 i2 f                                end;
. e7 h# p0 I; J2 k( }$ Q( m& s, }# }                        else+ E+ ^. z2 U1 C8 d& z% T' G% H  n9 i
                                @.Destination := assignLObj[1,row];
8 q, {2 [; ]& H                        end;                       
- u7 n# R- N+ D# a                        newDirection(@);
9 U; U# ]5 g- [+ R                        @.HasOrder := true;
6 f  ^' i" y: [" W/ o* X+ B' [& Q                end;
8 S( c5 C: z" o        end;4 C% L4 M( L; E0 [- ?
end;        -- of the method
$ H2 J9 J9 h) Q. S$ B  _
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 3 U3 T5 o* T0 |
) P: q$ Y$ s  V! }/ x- u
这是AGV_putin中arrive的method。, ?$ r1 c  _# e7 [( ?( m$ v! R- m3 b
/ L. F( l% x0 B# [: Z  `+ P
当到达物料速度越高时,这个报警更多,
9 T6 Z5 \6 a1 q4 H( L! m% s可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
8 a+ H$ \1 m; D. y3 r: z程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?4 V, ~' Y% e8 Z' L; c
  N6 m. S) Q, t6 {
另外一个小建议,就是move,所有的move都可以这样7 B2 e' P, \: J* ]; h
if not move() then debug end
6 M( U' ?! J& c0 a1 k8 @这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。5 E9 l) v. T4 g7 u5 m4 q
plant simulation中的free libraries有AGV模板,1 c/ ?0 z& P8 I/ c; J5 V# L3 z- H
里面也有案例。$ M7 Z9 W, j; o
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。5 [! k9 I2 t) s& G! A

$ X! ^/ p7 i! Y  @/ \; r我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
$ I5 X4 g$ E% z* w
7 y' X3 c% v5 f9 s( {那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
1 \6 G% q9 @3 \这是AGV_putin中arrive的method。
+ E) j- y$ }; ]0 G
( S( d) E4 @+ x4 Y8 B当到达物料速度越高时,这个报警更多,

3 r. {2 u; o5 B3 l' p! A% S; i# i/ n- C另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-7 17:06 , Processed in 0.023853 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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