设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9131|回复: 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'
& b! l8 f5 ]& L. q) V*/
# \% D5 W5 E6 m3 t2 T+ x9 h. lis
, D" n: O0 o0 z: x% H# [- G# M        part, GlobalDistObj, assignLObj:object;row,Lan:integer;2 `. L$ I+ Z9 x+ H, ~( L' y0 M
do4 Q; ]# T: F6 h0 [
        Lan := rootfolder.Internal.Tools.AOLlanguage;
" f9 _$ l/ Q  E        if current = @.Destination -- else return; m' l6 s+ v  H# ]' o) n& w8 T
        then/ Q4 b, N6 ^% D* `% T" z" g8 G
                @.Destination := void;
& ~  z5 Y$ B. C3 K% U                if @.occupied then
  a1 p3 \; j4 G3 T1 J                        part := @.cont;
& M9 ^, y0 ^: ~                        @.transpOrder := void;
, a1 K" I, n" M4 E/ Y% s( F                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
: _$ n4 D% i. a                                @,root.eventcontroller.simTime);
9 K/ f1 ?1 I# I7 W4 ?5 }% k                        @.HasOrder := false;
+ `7 J) \( R3 b: V                        @.DrivingHome := true;
  G$ _1 B5 [( E0 L, T( ~! l/ a                        rgManager.tryToStartTransOrder;, [7 R8 @; I6 ?' ?. V: A1 W; O
                        if @.Destination = void9 C# N- F" d& N
                        then -- no transport order for vehicle @
2 s7 s. r# s% D, M3 M4 c3 ]                                @.Destination :=
, b( p$ z& a2 O3 O: K                                rgManager.nearestFreeStation(@,track.~);
7 N' j( a  X; N8 n2 U# }: o                                newDirection(@);   
5 c* J0 A3 b) i( M% R' S4 Q                                if @.Destination /= void then, `6 ?: m; w" k
                                        @.Destination.NumReservation :=( Y- ~7 M$ i* L: l7 \! Y
                                        @.Destination.NumReservation + 1;5 @1 Z8 z4 o, s$ D0 P7 b) {
                                end;9 s- b9 u$ _  X8 s9 i5 E+ b
                                @.CurrIcon := "drivingHome";6 w3 B. {% ~; w- t" K
                                @.DrivingHome := true;
. ~) i' t+ u: s# X9 g: X/ J                        end;
. e9 g) x' F, v' U' V1 J7 h                else -- the vehicle @ is empty, both vehicle and part are in the same dock station2 S" j9 A" @' e
                        part := @.transpOrder;9 y/ P! m* C7 p2 C: |$ I) X
                        part.move(@);-- load part  p# u7 B# A$ w
                        @.CurrIcon := "load";
' q% i; d) Q1 c) s9 G$ ~                        GlobalDistObj := part.globDestination;
: f* |; ]  {% _& w5 g7 l5 P                        assignLObj := rgmanager.rgAssignL;
9 C; b# K" W( @' J% v! h  o- N! K$ A" s                        row := assignLObj.getRowNo(GlobalDistObj);+ u# q5 n% f3 O7 D- S- F
                        if Row = -1 then -- since 70
2 m0 _! Q  ?9 D9 G/ b' `  Y                                if lan=1 then
# s$ c" P/ E* t1 b) r3 e. a                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
7 b% `) j0 \1 U) ^                                                to_str("in der Andockstation: \"",?.~.name,"\""));
  g. s2 }0 @' W) b# P                                else: a5 Z& i9 ^' b5 r) `. _2 O- ]
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),: O2 \/ x, |( Y, n6 b
                                                to_str("in docking station: \"",?.~.name,"\""));                               
7 h  @8 s: c, S2 I                                end;; C; `! Q* b0 _
                        else1 L4 ?$ d6 ^. c6 c% a5 v3 b2 [
                                @.Destination := assignLObj[1,row];
2 u( w. ?) c1 h, s& c3 p                        end;                        : c$ H7 f" g* }
                        newDirection(@);# `8 ?- x' c) f# v, Y
                        @.HasOrder := true;" I. r+ p2 j5 ]: M
                end;
9 O2 Q1 I; ]0 V& O: h3 }+ a# c        end;9 R2 r0 Z& W& e! V
end;        -- of the method
$ K* L/ Q0 [; b: p
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 * R' d+ `, }6 s( M3 }8 }

2 f' t' f, A8 D2 _) s9 K8 ?这是AGV_putin中arrive的method。
6 ]( Q' _1 e+ K1 V. ~4 }1 M2 a7 M" m: M2 ^0 l7 r  G9 j6 G0 c  [4 b
当到达物料速度越高时,这个报警更多,
5 z# N3 N. x. A8 j# B可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
7 ?  H2 @0 \) s+ J9 J( Q( Q# z) @: G程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?/ [' {( n7 E* I+ [! _! q; @
; r: h0 Y, [; G0 w
另外一个小建议,就是move,所有的move都可以这样( _( B, l, |& ?# B
if not move() then debug end
* G' P  b' l0 g& |, g' u3 i这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
' d: l. m) J$ A8 W: A( w$ gplant simulation中的free libraries有AGV模板,
, h( r: |* d# \7 k# l9 |& z里面也有案例。
/ K4 C, b0 K% X  `4 W我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。0 X* y* \2 M5 d$ ]. n( ]
% r' \; n. U% i! U# [7 _
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
( i( p( e( A% p7 G% Q- }# \- ], s  P" M2 j$ Q- O$ k% c. I
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
( q, \; o7 f- j这是AGV_putin中arrive的method。# a/ ~" T$ d) C& q' |
3 Y. ~4 k2 x, \: z
当到达物料速度越高时,这个报警更多,
& s% P$ S$ Z1 `8 F' b
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-15 13:28 , Processed in 0.018721 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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