设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9775|回复: 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'4 T  ]  o1 E) o; [! ^$ m  E! k
*/: ~3 c# j" W+ u% W
is
3 f) Y! f/ [9 V5 K9 I! c5 T5 `        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
$ ?, p% P# o% ]( L. x; Tdo
* y) b: X- B8 W; t' G        Lan := rootfolder.Internal.Tools.AOLlanguage;8 J- p0 _- e( Q9 N4 i
        if current = @.Destination -- else return
4 u! l0 W' c8 R8 D+ K        then
- g: f, r& q# B3 Q- _) f                @.Destination := void;2 p3 A* o$ h9 A: ~, @  ?+ [: _; G
                if @.occupied then8 R) |! |8 p. z
                        part := @.cont;$ E8 m( U( N+ t
                        @.transpOrder := void;
! i/ m- e# o' f6 [% ]                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
/ H4 f6 k. D9 \) r; A6 H                                @,root.eventcontroller.simTime);
& z" P! Q) W. O4 Q$ c& ]# s                        @.HasOrder := false;2 _5 A: o! W9 \3 |0 ~- p; n
                        @.DrivingHome := true;
% H" Z! a( B8 J# v+ i) q                        rgManager.tryToStartTransOrder;
0 g, E! `4 }3 S, z: P                        if @.Destination = void% D, M) I7 j+ ?8 e6 f2 s1 ?
                        then -- no transport order for vehicle @3 X1 P& V3 s& g
                                @.Destination :=
; S0 g" Q# k0 [: l4 ]                                rgManager.nearestFreeStation(@,track.~);
& ~. q% A8 w% q* o6 S                                newDirection(@);   
& x% k) K2 K: y2 ]1 m6 U                                if @.Destination /= void then  l- M! }+ s: ~8 \8 F' H" X
                                        @.Destination.NumReservation :=
4 y4 m6 u0 z3 y                                        @.Destination.NumReservation + 1;
( \; {$ E% \# x2 R. R                                end;
! b& a$ J7 }5 ?) k5 D: `                                @.CurrIcon := "drivingHome";
4 D& A) A' a# K5 X7 c& _' d                                @.DrivingHome := true;1 N' R7 ]: R' A8 e. E( v
                        end;
' H& N4 R& d2 v2 c5 F  E' H: G                else -- the vehicle @ is empty, both vehicle and part are in the same dock station- y- R2 }; |8 e2 J  C/ i
                        part := @.transpOrder;
7 V6 m: i/ @- s7 R! [% \                        part.move(@);-- load part
  L, Z1 |- c5 s% y; s& I4 {8 C                        @.CurrIcon := "load";
$ ?- N" s5 U) [  J& A                        GlobalDistObj := part.globDestination;$ i1 ?) M% H8 g' k0 q0 C
                        assignLObj := rgmanager.rgAssignL;" ~7 H$ v9 B: Q" w
                        row := assignLObj.getRowNo(GlobalDistObj);
; j9 h9 @8 ?- a                        if Row = -1 then -- since 70
% F& M8 w3 U- Q                                if lan=1 then4 V; R3 \$ M- u2 r9 }8 p1 @
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
4 x& A, e" f$ u, x. z/ R- A1 g                                                to_str("in der Andockstation: \"",?.~.name,"\""));
: f9 {0 ~) ]) V- n4 u: c3 X! G                                else
$ Y* }4 |' p' ]- u4 q+ F# F. R                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),! M. V7 [) s. l/ O4 j8 ]
                                                to_str("in docking station: \"",?.~.name,"\""));                               
4 F0 S# P, I9 k+ I: I                                end;
$ J7 X1 Q( N% x: @; ?6 Z, s; b                        else
) a. s3 v7 G! O& @                                @.Destination := assignLObj[1,row];' v+ R( U9 H: r; `3 _7 z. b, B) d7 c$ ~
                        end;                        . ]1 W$ {. B( i2 R3 `# ?
                        newDirection(@);  T# z! e! f+ A' v
                        @.HasOrder := true;2 _1 {7 X3 W1 r5 {. q, b
                end;* O6 O8 E6 Y0 X# L" U4 U
        end;5 x7 q8 P* q3 M' x$ `3 W  G
end;        -- of the method
; \' D  y6 {$ \+ t  a2 x. K4 [" g( d
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 / y# u2 E8 Y& i/ g# D
# M0 m9 y8 Y2 S# d8 o' {4 C
这是AGV_putin中arrive的method。
( l. B* w; r' w# O. ?! T% E% [% E$ P& e
当到达物料速度越高时,这个报警更多,
7 t9 ]! C1 o$ I2 k) w% V4 Z可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。8 R2 I3 g- f% B. A! R7 Q
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?+ L% Q7 r1 [/ d3 Q/ X* v* t' O3 u% Z

" S* M) J' f9 s% [: Q& E另外一个小建议,就是move,所有的move都可以这样
4 k: D. B, X4 O: S3 Nif not move() then debug end- G/ v! P5 D5 m& ?) Q6 X
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
) c; h, w$ l* Z- P7 e$ jplant simulation中的free libraries有AGV模板,9 c/ Z8 |! ]1 @& t9 j  G
里面也有案例。  j# v4 _0 r- j5 D; [2 ]
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。: X" C: z/ P. u8 Z

$ y4 ~4 j# n5 p: a7 u我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
4 d5 E+ }* q: o& X4 x6 e6 Y0 \- n* V, E0 m  ]' P; U# t
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
# Z. v  }  p5 [; x8 [这是AGV_putin中arrive的method。' k7 w3 a" A/ l
1 ?( Z$ U" D- m8 V; k# g4 {( m
当到达物料速度越高时,这个报警更多,
, O8 b: {' D' o! ?
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-24 04:54 , Processed in 0.024455 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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