设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7805|回复: 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'
4 M, t8 L" E6 f/ m! k2 Z! L- B*/
; T+ S: T. |( ?/ W5 o) T0 N8 Lis" A$ l% q+ a7 X) t3 q' |
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;$ |) }, e8 b  l, w( H" t# i- H4 E8 X* d9 G
do
3 u/ C! N+ Q+ V) K2 J% N        Lan := rootfolder.Internal.Tools.AOLlanguage;
; H1 ]) P3 o# r( V3 V& C9 S        if current = @.Destination -- else return! S9 ?" ]# d9 @* k- G
        then
: F  k% o$ p# E# z/ @. ?( D: W                @.Destination := void;! @7 V" D! n; a
                if @.occupied then
0 A( T3 @% _8 k+ R9 Z( v3 C                        part := @.cont;
7 i" _+ |" H3 b  a! A  h                        @.transpOrder := void;1 `6 D2 z/ \; e& J
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,2 o% p. F: ^* G% n# z) j6 j
                                @,root.eventcontroller.simTime);
' m. N' d- `& P- n- M. \  g                        @.HasOrder := false;5 f, e1 I( s! s+ L* B; s) |
                        @.DrivingHome := true;0 n4 P! h( p  Z: _9 w5 C6 F2 b1 _+ c
                        rgManager.tryToStartTransOrder;/ y+ T$ o! n" J/ U8 K$ w
                        if @.Destination = void
; J! }) D- s7 b# n6 h                        then -- no transport order for vehicle @
8 m3 f$ ~' J6 j3 G                                @.Destination :=
. J/ g1 J  C+ |! b* ~( i- w8 |- g                                rgManager.nearestFreeStation(@,track.~);
9 G) O8 i4 ?0 ]; D* t. @                                newDirection(@);   2 k" A9 C, K; A, L9 _9 s* Z" S' f
                                if @.Destination /= void then
) M9 {$ s4 ]" M9 C% p                                        @.Destination.NumReservation :=: {2 T9 k4 T& r) w; E
                                        @.Destination.NumReservation + 1;/ Q9 }9 z; _$ {; y# B
                                end;
3 {$ @3 R- ^4 K- Q                                @.CurrIcon := "drivingHome";' a# Y" C9 x5 z" d/ [3 ?0 Z" q
                                @.DrivingHome := true;
$ p7 J1 {9 o/ M0 t- s: }4 E                        end;
- @( z8 M& n! X& \' b                else -- the vehicle @ is empty, both vehicle and part are in the same dock station5 F# R6 a8 M+ O1 b+ U
                        part := @.transpOrder;
* G9 N5 G1 z0 O2 k                        part.move(@);-- load part
2 S- @9 Z: d  \# b5 I                        @.CurrIcon := "load";  P* l9 e) ~  |
                        GlobalDistObj := part.globDestination;
7 I7 t2 Q7 f- P# S                        assignLObj := rgmanager.rgAssignL;
, l- F+ ?' k1 E: W. k3 ?, t                        row := assignLObj.getRowNo(GlobalDistObj);9 }: d4 `# V6 }$ h* h& }2 O
                        if Row = -1 then -- since 70
( u/ B! n$ C, K& S4 x# `" Q. h- N" P                                if lan=1 then
" I8 }, }# Q- v6 }                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),8 r+ B* m9 a+ m- ]
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
7 w9 U* J: b5 V" H/ l* K! T+ x3 b                                else
( `! ^4 v( ]. M, ]; Z8 A+ T( \                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),9 M0 V, p! r& [1 X5 N% K5 {
                                                to_str("in docking station: \"",?.~.name,"\""));                               
9 T+ J% a5 D( z5 I' |                                end;( t2 X9 \% h$ l9 b
                        else" U6 \5 _& g' t/ Z6 k1 M- T. j
                                @.Destination := assignLObj[1,row];
+ ?+ r7 ~/ k9 g                        end;                       
. z0 u1 X: Q4 K, E                        newDirection(@);/ {, e" X) s7 r# z
                        @.HasOrder := true;
* ?1 _+ t% D  z3 @4 M, I1 [. r                end;. c7 U" b1 |& d( @# }; o0 W4 e
        end;% e1 C- z% b+ Q6 {
end;        -- of the method
- L" v9 I! p# k  b* z( B/ g
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
2 Q+ a+ b- r3 Z+ C0 ]7 s2 z; u0 V$ L/ o6 B3 K8 ^/ o
这是AGV_putin中arrive的method。2 \2 L! \- ^! x7 F/ b
1 ^$ ?9 m. A, M% n
当到达物料速度越高时,这个报警更多,- ^( G7 K$ r$ C& ]8 y$ N
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。" a4 B4 `( p6 N0 V
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
7 W0 v4 C' \) c! Y9 t& h. o
5 J6 j8 _9 ~4 P8 `! _. r3 D另外一个小建议,就是move,所有的move都可以这样$ p) u/ G' z: L, ?/ l0 T0 q# N- e
if not move() then debug end
- G8 ]# `% w8 d- B- \" E这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。6 w) F; t; Q# M$ T
plant simulation中的free libraries有AGV模板,* r( F; }; E3 a7 e- z$ h
里面也有案例。
: S$ l9 }8 X) o3 e我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。% W/ w9 G  _, @" s

+ N( }3 X- J+ |我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 - q, e! _$ O: l4 h* i
! O" p# B* c# R% K: P
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08   d0 E& I. k# V0 a* ]8 U
这是AGV_putin中arrive的method。9 P* p+ x' W5 Y1 H; j0 C  A( n

( s+ b) h6 F8 r2 R6 J9 V  Y当到达物料速度越高时,这个报警更多,

. a4 o  {- S6 R+ \( S, D" F# m; f1 C另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-29 20:53 , Processed in 0.016652 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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