设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7553|回复: 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'
3 k5 E# G5 E. _*/
5 K1 h8 e! n! h0 M, Y: i4 Cis
: _, M3 H7 k6 [        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
5 J& D: {( _) K* f# l0 Kdo( o9 b- o" G. w% X( \
        Lan := rootfolder.Internal.Tools.AOLlanguage;3 K- ?9 K! f4 s  B! _4 l# R2 U
        if current = @.Destination -- else return6 M. T  V$ e; K* f
        then
7 Q( I/ @8 c% N$ f                @.Destination := void;
2 N# @2 _4 x  ^( N2 h                if @.occupied then
! n$ F/ p5 _1 `                        part := @.cont;
3 Y0 N% i- F, r; q1 Y0 Z& Q/ H2 @* b                        @.transpOrder := void;
% q. Z1 g5 n/ j1 c6 H4 S                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
8 C, |6 A4 B7 V: t" h; f' W                                @,root.eventcontroller.simTime);
, U7 C% c" U: Z) l                        @.HasOrder := false;
. w+ o7 `) m/ _$ p/ W                        @.DrivingHome := true;
8 `  t6 R+ j- r, H/ L. F2 \                        rgManager.tryToStartTransOrder;8 a* o; W% `& z1 h  @/ _* F
                        if @.Destination = void' Q- x5 P1 r. E' j5 F: |: Q
                        then -- no transport order for vehicle @8 R) Y' A" ?0 R  x- u
                                @.Destination :=1 b! }4 d: G( h' X  }
                                rgManager.nearestFreeStation(@,track.~);
4 M- g, S! o' w) p3 o                                newDirection(@);   % R3 u6 o# o- ~( }9 ^8 i' l, W! H/ R
                                if @.Destination /= void then
' q" l5 U( Z7 H3 O& _0 ^                                        @.Destination.NumReservation :=
8 {( @* t% Q% e! B$ m: Q( T                                        @.Destination.NumReservation + 1;& @! e# F3 ?0 B- D$ ~7 j5 Y" H' X
                                end;0 i3 L* g* m: H( b! s
                                @.CurrIcon := "drivingHome";7 s/ T, z# B3 U, M' r7 n
                                @.DrivingHome := true;/ A. C8 I5 ]/ _2 C0 h5 h
                        end;3 X- x7 D, i1 n  |) K% A  i9 b
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
8 Q2 Y8 r, ?2 k! f0 U0 }4 E                        part := @.transpOrder;
% K! X' |- N. K- N% _                        part.move(@);-- load part
9 C+ H7 B5 i' }' t6 i                        @.CurrIcon := "load";
. Y  q' ]5 o9 [) @                        GlobalDistObj := part.globDestination;9 T4 t, |( \  T: d
                        assignLObj := rgmanager.rgAssignL;, ^0 ?: ?* g' J8 N4 ^5 M! _
                        row := assignLObj.getRowNo(GlobalDistObj);
  x8 ^" c2 t" ^! x; s& }                        if Row = -1 then -- since 70
1 i# f4 o% k6 g0 e* J                                if lan=1 then$ l8 s  j: s  d9 _
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
2 U' M! E9 |8 m) ?                                                to_str("in der Andockstation: \"",?.~.name,"\""));8 T: [* M" A% c9 F
                                else
) ]- j# \# T' {6 Z+ l5 D                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
) K2 P5 z% |, Z                                                to_str("in docking station: \"",?.~.name,"\""));                                6 l# w5 Y' @1 m8 u/ i# m8 L/ ~* s
                                end;4 b" J  x) r4 _$ j; T( ^7 N1 d$ t
                        else! u) u' m" h: N+ v
                                @.Destination := assignLObj[1,row];
) N3 r3 _( }8 E5 }3 \- j9 ^                        end;                        , e# @" ~* }" ?$ ^/ e: ]* c, }* i
                        newDirection(@);
1 h, {* F( Y2 X3 v                        @.HasOrder := true;3 w" O( i7 `& L& z2 d
                end;
; N" z; h7 m/ G3 c' h        end;
  T0 Z5 Q7 y+ r! l% Hend;        -- of the method& a  C5 K) R( e
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 7 J  x) p+ X+ i" Q

5 e) _5 |. f4 O这是AGV_putin中arrive的method。' o" N: R' Y) A: J

% G: E9 @) c! x" P) L; s2 M: j当到达物料速度越高时,这个报警更多,
8 L& A) Q2 d6 M. n' X可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
" |! Z1 b: C+ b% A程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
, Z( @9 i# D1 a+ b
' k9 Z0 e* {; j0 p: n3 d5 u  F2 R. t另外一个小建议,就是move,所有的move都可以这样7 U0 L/ |8 ~9 i! z, _5 X6 b4 G9 Q
if not move() then debug end( @/ B/ G, K% r- f
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。4 W; u7 Q$ _5 r2 T" h8 {: k
plant simulation中的free libraries有AGV模板,1 E9 Q  E) Y/ I3 L1 [" @- N
里面也有案例。, Z- C% a& S) l5 L/ [; v- l/ d+ \" _
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
- Q+ Z& j+ u. n5 E* i2 E, q2 R8 n
% c1 x3 E( W- G: l) ~. Q我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
/ }' A4 b) {% w( b6 L4 _
, U" L- X: P  ]2 C% Z那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ' m/ ^  V( H" m1 I# E
这是AGV_putin中arrive的method。5 v; ]  S) `" q$ V

  q4 {  Y  H+ o当到达物料速度越高时,这个报警更多,
: P9 O' Q5 ?8 E8 V: h5 k
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-17 15:52 , Processed in 0.022882 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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