设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 4415|回复: 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'
1 m3 i1 H3 _. T8 [*/# X8 V0 m' \9 |+ Y/ \! J" J, m
is
6 M( G) {3 ?% w6 @. p6 {        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
) G8 r# U2 o% \* Mdo
6 B( Q  Y$ N" b* A: K        Lan := rootfolder.Internal.Tools.AOLlanguage;) _5 k+ ]. K( H) I9 s# H& g& D4 `
        if current = @.Destination -- else return
& {% ]& B2 @& `' i  H- U# z5 j+ E        then
4 X! p  F4 i4 G$ J: B9 L9 {: N                @.Destination := void;9 V; z( N. U( p; u4 c( J5 S
                if @.occupied then
/ E7 C8 v9 {& X; a  z# s  T                        part := @.cont;
5 J' f2 }- e9 @  M) K                        @.transpOrder := void;. D! ?3 g: w- {% C
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,( \9 X4 p  z" t, }- ?& y
                                @,root.eventcontroller.simTime);; a: [/ L# H0 v1 J: U- i1 ^
                        @.HasOrder := false;3 ~9 v; C5 g, ?0 ?0 g4 V
                        @.DrivingHome := true;
. L* X- i5 F7 Q7 N/ C; o* ^                        rgManager.tryToStartTransOrder;2 [& s* T+ e; k& V; H; H. a% Z
                        if @.Destination = void
6 c, ]/ N6 ]1 G; t6 A' v7 U                        then -- no transport order for vehicle @
; k! V6 G5 L8 P! v                                @.Destination :=- b3 H  q' V( `; a% r
                                rgManager.nearestFreeStation(@,track.~);' k: C! C' G3 c
                                newDirection(@);   ' ?3 ~- a" M" B
                                if @.Destination /= void then& |6 `# t: n3 Q* `4 Y
                                        @.Destination.NumReservation :=4 q6 J: d! u9 x$ T- V
                                        @.Destination.NumReservation + 1;( ~7 M8 w: L, I4 g8 s
                                end;
, C8 u% P- A( ?/ i7 |% T3 J                                @.CurrIcon := "drivingHome";
7 g2 o) Z5 G5 q* [& b; g                                @.DrivingHome := true;
( A" s- a5 ^/ V: R                        end;1 m, L9 e4 Q5 \  L- j- Z
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
. M9 Q, d4 S3 ^, D5 {                        part := @.transpOrder;
/ D, [6 o! F5 Y! `% k  G: p                        part.move(@);-- load part
7 B# N9 @6 x3 f5 ?                        @.CurrIcon := "load";: C! k  ?2 }5 o! T: a
                        GlobalDistObj := part.globDestination;9 k5 O3 @4 _2 F9 s- j9 U& h. K
                        assignLObj := rgmanager.rgAssignL;
. R& f2 t& F2 J0 L7 _                        row := assignLObj.getRowNo(GlobalDistObj);
9 M- P( r1 `9 ]) ]  C2 ?* {                        if Row = -1 then -- since 70# R# f- |" \2 h. C9 _
                                if lan=1 then
0 x" t8 ]+ H) L5 W* C6 Z                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),& s1 m$ H$ h. j2 x
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
2 G% J/ K, M' n* d                                else" z7 f5 g9 S. v+ W  d( v9 C
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
( w6 N2 G+ y+ s5 e6 j" W" b                                                to_str("in docking station: \"",?.~.name,"\""));                                9 f8 N! n) K* }; g  L
                                end;$ Q3 B" J6 r% w( n( a
                        else- K: D9 s! m4 X
                                @.Destination := assignLObj[1,row];1 Z: t/ d% ^9 ^9 a) ^" M8 R* T+ i
                        end;                       
* o1 @) L% X5 K5 R9 t# k                        newDirection(@);6 t; b. U( L6 Y) [7 k
                        @.HasOrder := true;
4 Q/ `  D! ~) e6 J( T0 D( M                end;
- ~# s% V, ?3 L: B! ]8 N        end;( l* r8 A* o( f- K# m1 q. Q  Y! K" l6 a
end;        -- of the method, K9 }+ V( i) ^8 M
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 0 Z" ~! h) _7 C  Z9 q0 D7 O. n+ ]: B
3 l  v- H& |+ I7 Y. ~6 A% M
这是AGV_putin中arrive的method。, f- w0 D6 d# l3 x1 y; _1 ~
& r7 }1 \, E: ?0 W
当到达物料速度越高时,这个报警更多,! J$ t' Y; B  {! M
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。& e, K% x. x5 g$ _
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?$ [$ O4 s" F# w# p

% ]( O  X. K  l/ a  `& K另外一个小建议,就是move,所有的move都可以这样) I7 X# I  Q2 d- P# S
if not move() then debug end( A3 v8 ~; T& U5 K* O$ C, H
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
# E6 r6 ^' w6 ^+ n0 `plant simulation中的free libraries有AGV模板,' W; i4 v7 F, T! o
里面也有案例。, S5 v; C8 z1 z
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
/ H9 X8 e9 Y3 c* b- V0 }) I1 d7 d& o" n, Y& O; _4 _! }3 a
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 . @0 p, f! o( N
5 e5 ^$ _# `* q
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ' b# s3 H* ?' `; V. ~
这是AGV_putin中arrive的method。" W& d3 M6 u# H+ r& R
" p8 g& Q( U% n$ i! `6 o7 y
当到达物料速度越高时,这个报警更多,
+ J+ b2 U% a  Y- q
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-5-12 10:41 , Processed in 0.019328 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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