设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10248|回复: 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': `2 r4 i$ m4 Q! C# i0 a% i/ |9 J
*/4 L# o& M7 M2 g! p5 u0 a
is+ q  w! J2 w  T6 B, ?9 k
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;( l7 \  a( [6 e  w
do
% F  B6 ]  [0 l* G        Lan := rootfolder.Internal.Tools.AOLlanguage;; m( _- d: _- e" J3 Z: N) `/ n* h
        if current = @.Destination -- else return! M4 L( }- X+ t" r, z2 b
        then  @" R2 K. C, w* @8 e
                @.Destination := void;
% ~! m6 R8 z9 ?+ O  s+ j- ^! s- t                if @.occupied then
" d- q$ Z! E, O) {                        part := @.cont;, l& e+ K% Y' p6 f& r3 u; }1 T
                        @.transpOrder := void;0 _9 L3 I( M& P$ \3 {6 ]
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,/ J# U1 L' V) L4 E+ {# [6 i& i6 b7 ]2 {
                                @,root.eventcontroller.simTime);
0 ~- S' ^& G/ b  _+ ~& r. T$ E                        @.HasOrder := false;
" O  p0 K- {# F# E% _                        @.DrivingHome := true;
9 N6 v) G! }. P2 [                        rgManager.tryToStartTransOrder;& Q- w& W7 W9 b3 D6 Z" o' }, h
                        if @.Destination = void$ [% @  {1 [1 a" q
                        then -- no transport order for vehicle @; F, t0 R0 A( {' u7 |) w9 a% M
                                @.Destination :=
: e" \( w) T8 d% Q  p! i                                rgManager.nearestFreeStation(@,track.~);
2 o3 A& e2 V. t% p! v0 P+ R                                newDirection(@);   
( g" {' K* ?4 ]0 j- W! `3 @2 I" s                                if @.Destination /= void then
2 ~: a" Y1 o/ M) w/ t                                        @.Destination.NumReservation :=) j1 |! s& _) V7 o, K1 q$ \8 U
                                        @.Destination.NumReservation + 1;
- r0 k7 d7 {; G& ]5 E! f3 L  {                                end;
* s1 w+ h/ y1 B" i$ p1 B                                @.CurrIcon := "drivingHome";
; }4 |7 [8 W+ i/ ?+ F% X                                @.DrivingHome := true;
* K0 o) F8 T- Z' X- _                        end;
* d- i7 ?" [3 u                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
6 |1 [) z- j' U( @                        part := @.transpOrder;
% C6 A) |& o/ c& o9 i' B) O                        part.move(@);-- load part
8 j: x' @8 d7 F# N) N7 N                        @.CurrIcon := "load";" s& z. _8 O) K6 A& Y$ L
                        GlobalDistObj := part.globDestination;
6 g7 e1 A. |+ M# Q! ~/ Y                        assignLObj := rgmanager.rgAssignL;
% y1 x3 y( Y( A1 i4 R6 A4 ^                        row := assignLObj.getRowNo(GlobalDistObj);# p) G- g8 P5 l0 [1 P
                        if Row = -1 then -- since 70- G5 {+ `* {9 ^8 h/ F5 X
                                if lan=1 then$ q: P4 y; H, T1 C8 J6 |# Q# Y
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),% K; H3 y) Q0 Y* ]' E6 G3 {: u% q, @
                                                to_str("in der Andockstation: \"",?.~.name,"\""));6 I0 C6 Q* b3 S) e
                                else
& L/ K! T% |8 `: J7 v0 h7 D                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),  u' b6 }: d% K7 D- U  q6 W
                                                to_str("in docking station: \"",?.~.name,"\""));                                . _' ], A2 D3 O! F$ I: N* ]+ h
                                end;
; c' o' `! X4 q0 B  Y% _+ D5 `9 c, D                        else2 ?1 c2 {$ t7 j$ [
                                @.Destination := assignLObj[1,row];
0 X' `* }0 {! x! q                        end;                       
+ z7 ^: F$ K) h8 r8 h                        newDirection(@);
6 L9 j! e, @# J1 Z/ p                        @.HasOrder := true;9 F8 V& w$ H% D. }' t
                end;% n* Q' N. T4 L* `& K/ |
        end;
6 y9 T6 E, \# Oend;        -- of the method
+ a9 y, h& k  r: U- A" O+ \
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
- j( R- o8 K! c3 X3 ^" X( O! d. p9 c, m& k
这是AGV_putin中arrive的method。. ^) z* K8 O) p$ [

- |. m, y& _1 P当到达物料速度越高时,这个报警更多,
3 O' [  g7 g/ W* w可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。* H0 @. L, @8 y! F
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?- A; P9 R: x3 {4 r7 p9 c

- q7 i) n/ |( Q+ V另外一个小建议,就是move,所有的move都可以这样( b- X/ z3 K+ D
if not move() then debug end
6 P5 S/ D3 o: y+ i这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。! x4 t) }7 B( p7 a' z
plant simulation中的free libraries有AGV模板,
' m( m' a9 K9 w( H8 x/ Z里面也有案例。  l+ o* @" n7 J9 m8 z
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
! g- s% h9 b: f- E8 X9 v8 [0 E
9 [/ [1 y: f) [& w. V我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 3 I0 O/ X/ G! s0 v) q9 |

5 s) i* Q/ J' a那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
& b! `6 N) Y. h4 a4 p/ F这是AGV_putin中arrive的method。1 Q* w4 C7 ~* B/ C+ m1 n

) L% f* c- F5 h4 w: a% _当到达物料速度越高时,这个报警更多,

8 q  \- `9 x- J* x6 f. q8 P, p另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-22 12:36 , Processed in 0.022044 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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