设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8607|回复: 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'# f7 `6 V0 a2 A1 E
*/
& D- T( \- p" M# @is0 e  T, d+ B1 F
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
* T" V7 e! K6 n3 U  b8 mdo
: \/ Z4 Y6 C6 T2 l* D  m        Lan := rootfolder.Internal.Tools.AOLlanguage;- ?: I  l) |( K  B# P) _
        if current = @.Destination -- else return
2 n! b# z2 }2 c6 Y        then
9 m: A3 d; ?% E* e                @.Destination := void;
" v% x2 f, |9 @/ {, a3 U# U  x6 G                if @.occupied then4 ~$ R5 G8 d0 ?: K
                        part := @.cont;9 @- [5 }( K& m* b* `, j, {2 l
                        @.transpOrder := void;
( M: j  |& {+ R: ?9 m                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,/ X. u/ d% x- C$ F! U7 m  o
                                @,root.eventcontroller.simTime);
( O4 C3 r; s1 |7 b3 U: v2 q                        @.HasOrder := false;  ^! n3 L: d% t( N' n
                        @.DrivingHome := true;
. a2 s" ?+ M4 X! l  U6 L                        rgManager.tryToStartTransOrder;
( M2 v. d) [# b+ v8 p' v                        if @.Destination = void$ U/ f' T) f2 J! V" B9 ^, l4 W
                        then -- no transport order for vehicle @( D5 ]( G( @% R. E% O6 D
                                @.Destination :=% b1 O4 y$ R( Z+ \; I# z8 B
                                rgManager.nearestFreeStation(@,track.~);6 Q9 ^1 \4 ~) M3 d
                                newDirection(@);   8 W9 e" G0 V( q. p& h0 Z) F
                                if @.Destination /= void then
; ]; H* w9 O6 H; j                                        @.Destination.NumReservation :=
" [9 [9 q! K  N7 D9 o                                        @.Destination.NumReservation + 1;
8 |3 h( z- L4 v% K                                end;+ d1 r" U' l& E/ h
                                @.CurrIcon := "drivingHome";( I! G, r, E! U  |- o! j
                                @.DrivingHome := true;' I4 t: O* H% L. X3 E) k
                        end;
5 s; w' h" S  q8 i4 v+ P2 A                else -- the vehicle @ is empty, both vehicle and part are in the same dock station. z9 k1 [; M) P- u
                        part := @.transpOrder;
4 B/ `% P+ y+ G4 T$ E7 f2 n0 J                        part.move(@);-- load part
4 o% q/ Q/ [5 L) W. j& [                        @.CurrIcon := "load";
8 A0 j1 K+ F3 e6 j                        GlobalDistObj := part.globDestination;. }$ i# `3 R& F/ e: J
                        assignLObj := rgmanager.rgAssignL;
* c/ i0 B; p+ @9 s                        row := assignLObj.getRowNo(GlobalDistObj);4 U' }" B. V+ u  `' \, A
                        if Row = -1 then -- since 70
# e$ O# i7 a) k- u                                if lan=1 then6 h1 K0 N! i& J" N0 C* t4 `
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),+ P" ~# v" L7 ^; s% z$ T3 ^) x
                                                to_str("in der Andockstation: \"",?.~.name,"\""));& A+ e; g* C2 c8 u7 p
                                else- b& w' H1 @6 v0 P- a( L
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),/ g4 p9 x1 A( \/ E/ J) C
                                                to_str("in docking station: \"",?.~.name,"\""));                                + w! }  x8 G$ M# l# h
                                end;
* Y- I( {9 W: V% W" `. @                        else8 L% J+ D1 v% x/ h% V
                                @.Destination := assignLObj[1,row];
1 \! }) `2 s! Q8 Y. o                        end;                       
0 Z8 i3 p7 |! c- b5 V                        newDirection(@);
% P) y% }( u! h9 g9 n                        @.HasOrder := true;! r  k! g" P+ v) C) {. F- n
                end;
. R( x4 A' \, h! }+ S% L' L4 y+ w        end;& z* G0 F% q0 y7 c. k7 N* M3 ^
end;        -- of the method
% @. u  O  p$ n1 I! m
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
9 i# [% z0 v5 A0 Z; R$ W. ?9 x3 v2 @+ {
这是AGV_putin中arrive的method。# [$ c6 `1 K9 A* Y6 h; m
; x- R8 Q/ {3 y7 L9 y$ A
当到达物料速度越高时,这个报警更多,  D$ F7 D" T$ p2 }* {
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。. f- M3 U* Z* k, x9 j
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?. x* @: z8 W5 s5 }* U

; V0 Q7 @2 ]4 b$ U: ?  V( C' f另外一个小建议,就是move,所有的move都可以这样& _) ^0 e0 m( M( F% O) n
if not move() then debug end0 r: `# U" G8 z
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。2 P9 h; B8 T5 N
plant simulation中的free libraries有AGV模板,
% }* M( t" m5 D/ y里面也有案例。' j0 Z# e# \1 U1 B6 |: Q2 X
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。% M& B4 j8 u  S* `3 \% @+ R
6 ~& d; O& d- b! P3 _, N4 a2 ?5 `" C
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 0 [/ @/ x# J6 c" e
+ K! w7 ~* E5 X( m/ _' z# y3 \
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 . K, b" {5 g* X
这是AGV_putin中arrive的method。
3 n6 d5 }% V' t* a; l- k
0 B' d1 C' o# s0 U- L  ]( A当到达物料速度越高时,这个报警更多,

( d& D; f, l' y6 W  |# I另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-15 09:42 , Processed in 0.016831 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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