设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 4795|回复: 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'
, e& ^3 ^: G$ [4 o*/
, [3 p: Z8 Y: w, d* Cis- @$ C, ~; d+ j' y. ], m
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
9 k! J& y2 i8 ?$ ]do
2 S9 f! ?! e% O' x- K. b3 M: l        Lan := rootfolder.Internal.Tools.AOLlanguage;
2 C! w: N# q3 O8 j' q        if current = @.Destination -- else return
! S7 V0 P$ J0 _: G7 t5 s        then
2 @( X; E4 }/ B, X                @.Destination := void;
3 {# L8 j: _( s. S" k6 \+ L                if @.occupied then) `2 T- p' A( Y0 `
                        part := @.cont;
4 M( f/ {- N  h                        @.transpOrder := void;! T' Z& C1 J8 j" I2 I
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
" D, E# J. T, A+ Q# Z, x2 ~. O! C                                @,root.eventcontroller.simTime);
+ y! j6 F% s6 p1 l. K  `4 u                        @.HasOrder := false;& g9 e! l6 E0 o
                        @.DrivingHome := true;& C( J( O3 L3 Y: g8 ~4 m1 c7 X
                        rgManager.tryToStartTransOrder;5 R5 Y& O0 H- s) N3 U; }* x+ x. A
                        if @.Destination = void" O6 `; K+ t1 |4 q1 T; q% S  @/ ^
                        then -- no transport order for vehicle @
  F1 `) L/ g2 C3 o% `5 {                                @.Destination :=
/ h; Z* r6 z8 j; w9 ]( @- h. z                                rgManager.nearestFreeStation(@,track.~);+ m2 \! K0 J. b5 f0 F1 a# d2 N
                                newDirection(@);   ! P% V& M: A9 C: M
                                if @.Destination /= void then
; v# D3 A4 ], z& q; ^/ q8 z                                        @.Destination.NumReservation :=* S. c4 z( h7 T
                                        @.Destination.NumReservation + 1;
8 ^6 K+ p1 t3 O' u' |                                end;
0 t1 I1 y9 r) f                                @.CurrIcon := "drivingHome";
4 C6 N# n) P3 c# I6 r                                @.DrivingHome := true;
# `9 x2 d7 U# @+ ^# T, y3 B& \                        end;
  Z( T2 W: q" h/ N                else -- the vehicle @ is empty, both vehicle and part are in the same dock station- d- t1 O& h+ B, X" J
                        part := @.transpOrder;
0 ?; c8 F+ L! \1 {5 l2 _) W1 V* m                        part.move(@);-- load part* @- \0 x1 S6 ]) u1 v  q' S! M
                        @.CurrIcon := "load";
  X% E: A$ ?  T$ ~( [5 n                        GlobalDistObj := part.globDestination;* a$ D7 a% [# @* f. [; c
                        assignLObj := rgmanager.rgAssignL;
( m( w, w# c- B2 k9 u5 x, t" r' K                        row := assignLObj.getRowNo(GlobalDistObj);' V7 a: S7 r! E1 R) K) O
                        if Row = -1 then -- since 70
+ d3 F9 e6 P" h( h                                if lan=1 then4 l& j  B+ t/ @9 q  `
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),! v4 U7 w! u1 b! b
                                                to_str("in der Andockstation: \"",?.~.name,"\""));) Q/ n' `* v5 F/ N8 ~$ ]6 o0 D
                                else* G0 c" F' Z, @, ~
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
$ Q% M) }2 r3 a% X  H" k) P                                                to_str("in docking station: \"",?.~.name,"\""));                                2 R& W/ Z$ [$ E
                                end;
3 E& _- p" W! W6 p                        else1 h& O8 n- M- u1 x: L4 T2 S
                                @.Destination := assignLObj[1,row];
3 c; w( W/ ?1 W! h                        end;                       
: p  ^& `. k& l! @                        newDirection(@);
, E+ l7 p- i" O' k                        @.HasOrder := true;
. w( |$ y' i! \- \& u                end;
2 l9 b) j* q. P! m9 j9 ~/ R- q        end;
5 z$ Z# R  B4 S3 \" Bend;        -- of the method7 Q8 H6 {- t2 Q" b9 u  \- V
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
" e  m. X4 E. t  N! E3 x4 C* z2 J9 Z9 X, {4 G* P6 @
这是AGV_putin中arrive的method。
. u% G- S0 P( r4 k9 n4 M2 U. `8 \  |1 D3 S
当到达物料速度越高时,这个报警更多,( x9 ]5 S1 d3 S% e, Y  J0 j1 O
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。& j" w1 `) w0 Z6 k, C  m3 D% f
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?7 j: T) w- s' V, ^/ N! ~; M

/ K$ @: D) A7 e另外一个小建议,就是move,所有的move都可以这样$ B3 C& U3 ?/ s
if not move() then debug end  Z# ]( ]+ n1 s. @8 s% J
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
" u  j, r9 y& ~/ E' q8 Xplant simulation中的free libraries有AGV模板,
! m! E. W. y" q% ~里面也有案例。
9 n# c' `0 K4 n" w. @) s我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
% `0 ~" x4 r2 W9 J  Y2 _& u2 O3 C# D8 e. p) K1 k1 B
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 # t/ ], R, T: n5 P' R1 d0 z+ j) @
" P1 m+ M+ Z! N3 R! z7 Q" [
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
9 J+ e) [+ r/ n) v  ^' j这是AGV_putin中arrive的method。
( x+ \+ b: X  |2 `: f6 t( ~9 \8 X  m( N( L
当到达物料速度越高时,这个报警更多,
& ^' ~6 W" D7 {- Z, ^! Z
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-8-22 00:51 , Processed in 0.016338 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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