设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5460|回复: 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 [! Q: }" a
*/1 ?; ~. n; q" O7 d" H9 v
is
' e' E0 i$ y7 v        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
/ q' Q/ }& T! L; K- Q  K( udo
# C# a8 g  h  V; w- [4 {2 h3 R        Lan := rootfolder.Internal.Tools.AOLlanguage;
( i: x8 W$ t$ e2 o& y4 [        if current = @.Destination -- else return
5 M% ~. j( a6 R' T        then! {$ a9 q% f% p7 w3 G
                @.Destination := void;
. b  j7 W+ F5 N7 }' |, j& {+ e                if @.occupied then5 A7 g: M/ D' m$ R) S* f
                        part := @.cont;
: v: B+ a$ k; c  t& P                        @.transpOrder := void;' ?+ [; Y- L' x9 {$ f
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
$ N- m$ B, ~" y9 l& d: B- T                                @,root.eventcontroller.simTime);8 e! `" q" U7 A' ?
                        @.HasOrder := false;
8 [$ y/ S  }  l& N8 `: b9 K                        @.DrivingHome := true;# n$ A8 h; s4 e6 _
                        rgManager.tryToStartTransOrder;
; K* {9 E2 z2 u                        if @.Destination = void) [3 l( F. ~0 t4 \$ I
                        then -- no transport order for vehicle @
7 M# y. m/ i) _6 w3 t' u                                @.Destination :=
2 l0 I- x# u/ {" ?# L                                rgManager.nearestFreeStation(@,track.~);1 |! K: d) x/ R! K- v) d7 i
                                newDirection(@);   
" s# h# z6 {7 h: c, y9 ?3 M1 t                                if @.Destination /= void then8 _0 t0 f3 P: H; K6 L
                                        @.Destination.NumReservation :=
9 L0 V1 f* E/ P. ?2 s                                        @.Destination.NumReservation + 1;* o2 I/ }- v4 v
                                end;: r6 X% S" F* z, C( Q  ?; B
                                @.CurrIcon := "drivingHome";/ B4 j# R5 B1 J  L  x3 u
                                @.DrivingHome := true;
$ _/ R5 `$ ]4 O( N% d# a- e, p) G                        end;
& z) t6 t9 Q# S: z9 Q+ s2 }                else -- the vehicle @ is empty, both vehicle and part are in the same dock station, X) w( v. H; z# ?9 Q: [- D
                        part := @.transpOrder;6 o, @! H3 L( z# P' P* f
                        part.move(@);-- load part2 z  q+ P3 q! g! \7 N* E3 G
                        @.CurrIcon := "load";
1 ~9 q9 @9 a+ V3 M3 t                        GlobalDistObj := part.globDestination;0 [4 i8 N& r) P, x
                        assignLObj := rgmanager.rgAssignL;
& c5 d, o6 O; b8 B                        row := assignLObj.getRowNo(GlobalDistObj);# D3 B' x- |4 Z: y' e; |% R7 P+ L% V
                        if Row = -1 then -- since 70- z+ A& D# f/ @- l* i: I7 t8 ^8 B  Q
                                if lan=1 then, ]9 W& x) U6 M/ }- f' K! _
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),6 X3 @2 ~9 G0 @7 S
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
/ D, R: \, n; Y- x0 z, Y; v: @) l" O. b                                else4 L% k8 g* b/ e# w# L
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
2 L8 g% D- v1 @                                                to_str("in docking station: \"",?.~.name,"\""));                                6 I. }3 m9 X/ b0 o' A$ y
                                end;0 g5 C' z. B6 d. j5 ?3 z  n
                        else
% w8 `; r- @; P0 t  k1 s                                @.Destination := assignLObj[1,row];7 D" V  }$ @' Z! ]. \4 b
                        end;                        ( `0 N/ w8 U0 y" w1 ?7 I
                        newDirection(@);' w% T$ @* B5 d3 X3 B
                        @.HasOrder := true;: @# U1 F0 x  c0 _( `1 h( u; c4 T
                end;
- f. ?7 P& P# Z# l$ O; ^+ v        end;
! [& b6 G" w/ l8 iend;        -- of the method
2 I0 G' P( B- X- n% C
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 8 x" Z1 \  n9 x7 h
0 }' A8 V0 D" \5 G
这是AGV_putin中arrive的method。
$ w7 J: g$ |1 I: Y) a! p' F1 k
" N1 Y; r" C8 b8 G, Y当到达物料速度越高时,这个报警更多,2 n  Z" @% C# G9 I1 g6 [# L
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
7 |  v, q5 A. \2 U0 I7 O; J程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
3 z! ~& I3 K% A! T/ T! ?0 P8 i" G
2 |' H( B% M# M) j  {" N1 f另外一个小建议,就是move,所有的move都可以这样
$ J3 D+ L% h& h1 O' Gif not move() then debug end2 _8 [0 a, y/ ^& a: a4 b( o* r
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。# C  T" a2 h$ D% ]  F
plant simulation中的free libraries有AGV模板,; n2 X+ G1 [* e9 n, O0 v
里面也有案例。+ M$ z, t) `% N6 y
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
! z* D" b) G0 N  `& a( _
  A. l! R" T% h& M8 X( F我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 * f) S  ]4 q/ w. J9 E7 r3 A& t
9 [4 p. M1 ~' v/ V% u
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 - {6 b. w# u6 S
这是AGV_putin中arrive的method。
; E, d5 p/ ~6 R
$ S# G# M5 U6 g9 L% n当到达物料速度越高时,这个报警更多,
+ c) L; _& R) p7 }' T# E6 C
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-11-25 13:25 , Processed in 0.019108 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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