设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5809|回复: 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'9 B# g0 R4 m8 w3 A; h9 I
*/- A, b5 A4 q! p" `2 D/ |& l
is
1 z; n( k0 G0 \* J2 \        part, GlobalDistObj, assignLObj:object;row,Lan:integer;& t- Z& h+ d4 O9 n# Z/ h) z
do
) b0 H/ _" }; U3 n; {- o& e        Lan := rootfolder.Internal.Tools.AOLlanguage;* H5 w+ J( A8 H8 t7 @+ z
        if current = @.Destination -- else return# [8 U( U' q9 i2 \6 ^
        then' d9 X6 L  }, l
                @.Destination := void;: k! {( X/ N4 w
                if @.occupied then
% j9 ^- X- g( V0 N: V  w7 e$ `1 g                        part := @.cont;
( q/ s; O  A* @5 F5 ?; E8 y                        @.transpOrder := void;, x  S0 q( d4 c: P
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,9 m; o, {; O0 q4 H  v
                                @,root.eventcontroller.simTime);5 S' x& l5 f& q3 a2 O
                        @.HasOrder := false;! |' ?& e9 L7 X6 g
                        @.DrivingHome := true;3 p+ y- I# W) W1 R  q* \! }
                        rgManager.tryToStartTransOrder;
! Z1 ~4 g# Y: e& Y! N2 B. O9 \                        if @.Destination = void
5 l6 v0 N5 P6 Q/ D5 u; I4 `                        then -- no transport order for vehicle @
$ l% \& y) _+ H- f1 i                                @.Destination :=: H9 C  ^% v+ _! H1 C
                                rgManager.nearestFreeStation(@,track.~);( i% Y/ p& V/ {- g% s
                                newDirection(@);   . N4 _; b4 h- Y& \# S
                                if @.Destination /= void then  i1 E  Y, _/ m4 I- h
                                        @.Destination.NumReservation :=" A% q# y, p* ^8 `" \
                                        @.Destination.NumReservation + 1;  Q- \% ^% Y* Y2 d
                                end;
0 h" O% m2 y2 ^. B, y                                @.CurrIcon := "drivingHome";: S" [2 u3 s: f
                                @.DrivingHome := true;
7 Z' ]9 V) r, n6 }                        end;8 G9 v- _# A& _: {- C2 w
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
8 |2 b% g! k7 t& z# w                        part := @.transpOrder;5 H) C6 G6 E1 n0 k
                        part.move(@);-- load part; A' I% a8 r! c, D& u
                        @.CurrIcon := "load";
5 \" ?2 F2 M( N$ N: P2 ]                        GlobalDistObj := part.globDestination;7 l; q* g/ O# T+ ~( ?/ X
                        assignLObj := rgmanager.rgAssignL;- U) ?. ?0 U8 u4 r2 Y6 b* U
                        row := assignLObj.getRowNo(GlobalDistObj);
: Z, x8 Y+ M" j' q; J                        if Row = -1 then -- since 70
: Z( l) Y5 S. n4 g                                if lan=1 then6 y8 V* `/ b3 q
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
3 k" J% h5 |4 n" M) W                                                to_str("in der Andockstation: \"",?.~.name,"\""));
+ y  H& Z6 a! H& F* X                                else" L- L5 G7 s% [. _
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),+ R/ ~, T- C; {& E1 E+ w
                                                to_str("in docking station: \"",?.~.name,"\""));                                ( T* }9 x* \5 E
                                end;
6 O: ?% b3 n8 v0 ^4 [0 m- s& B                        else# q( {$ G1 J( ]0 {) L" P' V3 \+ G
                                @.Destination := assignLObj[1,row];
) D5 L3 X* O+ J- i                        end;                       
/ a- O9 Y) N% x/ B. v8 B                        newDirection(@);
& {: S( }. [7 B1 _, {. Y  i( r                        @.HasOrder := true;( W# f; y) m! x, s1 Z
                end;
0 V# q' B+ C1 }3 \1 F8 B  p4 q) {! Y        end;: u7 h5 E0 I4 u9 M$ |- y9 G
end;        -- of the method! U2 Q8 U: s1 a' q
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
2 L! O$ F  Z- n3 t1 B4 i# A% Y  y' C( X2 v( u' l
这是AGV_putin中arrive的method。
: j% @7 x7 @4 V" `( W8 x# H3 B4 E& \# b
当到达物料速度越高时,这个报警更多,
2 G! @0 y, ^. [* P! K4 b可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。. ?' f: W6 m5 `- W+ z
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?' ^! o5 B. Z9 k0 Z

" T9 o1 h' _1 g* ]* c; M另外一个小建议,就是move,所有的move都可以这样
3 `" ]4 B; t+ p! o( Vif not move() then debug end
- r5 X5 G9 u) n0 j这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。, x7 P7 J; Q. d  B& Y
plant simulation中的free libraries有AGV模板,
8 d( Y: {8 U& }里面也有案例。  U! ^7 R/ d% L) T
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。. _4 b8 B- [6 X/ O5 t" k+ D$ N5 u
/ A: q) q$ S! P* Z+ p, ?# J* p
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
) q# d, W7 }5 o" w9 ?* Y0 B: r% m/ ?8 P
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ; ?! g9 u& `  H7 \. f' n
这是AGV_putin中arrive的method。
  |- |( _4 @9 R2 l' i' J/ H) ?& ~* R3 ^+ q: K; `  F9 [
当到达物料速度越高时,这个报警更多,
/ j" t5 c$ E8 w* c- I
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-12-22 17:28 , Processed in 0.020182 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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