设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8309|回复: 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'- b6 i' F2 k9 e  }
*/' q1 v9 G$ {& R5 x# d
is
$ F1 ^  l1 P& t' [: x! r" }" U        part, GlobalDistObj, assignLObj:object;row,Lan:integer;! _- G4 Z/ y( o9 B, |/ Z) Q
do0 X: e; D; U$ i2 ]3 v8 {' d& ]
        Lan := rootfolder.Internal.Tools.AOLlanguage;
7 u! K. L0 Y" a7 v/ t! H2 \        if current = @.Destination -- else return: k. s, X2 Z9 y( ]% D* M1 w5 K# a5 p
        then% f0 E! @! G: b' Q) t# K! p
                @.Destination := void;( v! r4 y" K  a7 _$ a
                if @.occupied then
8 t5 _+ I: }9 i/ d                        part := @.cont;( T, l1 S0 A, P% _9 F9 ^
                        @.transpOrder := void;
* C# F2 t" x( d# n5 v4 E0 P                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,' y: G0 b3 ~) X, v' E7 r
                                @,root.eventcontroller.simTime);- J3 Z! j& |& v. e2 ^
                        @.HasOrder := false;
: V  \6 Q! Y, O  D: s                        @.DrivingHome := true;3 ]9 j+ `+ L5 `" `
                        rgManager.tryToStartTransOrder;
# u- H; ?0 t- p/ \/ }                        if @.Destination = void
7 Z4 n; r( P* x- `6 R                        then -- no transport order for vehicle @+ J, Y3 p# `( g
                                @.Destination :=
) n+ H0 N5 a; e5 p) ~2 `" P/ ~                                rgManager.nearestFreeStation(@,track.~);) v: {' ^9 A0 I4 r; K4 I& n
                                newDirection(@);   
* f" T2 w' y9 h6 [, H  h+ E                                if @.Destination /= void then
: A" ~3 @" ^% c) J                                        @.Destination.NumReservation :=
6 G" R" q- p* I7 J: d                                        @.Destination.NumReservation + 1;7 _( B$ {+ v# \  J8 V0 c+ @
                                end;6 G/ c4 r( s  h6 _
                                @.CurrIcon := "drivingHome";2 T5 |" p& x; o- _$ f) u
                                @.DrivingHome := true;
% N& u: i& X+ T9 w$ h6 P( v8 d                        end;
" K& _& J# A8 |/ o) _                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
5 j9 {* |+ X0 S1 e                        part := @.transpOrder;
/ f) T( @6 \: w) a                        part.move(@);-- load part4 o8 t$ ?6 @! {& w6 m/ [# t
                        @.CurrIcon := "load";  H& j9 l9 e* G
                        GlobalDistObj := part.globDestination;. W3 x8 o7 @0 F% T1 Y
                        assignLObj := rgmanager.rgAssignL;' e2 \* Q& u5 W: C) F+ y
                        row := assignLObj.getRowNo(GlobalDistObj);* D/ _$ B& N7 T3 F4 T. f
                        if Row = -1 then -- since 704 y9 F2 T  r/ v
                                if lan=1 then3 E- ?6 a: `6 `( i" \4 W
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),7 ]! f1 a3 I" a/ ~7 G
                                                to_str("in der Andockstation: \"",?.~.name,"\""));) C+ {; X/ r7 g) S: S! K
                                else' G3 U4 {+ r' Z
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
/ h% n8 U/ [' U2 `6 l* f- N                                                to_str("in docking station: \"",?.~.name,"\""));                                ; f" P$ K; z( |) p2 Q9 ^9 p1 X
                                end;) c  `" k. Q2 K  \/ u' f* n% S
                        else
) W( z* v4 X9 O% B  ~                                @.Destination := assignLObj[1,row];
$ Z( a( P# n: c. M                        end;                        1 Q1 V4 b1 t; q4 y2 Y- z
                        newDirection(@);
- q: t/ U) _4 W, B, Y                        @.HasOrder := true;
9 P3 {! t/ j9 J8 V* T4 ~: n                end;4 K2 k! Z) k' f5 o5 C+ R* d
        end;
1 v8 k. I2 q  [& Wend;        -- of the method
( o7 N) l2 v! ~& d" C" s/ v- Y
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 4 A) J  K( N# W" I

' W$ ?  R# s* z这是AGV_putin中arrive的method。
  D3 z$ C. T) J3 L# ]1 e+ t0 i, G) y9 g$ I) U$ U1 Q0 S
当到达物料速度越高时,这个报警更多,8 |, O! O0 x. ]- i( ?2 i+ \
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。( C+ Z+ |+ I" _9 Z+ Q+ @3 l" }7 |
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?* P9 ]' r8 o/ Y. `# v: i
. b/ I5 R+ T/ U$ @* E! m
另外一个小建议,就是move,所有的move都可以这样
0 p! S1 A. Y! N! |. Y- @; ^) Eif not move() then debug end% S) h& g" P: [! D# B
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。; _- p  R+ o9 S+ M3 R  I# s/ T2 g+ c
plant simulation中的free libraries有AGV模板,
' N4 R# R! v. `% G0 |里面也有案例。
. E2 g$ d- _/ o' v; Y我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
4 J9 Q  Z( Y# D- d9 T  I7 g) ]6 h: A6 ?. M  v
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 5 {9 v6 L9 |4 }4 p; R

/ s" g& F$ h; S: e! [  B那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
' @, z) ~( ?' \4 ?4 g% F4 c这是AGV_putin中arrive的method。
3 f/ `1 G; y( V1 V# o+ |' k9 M2 d# y1 X9 r/ ~, U
当到达物料速度越高时,这个报警更多,

" C/ h  D" |- e# U# J另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-27 01:28 , Processed in 0.019836 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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