设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9187|回复: 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'
+ ]: _$ a2 n1 L& j*/) \( f$ G& p: @0 u
is
: h; x# M8 {- U# v5 `- E        part, GlobalDistObj, assignLObj:object;row,Lan:integer;8 }  B$ |# f* V+ c1 S
do
) s8 A+ E% b: D* f3 `# l6 V8 i3 J        Lan := rootfolder.Internal.Tools.AOLlanguage;* a" O; h+ F' W$ e3 I
        if current = @.Destination -- else return! s6 g. X% j8 \8 E( i5 v
        then% D8 t/ [' m( p2 S/ m3 s
                @.Destination := void;
& ~4 x9 j9 r+ l4 [* W                if @.occupied then+ h, o# o4 g6 A& P* o0 w
                        part := @.cont;
2 k4 I1 O  f" i" m% m- l7 u                        @.transpOrder := void;
; j4 {" ^( A" j  G% g. A3 h                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
; x/ S7 [! m( s8 Q* y                                @,root.eventcontroller.simTime);5 V8 w7 X- `) t: x% C
                        @.HasOrder := false;1 s/ p4 m  Y/ J8 F7 Y1 U
                        @.DrivingHome := true;2 i' F% s( `: E
                        rgManager.tryToStartTransOrder;1 e5 l8 A1 P/ r
                        if @.Destination = void
& F5 g3 M# p& D* a                        then -- no transport order for vehicle @
7 }6 _8 A; ]9 ~* \, r                                @.Destination :=
/ w5 q# h; @7 D                                rgManager.nearestFreeStation(@,track.~);
# ?  p. U. }$ f* t- j2 B# Y* s                                newDirection(@);   6 n8 o: K  d8 y
                                if @.Destination /= void then
: u+ g1 h! Y7 j1 o5 d8 v                                        @.Destination.NumReservation :=0 [. k# [/ J4 _5 }) e7 U) s
                                        @.Destination.NumReservation + 1;0 A4 L0 o1 E- ]5 F4 n
                                end;" I8 s) a: J" @* z( Q) u$ Q1 k# e1 j4 ~
                                @.CurrIcon := "drivingHome";9 _9 |8 J/ d- Q  T7 G- g8 c4 V
                                @.DrivingHome := true;
2 q5 q+ W. ?% Q4 I                        end;  q: G7 {4 v* g
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station3 O! L  w: S! G$ ^
                        part := @.transpOrder;# H% P  A6 z7 s5 E
                        part.move(@);-- load part* i& d  N( A- w- c; G
                        @.CurrIcon := "load";
( T) Z- K! S: f; K* H                        GlobalDistObj := part.globDestination;
1 r1 Y& G# f- B6 f0 p, F* @( [; Y                        assignLObj := rgmanager.rgAssignL;
" w/ x% b# T% y. [( M                        row := assignLObj.getRowNo(GlobalDistObj);
# p2 J+ ], G' b                        if Row = -1 then -- since 70
+ ?1 H# p6 ~/ ^) |, l3 j+ T# q                                if lan=1 then
5 y8 L' {& V. k1 ~                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
3 x8 J" w( \3 P- V$ n/ f# J1 j                                                to_str("in der Andockstation: \"",?.~.name,"\""));5 J: S3 F' S) e, G  J, U1 u
                                else
# p' T' ~+ k- K5 a                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
% Q  X7 h, W6 p% C- ~                                                to_str("in docking station: \"",?.~.name,"\""));                               
) E3 T0 O& e9 b6 N5 _! V+ [                                end;
5 k  h% r6 j: t4 Y                        else& K1 S( H9 ?3 S1 N  ]3 y% K
                                @.Destination := assignLObj[1,row];0 x2 u$ M# h9 m
                        end;                       
- e, ?5 m6 X4 m# W( E' R% |                        newDirection(@);
6 }. B/ E5 d: ?7 y                        @.HasOrder := true;
9 `, q. D0 O+ j! B1 d, K; J0 }                end;
7 b! B+ k; [2 ?        end;
: \7 w+ F: e  a$ g; F- M0 L2 v9 iend;        -- of the method# w2 u! _) f- {$ H" C7 A1 l) a* l9 G
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
( ]* y1 g8 D7 s2 Z( q3 b4 Y" s. O! p; r7 }' [- o
这是AGV_putin中arrive的method。; V" h& g" I4 r
) P4 q' ?. H1 ^( v
当到达物料速度越高时,这个报警更多,
, |- P# I# @; B, d! z0 i0 \: i可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
, g$ ~+ }( Y0 x1 X/ x程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?; e# B3 P/ P) @! `  V& i

6 G6 U5 |4 q* t& W" H9 d另外一个小建议,就是move,所有的move都可以这样
/ |+ `( b9 S0 ^/ s) Rif not move() then debug end2 x( a# l, M6 q% m$ c" E! t$ Y
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。5 o  y& ^+ Q/ |
plant simulation中的free libraries有AGV模板,# U5 V# T+ I0 \
里面也有案例。; `- j9 h) q" C2 p* F7 j, J
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
8 e% D2 ?$ h9 z' q/ d) X4 u$ e
0 C3 h$ ^1 y" q3 z我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑   l& [# O" G  a- D1 {

, Q& s- t5 E: c6 [* P1 M5 @那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 6 C9 w9 C4 G, y" T, Y4 [; m' _. ]
这是AGV_putin中arrive的method。. j+ l+ ]. L0 g6 `. O8 v0 U, w

$ D( J& A! j: \# A) D8 m/ R当到达物料速度越高时,这个报警更多,

9 ?0 g2 G1 U; t1 O另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-18 14:00 , Processed in 0.013577 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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