设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10144|回复: 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'
8 |: e8 M* Z/ S/ R3 U: l*/* V7 i, Y( M; d% a  P4 i
is- q0 o# K- O+ P/ N
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
% z3 e+ X- c: z+ [0 ydo" r: ~0 s  p* W: ]9 \. y& t# D8 N
        Lan := rootfolder.Internal.Tools.AOLlanguage;; I  z; K  n6 U2 L  w3 }7 h8 l) }
        if current = @.Destination -- else return/ t% d( i/ Z; Y  k9 |. j1 Q2 J
        then
7 S0 j" n# Q9 N. r+ ^1 a5 @7 A                @.Destination := void;. p8 j  {  _5 F% m* R0 M2 ~
                if @.occupied then' t1 C  J: t  @
                        part := @.cont;6 F7 d" R0 x) l/ N0 X8 S5 e
                        @.transpOrder := void;
" i# v* k$ F- Q9 r: H7 @4 r                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
) `3 {7 \6 v5 L1 c2 J9 J7 h                                @,root.eventcontroller.simTime);9 D" ^0 ]6 D, ?, E
                        @.HasOrder := false;
& i3 x) b( C  s$ {$ g1 ]                        @.DrivingHome := true;
% y& g( V' p# ]" U2 T6 ?                        rgManager.tryToStartTransOrder;
/ L. r- p% S2 _; t9 r. g                        if @.Destination = void5 Q& z: o7 B, R* X1 @( {" p5 Y! S3 h
                        then -- no transport order for vehicle @3 b4 Q1 g+ M# W( d) s
                                @.Destination :=
3 F' l: h0 W- [8 b                                rgManager.nearestFreeStation(@,track.~);
! S( a( J, q. m5 K5 a5 i5 t                                newDirection(@);   
4 V- ^- k; ?5 q                                if @.Destination /= void then
; s, C0 t, }2 i7 L                                        @.Destination.NumReservation :=
$ G. U$ U4 b: B% k* Z$ [# |                                        @.Destination.NumReservation + 1;
; C% @$ [$ o/ A3 U' \                                end;
' X7 u9 l# b- Y# _4 ?, }- V( ]                                @.CurrIcon := "drivingHome";) A! W9 e2 s' e" I1 V/ p
                                @.DrivingHome := true;
0 r  x& r! ^2 [$ K; X+ v                        end;/ g, }- s  H- L1 f1 H# G  V
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
- P9 H' n' ~: I) E. V                        part := @.transpOrder;4 c, v- v; p+ G+ f. ?
                        part.move(@);-- load part
8 g: u; t2 u! M! @7 o9 V* \  M                        @.CurrIcon := "load";
! d& ^# e6 B' Q7 h1 E, H                        GlobalDistObj := part.globDestination;
, p* H5 t" P5 j$ l                        assignLObj := rgmanager.rgAssignL;
* h- ]6 L6 t, j7 k' g$ I1 g                        row := assignLObj.getRowNo(GlobalDistObj);
2 R' n5 R5 E7 ]9 w                        if Row = -1 then -- since 70
7 }- N/ N4 x2 x                                if lan=1 then' B$ l, I) P! f2 I. {: v
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
" z, E9 S, {& x                                                to_str("in der Andockstation: \"",?.~.name,"\""));9 d1 T9 E2 J( e; y+ \1 _  ]
                                else
6 B1 {7 z$ y2 Z/ d: `                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
# m4 S4 k: N- u                                                to_str("in docking station: \"",?.~.name,"\""));                                4 B% o& N7 \  f( h, d) {
                                end;
! [- ]' e! [5 c7 x                        else9 l# P; }1 N, \
                                @.Destination := assignLObj[1,row];4 l7 Z0 G- p4 h) v7 a8 e7 c0 B
                        end;                        ) k4 @# S& K. M* J" ^  E! S
                        newDirection(@);
) i' l- ]( T! l                        @.HasOrder := true;' {" T0 o/ W/ `$ [9 f
                end;
4 h$ _' a# K- n( K        end;
8 ^( q+ Z' U$ q. [) [end;        -- of the method% ^$ q) T9 s+ a1 S/ ?
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
2 C3 d$ p0 l; ~8 v# T2 E1 b# Y1 ]) q( V7 t
这是AGV_putin中arrive的method。
9 t) E" I7 q  z; V, r
- v& c3 N- I- N1 X. J当到达物料速度越高时,这个报警更多,3 c  ^% S1 q, y; @; u8 M/ }* [
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。7 ~5 [8 a  S8 X: D
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?3 k9 ?! @: f( b3 C# B: U# r4 \

% X- Z' e* Q1 [2 u% ?9 e) s另外一个小建议,就是move,所有的move都可以这样8 A/ P- h5 D9 x! q$ D& y
if not move() then debug end! z; A9 F- L% E0 ~8 h3 n/ F" V7 [
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
2 y! b: H5 ^& m8 fplant simulation中的free libraries有AGV模板,
6 A; Q6 E5 @/ J: h里面也有案例。5 o3 q4 s9 T4 q$ v8 ~
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。3 C7 R4 @. I3 a" o0 y
- l' U2 p% _( s5 r! C/ h9 n- O3 h: F( A
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ( ]6 J6 \, f9 _& w2 S1 W0 E- Q: ~" ^
9 x; o  M& T3 R# u8 l, C& a' @
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 5 I- \+ M4 g% s  H  F0 k1 W
这是AGV_putin中arrive的method。6 ~* b+ b' o% q! m8 }( F, [& W
8 O5 S5 D" }2 V% \
当到达物料速度越高时,这个报警更多,

6 D9 _7 Z3 n# a另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-15 23:41 , Processed in 0.019919 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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