设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9764|回复: 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'# \* C; G( {9 ]( a
*/
8 E' W" @& P+ ois
2 m/ Z. z' {+ W: ~. m/ Y        part, GlobalDistObj, assignLObj:object;row,Lan:integer;6 r" D1 r  E5 r( [5 n+ m
do
( z8 ^! m: u7 f$ U! Y0 o        Lan := rootfolder.Internal.Tools.AOLlanguage;
" o7 ~7 O: \3 e& b        if current = @.Destination -- else return
) j8 A/ |% T9 Q3 A/ R        then% e8 q0 W7 ^4 q3 R) f; n3 w& P7 E
                @.Destination := void;
2 J+ V6 i" a2 p/ t8 t. P: V4 s                if @.occupied then# J5 z# P( x+ G. D  f: w
                        part := @.cont;
) V* t, H. H4 v                        @.transpOrder := void;
# w2 f8 j$ V& E+ F" W& n                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
: y! Q! T0 ?; L7 p, N$ T5 d2 g                                @,root.eventcontroller.simTime);8 f" B: ~5 c$ d! e# Z! C
                        @.HasOrder := false;8 ?) L: Y; [7 X: t/ }1 D
                        @.DrivingHome := true;
5 s! i: H) w3 }                        rgManager.tryToStartTransOrder;: z! Q( u  @6 ^. E! n6 Y- k4 G5 C3 k
                        if @.Destination = void
; e$ w: I7 ]) y* n3 [# l% p                        then -- no transport order for vehicle @. Q2 q4 T7 H# c& i# Z. o
                                @.Destination :=
6 s5 ^8 }& |) {; B3 e                                rgManager.nearestFreeStation(@,track.~);# S/ d9 ^3 X% X# g- f/ g$ x0 }
                                newDirection(@);   
* B( L7 ^) t" O) D" x                                if @.Destination /= void then1 ]8 L( @- d, M  N" j% p1 [
                                        @.Destination.NumReservation :=' Q6 B+ P& X4 w& I
                                        @.Destination.NumReservation + 1;
. z8 O1 @" x& d, d; U5 Y* u( |7 v% I                                end;
* G$ q+ e5 ~' y; j7 t' l                                @.CurrIcon := "drivingHome";: }' v* {' ?1 K3 k' H2 A, |
                                @.DrivingHome := true;. p; ?8 |* C) z
                        end;
$ a  Q9 E9 c4 M6 D                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
6 S( z: j& p4 I. L5 r( j                        part := @.transpOrder;; {0 E! `# s! f3 Y' b& o
                        part.move(@);-- load part
4 K  m9 [6 f+ ^  F  |                        @.CurrIcon := "load";
% o" s- f  u3 K: s                        GlobalDistObj := part.globDestination;
0 D, ]; t% C7 D) h( q+ m! R4 J* D                        assignLObj := rgmanager.rgAssignL;# n0 j) h5 ^3 g3 z4 S
                        row := assignLObj.getRowNo(GlobalDistObj);) X: k" D1 [7 p
                        if Row = -1 then -- since 701 F2 H5 T! O: o' i' Y3 W
                                if lan=1 then. ^0 `& N4 B1 J1 Z; O/ o# Q2 `7 M2 L
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
3 H  L% O/ u$ _5 ]/ ^! j                                                to_str("in der Andockstation: \"",?.~.name,"\""));
' a- l, x4 ~1 `/ ~5 j8 t6 @                                else: K7 ]+ C& a- \: f
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
- P( O# r! ?6 L                                                to_str("in docking station: \"",?.~.name,"\""));                               
4 J1 m& k) Q+ w. M, q: G! ?                                end;. i6 g. k" q7 S2 W+ {9 F
                        else
. D) u9 s* s. @! h: m' v- W                                @.Destination := assignLObj[1,row];, g6 w" E0 C+ }" t( l$ c
                        end;                        1 A3 q4 N5 }; }; {
                        newDirection(@);
5 y, H) C1 S/ O7 A                        @.HasOrder := true;" R: y' P6 p4 e* b& z; |' L
                end;7 i; Y# N2 }8 D: l% e
        end;' \' ?+ v- g; I' u7 ~
end;        -- of the method
4 G7 `& h3 P* H; D0 \- r
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ' p3 _5 e% @$ O2 c5 M& Q3 p
; ^2 V( v- c8 ]" `6 x4 A
这是AGV_putin中arrive的method。
0 Y/ \0 P, _, Q$ @3 c  q" H& z. [  J7 Y$ _
当到达物料速度越高时,这个报警更多,8 ]2 m7 B6 p! W9 B
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。: I/ u2 N; f, b- Z
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
+ V; P! `: ^! |3 G! h& X2 f! e6 l- v8 e
另外一个小建议,就是move,所有的move都可以这样( o4 l3 A3 [: q! M9 y2 S
if not move() then debug end, h3 \+ u! X8 c0 p' F% E
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
( [$ H: E2 U$ L7 Iplant simulation中的free libraries有AGV模板,  l: n# W  k  ?
里面也有案例。
9 l3 ^8 y7 C% E$ X* a( z我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
! ?( z( h0 k6 X# L4 N0 @- F( D! R+ p1 E" M  H8 U4 q
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
# c; Q" {" s2 U0 a) i* R
/ N. g! h# }! Y+ L那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 : t$ e9 w9 w) f! J1 H/ S) d. V
这是AGV_putin中arrive的method。& `# X  c" x$ t  F

# D0 h& U& i+ Q: s( r4 W1 F' ~! O& H当到达物料速度越高时,这个报警更多,

9 _% K: p7 _! L  C另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-23 09:28 , Processed in 0.021080 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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