设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9542|回复: 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', K1 f, O+ A, q4 c1 v
*/
. i8 U. |2 {  Y* \, Z4 Gis
8 _! t3 C* R: p8 t8 F        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
% Y0 e% G( }; t' o/ c$ hdo; ?1 u3 ^+ A) ]& x1 S+ y: U
        Lan := rootfolder.Internal.Tools.AOLlanguage;2 N# `" ]; e% [6 a
        if current = @.Destination -- else return1 X% w! _+ k$ }$ ?' f0 J
        then
% h, S" b5 s; b$ i3 N% z- y                @.Destination := void;
, N( M5 u, d* T" z/ Y/ H                if @.occupied then
! o, k. p1 \) o: M) \/ m                        part := @.cont;
, G6 \- |: ?% N+ j                        @.transpOrder := void;
8 A$ x+ q0 Y. d* ]' Q                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,* I/ l9 f& p1 m* J2 h4 `9 ^. p
                                @,root.eventcontroller.simTime);
* R6 d. e3 b! g: v/ q' N! O$ I                        @.HasOrder := false;
0 i3 D! l8 j; a$ v5 o+ F                        @.DrivingHome := true;# U7 d$ k) T0 A  ?$ G& V9 ]' Y
                        rgManager.tryToStartTransOrder;1 o& B. P5 e0 y. v7 D) r+ X
                        if @.Destination = void* R/ E7 C* h. u1 k1 s$ e! e& _" l
                        then -- no transport order for vehicle @
; ~* S9 {/ J$ O( y, p: h                                @.Destination :=- v& W" z2 q3 t$ t" k* U$ R
                                rgManager.nearestFreeStation(@,track.~);
6 A/ R* r4 Q: z: x8 K" U, ^7 l2 V2 K                                newDirection(@);   
# I! Y- ^9 o/ o. ]( X  C                                if @.Destination /= void then1 k; X% }- I% W: q- o
                                        @.Destination.NumReservation :=% ?' t" J! T, R* y; X
                                        @.Destination.NumReservation + 1;
$ r# M7 {% e  I                                end;- g9 q" i) c) o7 {1 N6 ]
                                @.CurrIcon := "drivingHome";
! Q& \4 J- ]/ Y. z! N1 d/ I                                @.DrivingHome := true;- v8 B- B. `+ B  V9 Z
                        end;
7 {6 ~! F% E. J8 U                else -- the vehicle @ is empty, both vehicle and part are in the same dock station8 `6 _0 }: |4 O/ }
                        part := @.transpOrder;
. R6 I8 z) W/ J# X                        part.move(@);-- load part
( ]$ D! @+ U( _( L3 e- c                        @.CurrIcon := "load";% \0 ~% T1 w6 `! i! [- f9 X- I. }
                        GlobalDistObj := part.globDestination;
. `0 d0 X8 b6 z                        assignLObj := rgmanager.rgAssignL;$ f" L$ M; b9 t
                        row := assignLObj.getRowNo(GlobalDistObj);
2 l( W/ }( D: C& `5 e, ~8 p+ \. u                        if Row = -1 then -- since 70
: S8 z" v) ^; S( H! [7 _                                if lan=1 then) i1 c1 g6 @% R
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),) y& r2 t* T" S7 p/ _! W
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
/ d! j" R9 \* }+ T& Z                                else
. G* |) ?2 W4 ^                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
, Y- @7 O' ]# Y/ ?                                                to_str("in docking station: \"",?.~.name,"\""));                               
) j4 y) V" T7 X  \6 I5 M- d                                end;4 ^* L) F; X- F; @8 V
                        else1 `  N. F) S7 v$ W) f' R
                                @.Destination := assignLObj[1,row];
. p& c, b$ ~% r. n) V                        end;                        ( b' N) E6 {% y' c2 v
                        newDirection(@);4 h; l) l- D) d
                        @.HasOrder := true;, ]! V8 p2 P) Z
                end;  d5 h- _0 M6 Q: u' v; o* v0 ]
        end;
- {  a9 R: U" x$ \% Z" [end;        -- of the method
: X& j9 e9 v) p% r" [9 l/ Y. n) J  X
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 4 N, p& c+ D/ V0 ^& N$ F* D

7 r4 J4 k6 ]* V  ?1 e/ e$ m6 Y8 ]7 n这是AGV_putin中arrive的method。1 ?9 M& S* u7 f

" O6 P+ j' _% q5 @当到达物料速度越高时,这个报警更多,$ m: d2 H3 U2 ?7 F
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。: \. ^% G% Y# l! ~1 X( e5 O
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
! l# f$ n+ R# L; |8 p; ?; m$ V) s7 W0 T
另外一个小建议,就是move,所有的move都可以这样
6 l) V; [- V/ Z! h; |/ J4 @) e" ~" bif not move() then debug end5 y8 o9 ^% ~" G$ q/ @
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。5 H' g) ], Q9 q/ S) M# U( U) f
plant simulation中的free libraries有AGV模板,7 D( U; A7 w/ D! }
里面也有案例。( k" H% K: `' \/ k; H- S
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
2 a- z) O* W6 q  |( p" X/ T+ T% x, T& |
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
+ n8 p2 p; y- Z* ^& J4 y; o
8 B2 l4 a6 b, k那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 + c4 T% F/ u& X0 n+ O; x
这是AGV_putin中arrive的method。* s  f& f2 m9 q1 I& B8 j2 [4 q' O
  H  c/ X! ?: O$ O' W
当到达物料速度越高时,这个报警更多,
3 z% v, F# k( o  X& }5 X
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-7 00:50 , Processed in 0.016200 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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