设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8289|回复: 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'& ]/ q1 g: c' A7 E% z6 K
*/
2 ^+ S( r' G, Qis0 G4 x9 F6 U. T/ C1 f
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;! E  x$ M. E% |' a6 F1 K
do
6 J0 U2 F- r9 U+ f        Lan := rootfolder.Internal.Tools.AOLlanguage;+ x) q6 C' V2 U* z( j* X7 `
        if current = @.Destination -- else return
4 H, {! c( d5 G7 _. K: h/ n        then4 h" A. A3 s. T
                @.Destination := void;% B* C' [4 m* ^7 G% N) G
                if @.occupied then
" `/ x$ x. Y, ^& N, o                        part := @.cont;( g7 V4 H( y5 t
                        @.transpOrder := void;
7 w5 C$ w2 j# v' J/ _+ {' d                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
( A  Q# |( A" F9 {; l- b                                @,root.eventcontroller.simTime);
' j3 _; d2 A" d, y6 O' A0 H                        @.HasOrder := false;3 ?; |1 J3 O; R* S2 x3 n
                        @.DrivingHome := true;
" P' }9 A; ^/ p; {; o& L" @                        rgManager.tryToStartTransOrder;, m; K  Z- P4 I
                        if @.Destination = void
  d0 c' T5 S! Y& M; t                        then -- no transport order for vehicle @( r  f2 q2 v& D8 F
                                @.Destination :=: j1 ^- X) D' r
                                rgManager.nearestFreeStation(@,track.~);
6 l8 N2 R. Y; \" o# ^7 A                                newDirection(@);   / t8 J" C3 A5 \3 U6 ], P
                                if @.Destination /= void then
4 D: N6 Z, V* t7 f; J+ l                                        @.Destination.NumReservation :=2 ^- r4 S  T1 X* L5 U; L
                                        @.Destination.NumReservation + 1;
4 e* T% L  I) Q( l                                end;
$ E. d% K( @" ~7 Q                                @.CurrIcon := "drivingHome";2 _4 c3 b/ L4 c5 f
                                @.DrivingHome := true;
( L4 D/ t$ |' C  d: m) E                        end;
: n* t+ X* `/ [                else -- the vehicle @ is empty, both vehicle and part are in the same dock station7 o& Q# F4 p3 O: a
                        part := @.transpOrder;3 b2 h6 e) Y% d" `4 k
                        part.move(@);-- load part0 {( d" {" j: d6 T' c" w/ t
                        @.CurrIcon := "load";
! c" I" V  h# R5 M                        GlobalDistObj := part.globDestination;
" K: u% a& `' o0 `2 I9 `& @% ~                        assignLObj := rgmanager.rgAssignL;. G' Z- @4 S/ E! s4 H3 l4 Q
                        row := assignLObj.getRowNo(GlobalDistObj);
, d+ ?8 a' T6 q; o+ P! l                        if Row = -1 then -- since 707 n  P' D: M% }; V4 P" v! G. e: A; n
                                if lan=1 then
; ?, r2 ?3 s( G3 p4 J7 T                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
- d3 T5 A. H) ^) w                                                to_str("in der Andockstation: \"",?.~.name,"\""));0 A# Z) s( q5 v: Y* G* j
                                else0 R  K' n; k7 S" g
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),- h3 O8 u$ p- j# m
                                                to_str("in docking station: \"",?.~.name,"\""));                               
8 e7 M' |  @* ~                                end;
/ A: d& r9 V- H# y: m1 U8 w( a) ?                        else  L& I" e$ w2 S" O: q8 Q+ h
                                @.Destination := assignLObj[1,row];3 l" u  i4 Q# X  x2 O  S
                        end;                        4 y5 \1 {6 g6 v# Y$ J' R
                        newDirection(@);
6 r$ N/ G! {; _8 F                        @.HasOrder := true;( \; l# f& Z: D1 F& T
                end;. i9 t9 {( \8 s- f) B) N( F
        end;
8 X* e$ t7 u/ d, o. Q3 kend;        -- of the method
! c8 k) M8 w' q7 _5 y
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
. H) C9 G2 d4 n1 A8 Y0 t/ J! n2 _
这是AGV_putin中arrive的method。7 ~6 G/ F/ K" a, I. x' y

  m, I! X5 C2 u3 N当到达物料速度越高时,这个报警更多,* `- ^3 h0 F6 C: W! B! q/ p
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。$ W, J: M. J( R; B/ D5 A! Y
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?0 x1 [7 t8 q, z! d5 @+ z

$ G, H2 d( k) z/ @1 H1 O另外一个小建议,就是move,所有的move都可以这样$ b( l" g: d! B; T, u$ l
if not move() then debug end9 P9 |+ U; `: i2 J% R: Z( g* _
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
% {3 P7 \% q4 I  ]plant simulation中的free libraries有AGV模板,; \0 u4 l! n: @* x
里面也有案例。
* t0 J, x3 N' v0 m5 I4 h/ w0 d: r  B0 t/ \+ [我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。* h$ u4 r+ Z/ F1 ]7 l1 j$ b
& p' z1 U1 U! l* c, A
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ; R* Y1 r2 }* P3 x8 \  e
: n8 f! b. Z, z4 d: i
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
6 L; `/ c. O' Q/ t2 m- w) K这是AGV_putin中arrive的method。' M' O- \+ V' z3 V" P& C
( B) f0 a. Q( J2 o& t9 g' @" w
当到达物料速度越高时,这个报警更多,

3 b  b: x  N) T9 s' d) p/ V$ }另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-25 16:58 , Processed in 0.017030 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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