设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7521|回复: 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'
* N9 ]/ u8 o3 k% {# ~*// C* L* e; M3 a! A% }
is
. }& O+ X* t+ \, _& W        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
1 G* @2 J+ w( o9 h, Z  pdo+ `& ^7 E: c" G( D
        Lan := rootfolder.Internal.Tools.AOLlanguage;
2 \* T% K+ ?: r- s; {  R" l        if current = @.Destination -- else return5 I" M( Y- r+ [6 W- B9 v0 Q
        then' o3 [  T. V7 }( B! K9 e/ p
                @.Destination := void;
- H$ E8 `% e' O9 h( e9 y                if @.occupied then! c2 d$ S% s  l  J5 P$ j0 {0 ]
                        part := @.cont;3 D- `: S* y/ b
                        @.transpOrder := void;" w( Y" X2 t) E  ^) u
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
1 Y) F* i2 D. X# }4 q7 K& q                                @,root.eventcontroller.simTime);6 |: L6 o+ m6 F5 X2 N, W' k4 o
                        @.HasOrder := false;
; }# Q6 I, p7 d3 W+ p/ b# t, n                        @.DrivingHome := true;" V# V3 ^' U& i) S
                        rgManager.tryToStartTransOrder;
' k. a* Z6 B: G                        if @.Destination = void( X" Z1 y# U4 L! |1 V
                        then -- no transport order for vehicle @
, L: @/ Q9 Q' k' G                                @.Destination :=9 a: i- a7 y( ?3 x2 L# y/ d2 w& @
                                rgManager.nearestFreeStation(@,track.~);4 `, M+ i$ l. U. ^( R4 M
                                newDirection(@);   
' A4 B/ n  f' `                                if @.Destination /= void then
% r9 d, a9 Y) I) l; l  o  c3 O( V                                        @.Destination.NumReservation :=! n2 n1 Y7 N, o8 D
                                        @.Destination.NumReservation + 1;' i# Q8 Q; z* v8 a+ x. p
                                end;
$ X4 @6 ]0 }$ z0 O3 L# u5 w& l                                @.CurrIcon := "drivingHome";
& N2 M5 l8 u! l8 j# l6 `                                @.DrivingHome := true;
& {4 w$ G" [( A) t                        end;, u# z' H; {" ?; \( @, y
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station* G2 W2 \' N; S% ~1 L
                        part := @.transpOrder;
8 @$ F5 L# _" G) e                        part.move(@);-- load part5 P6 v3 j1 @6 {, e2 c5 Q
                        @.CurrIcon := "load";
) o8 x- ^% I4 Z& i                        GlobalDistObj := part.globDestination;% F# \% ~! c6 O! y" F
                        assignLObj := rgmanager.rgAssignL;
( ~7 x3 U, I" T4 Y                        row := assignLObj.getRowNo(GlobalDistObj);
- I8 e. c6 ^5 [, K3 z" Y( B5 m                        if Row = -1 then -- since 70
3 ~5 H: ^; h, ^) `) R                                if lan=1 then' U& T, D' l7 y- u/ q) Y
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),& A4 `) e6 i( k: }1 _" T
                                                to_str("in der Andockstation: \"",?.~.name,"\""));1 Q  e; M1 j* `
                                else
$ ~0 _6 L9 Z3 c, x                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
# P1 C4 a6 y9 T, s7 S5 I                                                to_str("in docking station: \"",?.~.name,"\""));                               
% R! N; E- W9 A$ J                                end;9 ^4 t2 O) p1 ~( P
                        else3 K$ F6 B8 O& B# S7 |8 ^
                                @.Destination := assignLObj[1,row];; `8 b) N2 o, Z
                        end;                        / T2 T7 O+ z: W
                        newDirection(@);7 `6 f% p, f0 F' k
                        @.HasOrder := true;
0 \6 D8 g* Y5 E, Z5 U                end;; ^7 K4 g2 L, R& q! Q2 S2 R
        end;
2 [5 Z2 Y, Y# c+ A5 b! S7 }end;        -- of the method
9 g8 n/ ?$ R+ h
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 5 M, O( m- _; J. D1 N: ?; f

/ }3 h4 I9 E( Q8 X; i这是AGV_putin中arrive的method。
: B: g% R( H0 W0 n7 A, p9 u7 m/ i! M1 F# R3 A; r4 V
当到达物料速度越高时,这个报警更多,
/ Q9 L% x8 w$ W; e& \$ R可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
4 N4 }2 j3 j, P2 z% ?- d程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
) t6 p( f) D/ _1 V& f% h$ b# A# V7 Y1 O  `; O
另外一个小建议,就是move,所有的move都可以这样+ b6 L- B7 ?& U% A) u4 `* T# f/ K+ t  [
if not move() then debug end
1 Y# y. u5 q, y% E这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。& f9 d; Y, t# I$ [
plant simulation中的free libraries有AGV模板,
( f) K; F' g5 E+ j里面也有案例。
" C& p9 _& H; N2 P$ \  ^我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
; t1 D0 u( w- x) I' T# @" ~: }* q: n, P; H9 P+ W
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 & L! F" p5 p& ], W: y: C! l

! I) K: ^6 p5 {! \; Q4 i那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
4 p( B" e  Y  i' d$ b  p2 X( ^: S这是AGV_putin中arrive的method。
3 d% k' ?, W# z& s# W# }* n  w
, n* g  D; W+ _) q5 y当到达物料速度越高时,这个报警更多,

" a8 w. W; j9 y* J3 N4 B. p8 F另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-16 10:06 , Processed in 0.019786 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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