设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6829|回复: 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'
% h+ P$ @! L, l  ~% p. @*/& k7 \# T8 e  p0 \4 q
is8 a: b; T: E8 {! W% C' [2 l* s' C
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
# ?' s. f5 p, m# Q, |/ ?) }% Pdo
  c8 x. Q  ?; `2 y+ d3 z$ s; a        Lan := rootfolder.Internal.Tools.AOLlanguage;
8 I9 g5 V: M) l        if current = @.Destination -- else return! R/ i9 U# l7 ^
        then: Q, K  N. m1 Y+ ]
                @.Destination := void;' O$ E/ J; ]6 f  Q4 N( {
                if @.occupied then1 y& `$ `0 T' `1 b5 T
                        part := @.cont;# v! E" Y+ Y( g# ~( Z) |1 Y9 _
                        @.transpOrder := void;
, r6 ~+ z2 g: F4 V                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
" B. }9 O/ s9 |* N: P0 N; E* J                                @,root.eventcontroller.simTime);. Q. c* k3 N2 K: Y
                        @.HasOrder := false;7 g8 e  `* _- u9 u: f
                        @.DrivingHome := true;4 g9 T2 o) s# s! P5 x9 W
                        rgManager.tryToStartTransOrder;
: ^0 \. I5 t0 ?                        if @.Destination = void/ ^' t. ?- |! h# `. B4 ]1 `5 t
                        then -- no transport order for vehicle @
4 L2 {) T+ J' U' }                                @.Destination :=- d( B3 U8 R5 i3 b
                                rgManager.nearestFreeStation(@,track.~);
% }/ W  G8 |) k' y* d* l6 a" t8 z                                newDirection(@);   6 c9 O. P7 g' h% a$ m: h# o8 u
                                if @.Destination /= void then
+ v1 ?4 i- F" F$ o                                        @.Destination.NumReservation :=
7 @! H6 t# z( z7 q- R8 B) Q                                        @.Destination.NumReservation + 1;* L5 S' }8 |! j* h7 b4 O
                                end;7 t' t- }; T* K1 J
                                @.CurrIcon := "drivingHome";- b- R, @# B; a0 h
                                @.DrivingHome := true;' m/ J0 ^  O% K, ~4 L
                        end;% i, H: q' \7 h+ |# a
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
* Z8 D9 C" ?" P' P7 j+ Z                        part := @.transpOrder;
$ g% R/ n' `( o8 u" O1 X4 j- F                        part.move(@);-- load part( i/ H: ?8 ?$ ^6 Q
                        @.CurrIcon := "load";
& z% O9 n9 z: B9 C% B& C, V- Y                        GlobalDistObj := part.globDestination;) J9 V' `' M& m! O4 m. q4 c
                        assignLObj := rgmanager.rgAssignL;
2 d9 C: X$ e) T+ }. I                        row := assignLObj.getRowNo(GlobalDistObj);& Q7 z/ k7 V8 v" {, S
                        if Row = -1 then -- since 705 ^+ e; J7 g$ X) z2 o
                                if lan=1 then
1 t9 K$ t+ Z8 f6 {' y8 j9 g                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
- T3 l! P. m$ p# I/ Y+ ?                                                to_str("in der Andockstation: \"",?.~.name,"\""));
) G% l" @9 H3 b; D                                else' T: _0 m0 A2 z8 E# a$ ~
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
- w& V0 w+ V( g) k. z/ Q' G6 M                                                to_str("in docking station: \"",?.~.name,"\""));                               
' N  y1 _9 x8 O                                end;
$ D5 _9 N; Y% p                        else9 E# ?+ R6 J9 \
                                @.Destination := assignLObj[1,row];
6 v5 j. I# e& @3 p1 ~" l  K- f                        end;                        0 E$ O# z* e& ]7 A9 g( \
                        newDirection(@);
, x( b( j6 F5 c: g                        @.HasOrder := true;2 B# r; F; H  G+ u8 h# L( ]  I
                end;
* n7 Z3 ~$ J+ t, J) e8 h' f        end;
6 C: `7 d8 \8 x0 Q% K( C/ @end;        -- of the method
) Z: D' t) }# F2 E* O( [
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
: y$ l$ C8 {1 S* J) l0 Q! T" O6 a) c" N6 Q" F9 q% C
这是AGV_putin中arrive的method。6 ~4 L7 ]9 D. j6 _. y7 g. k# J

( L' s# A9 p/ s) O: B* n- W当到达物料速度越高时,这个报警更多,
  ~2 s( o' F% d可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。8 C, J+ j) A% z# o) |. Y1 B+ U
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?% g# U# ~' d7 ?- I8 |: M
9 l7 C' x( J8 c! E% f
另外一个小建议,就是move,所有的move都可以这样- L" e% a/ a1 W( g. }
if not move() then debug end! Q( E5 W" w, x
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。9 D/ q5 I. ], @! H. `& b7 V
plant simulation中的free libraries有AGV模板,2 z9 l7 U2 j  R5 u  T$ T. a
里面也有案例。
- Z0 Q+ k+ J; {2 j1 B6 b我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。) H6 `& Q7 q( z+ A5 ~2 Z" r
+ v8 y' J" R/ ^( v
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 $ ]! G8 h6 L3 W
+ T% P- W; u  ]) O1 W+ k) p  M
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
) M7 N/ O! T( w这是AGV_putin中arrive的method。
( n2 v# ^/ b7 O2 G+ w: d5 k/ L- _- [- `8 y0 C. E5 b+ C) j. F- ^' o
当到达物料速度越高时,这个报警更多,
, V$ h  O9 y: W! v2 h
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-1 04:14 , Processed in 0.019301 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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