设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6315|回复: 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'+ j0 w2 q! s3 o
*/7 E! }* _8 j# t: F
is/ [. h( E; G( ?
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;" M  p9 X, D" P
do
. j! }4 c0 N$ w, j* h: r4 h6 p3 r        Lan := rootfolder.Internal.Tools.AOLlanguage;. U$ ?; Y) h2 K0 g
        if current = @.Destination -- else return1 o' @" i( C& |  ~  t
        then) L  X1 ]  m' Q  o9 C6 I8 x. b
                @.Destination := void;5 i- i1 M; }& Z3 G2 T* n( G
                if @.occupied then
6 T! }6 L% P, c, _                        part := @.cont;
- V. O) _9 i" B5 K7 ?. _: V, l3 f                        @.transpOrder := void;, J0 i7 m' x) m9 G
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,; ^5 T5 ^: n$ f: [- D0 m8 s- Y
                                @,root.eventcontroller.simTime);" h) L0 ]$ T) n# I
                        @.HasOrder := false;
& v) v% y, E% a3 ~& f% K- ~                        @.DrivingHome := true;
$ n+ X' V6 p! I  y- {                        rgManager.tryToStartTransOrder;; @; X5 D* ?$ {& s" ~6 `7 y
                        if @.Destination = void
, f1 I" C2 Z9 a  g) D& I  a                        then -- no transport order for vehicle @* M  B/ p0 W& }. b! E
                                @.Destination :=8 P% Z1 b7 q9 G# W; Q
                                rgManager.nearestFreeStation(@,track.~);$ u" D3 X; H" [+ A( w1 i* Z' j
                                newDirection(@);   + W9 b* ^$ i9 n5 q
                                if @.Destination /= void then
( y- {2 ?& ]9 I( h" M                                        @.Destination.NumReservation :=
  u( v" W  T6 w) s6 Z( X                                        @.Destination.NumReservation + 1;
4 y+ f8 N# s5 F! Q8 ^) Z                                end;
% A9 Z( o" A; n# x: l                                @.CurrIcon := "drivingHome";+ N0 _% f' Z  ], |. ~, U$ U
                                @.DrivingHome := true;' V' X' d" t9 J& D! Q: [  {& }
                        end;
) A- U+ j- G- w' k3 D                else -- the vehicle @ is empty, both vehicle and part are in the same dock station& p1 ?9 Z3 l1 s, n" K
                        part := @.transpOrder;
/ W; b7 A  {3 N, e" g& Y                        part.move(@);-- load part8 z/ A7 }( K, q( y/ l. X2 e
                        @.CurrIcon := "load";
$ O* {3 X" _& Y$ E: A                        GlobalDistObj := part.globDestination;( w) \& J. A- Q9 q) W5 d& r
                        assignLObj := rgmanager.rgAssignL;
* Y$ \. g1 B4 _" N! w$ q7 J: X1 ~7 C                        row := assignLObj.getRowNo(GlobalDistObj);0 j' o) t8 P! f# g7 H9 q4 w
                        if Row = -1 then -- since 70
. m5 p1 N  j: A! [                                if lan=1 then
+ d& Y, x) O* `9 Y                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
- [& q+ V4 P  i9 q) f2 c* X: I                                                to_str("in der Andockstation: \"",?.~.name,"\""));
7 @- K4 O% Y: Z                                else6 H! A9 \/ Z1 X: b( }. R& ]
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),: h- H) q/ q# u: r( Z5 U; M
                                                to_str("in docking station: \"",?.~.name,"\""));                                / \" @( ?# }8 r' k) v4 `# b9 i8 \
                                end;  D1 F! ~1 u4 a8 U
                        else
/ U% [0 G: [; N9 V6 t                                @.Destination := assignLObj[1,row];
/ b* X- W0 E7 y8 m5 p                        end;                       
6 |! Z6 x6 u; @) @0 R, _0 @( p                        newDirection(@);
' I$ S, t9 D3 [( i6 d# w                        @.HasOrder := true;
% Y! `# \# Y- s! h* j: K# F2 X8 k4 o& ]                end;
: C) L8 I$ a  n0 J! Q$ ~, @        end;
2 z9 l, b/ V- ^0 \! j/ Cend;        -- of the method
' U% E0 m! n# w: D
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
1 {9 z: x, x- h+ w
  N2 e* f& p. S% _6 d$ P这是AGV_putin中arrive的method。
* }0 S: n" Z$ ]- B
0 ~3 I! S3 n" p( i& F当到达物料速度越高时,这个报警更多,
, t7 O2 ?( }. M) h$ `7 N/ F可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
# t) H* ~( Q; k' b  \0 \  d0 v2 [程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?" P  B& r1 y4 i. j* T
/ e3 d( x' u% O5 m
另外一个小建议,就是move,所有的move都可以这样
) a# V- L- M: _if not move() then debug end: h- |* s5 Q0 J2 W
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
$ t& A; M4 x% h, W/ kplant simulation中的free libraries有AGV模板,. ~; x: f# U# h% W
里面也有案例。
8 B1 L. _. l7 O$ g, x0 I9 ?8 u我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。% \# z9 ]* A! r! E9 p9 h3 J
8 D+ s* }: m$ j- K8 u- }9 r
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 4 [5 ?# P* F, x# I  m( o6 u
  }1 K# u  l& ~& @- H2 p1 a% l" b
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
% C# u2 L6 L. c" v8 |, f4 Q. n这是AGV_putin中arrive的method。4 d0 Y9 A+ ?6 Q* d* E
( C+ W' r8 J3 Y  C4 F, s' B6 h
当到达物料速度越高时,这个报警更多,
7 r8 K6 T; [% _' `& l0 p" I
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-30 11:52 , Processed in 0.021330 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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