设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7871|回复: 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'* n% n* `( {9 P& w3 S: j
*/1 T* M; u' `. l% i; m/ a
is$ b! c$ k, b5 {$ u9 i
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
7 r# X5 u$ }/ o# ~8 J/ g% }do
0 w( U, x1 ]8 p% l) Q        Lan := rootfolder.Internal.Tools.AOLlanguage;, |, }# D' J& c1 w
        if current = @.Destination -- else return
6 e6 D( f, |% C        then
7 K; ^' s* c2 j; i2 |                @.Destination := void;
( u; Y8 C0 h/ J- W! a                if @.occupied then
; c" T& D5 F: F9 C                        part := @.cont;  P+ m7 k6 n$ E7 ~7 a" g+ W, V
                        @.transpOrder := void;
1 }, I: }+ O* G                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,+ U; p7 U7 h' V2 i, R
                                @,root.eventcontroller.simTime);
$ J9 @7 z1 B( n                        @.HasOrder := false;! f' `, y! {: H9 w( k
                        @.DrivingHome := true;( y; n( K9 `- O- O% R
                        rgManager.tryToStartTransOrder;  i4 ]: _  r" I! G
                        if @.Destination = void( i& r2 I+ h; {* L6 {
                        then -- no transport order for vehicle @
' i, s' x6 X& R                                @.Destination :=
8 D2 h5 |" f/ S6 K$ j3 {: `                                rgManager.nearestFreeStation(@,track.~);
$ W/ F2 E4 ~. y                                newDirection(@);   : l1 P$ p$ X  D# J
                                if @.Destination /= void then1 c8 @7 ^4 m; |" C7 I
                                        @.Destination.NumReservation :=
0 v  L/ f- h/ E, Z4 J                                        @.Destination.NumReservation + 1;- X! v6 b# F( O3 v
                                end;
. v" |& }! o* c* f                                @.CurrIcon := "drivingHome";
. Y; K7 X' J8 D0 f                                @.DrivingHome := true;" `" ]* K' l0 h1 |/ j- z
                        end;( V9 ~* x. ^! M6 G
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
" a% K1 L! X+ G# K% ~% c+ T+ W" t                        part := @.transpOrder;
3 P5 w9 o) |3 G! q: g! g                        part.move(@);-- load part) N7 y3 Z2 v& ?7 f
                        @.CurrIcon := "load";
* P3 R# @0 @& h/ p7 J                        GlobalDistObj := part.globDestination;
* b, L( Y, G' v8 C3 U6 Z                        assignLObj := rgmanager.rgAssignL;9 o( t* @* L/ I+ _8 u$ _* @
                        row := assignLObj.getRowNo(GlobalDistObj);
* Z8 j: m& X9 R& N5 C                        if Row = -1 then -- since 70
1 |; e3 J; M* Q. B- B9 g                                if lan=1 then
1 s# {2 Y$ O  {7 w                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),/ w5 \  ^1 p7 U% S& g! Q
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
  x# Z4 K& c8 t- {+ r, \                                else
' y7 J% c  w( o& n  E                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),2 @' P5 a' {) l8 ?
                                                to_str("in docking station: \"",?.~.name,"\""));                                & ~  s8 n" _- H9 C
                                end;! }; ^: }6 k$ D# `+ y
                        else
% Z) C3 [9 J" l  V; H                                @.Destination := assignLObj[1,row];0 m4 D' i, ~5 j4 b; a  y
                        end;                        * }( {) F/ t9 B) B0 v
                        newDirection(@);  Q& Z  x+ z/ T- W  z
                        @.HasOrder := true;
$ x* ]0 {  {" \                end;0 j) p3 n5 W& V. {, }$ U! H
        end;
" d) n& u# r4 H3 @- W9 Rend;        -- of the method
4 \( U5 W% l; a" e* l3 |
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 4 r2 @! d; W4 ?& V- f4 g

- \* \, ]1 J1 i5 u: X5 U这是AGV_putin中arrive的method。
, E- V$ c* C, L1 [' C
  N- ^$ e# i: t5 H# ~& r  e9 n当到达物料速度越高时,这个报警更多,
  p2 Y  v$ c- X5 s$ n+ {可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
" H3 H0 z# a  P( Y程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?# B* y! c7 a) P' z+ x

, J/ Q: ^4 [9 T0 o: x另外一个小建议,就是move,所有的move都可以这样5 e* ]! t9 X$ K
if not move() then debug end9 Y3 t( R- x2 m+ X$ l8 i
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
) E1 N( [, n; }1 }; R% mplant simulation中的free libraries有AGV模板,& ?( d' k; U, n
里面也有案例。
' v7 _$ E! \' v+ m我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。4 i" e1 s8 Y2 U) u1 I8 V6 ^
- h6 b# O/ `% g9 |
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
. z' b  }/ d9 K8 D9 W
# _1 x# s* P0 e( S1 ?5 G( R那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
) I7 |4 _% r& J# G& s1 [! T; s4 |这是AGV_putin中arrive的method。! p9 Q7 j, N/ J3 S
, _4 N+ o5 _+ B
当到达物料速度越高时,这个报警更多,

. y- h. V; ?8 ~另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-2 19:30 , Processed in 0.017003 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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