设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7726|回复: 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'
7 x; l0 E- F; E4 o# [*/
  P- w2 q/ _6 Z& O# wis
' [- s+ g- r* r5 u        part, GlobalDistObj, assignLObj:object;row,Lan:integer;$ L) [1 W! ^6 F+ H3 E& k, G- h
do
, P2 H  U6 F* E, X2 r8 u        Lan := rootfolder.Internal.Tools.AOLlanguage;4 T: c5 y; {& z
        if current = @.Destination -- else return
) m+ r$ c: u5 |: I& M        then
# e4 F* i: ~8 N6 V4 }                @.Destination := void;# g1 x7 J2 o9 b+ k/ n6 Z' o
                if @.occupied then
0 }+ B% P( b" ^( K0 @1 W' t  W                        part := @.cont;
4 i/ d$ C. S+ J' a1 N! J% z2 W( l                        @.transpOrder := void;9 W8 m4 E4 }) e, D0 s
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
; i' k% R4 D/ K* @2 i: @# j                                @,root.eventcontroller.simTime);( N) r/ j3 w: ]
                        @.HasOrder := false;, v: S  ^1 c/ K, J
                        @.DrivingHome := true;
  X8 s1 k3 j9 t                        rgManager.tryToStartTransOrder;
  d3 _5 |% U7 P# F; Z* H                        if @.Destination = void4 L) P; O" P  O7 E, s' _( u
                        then -- no transport order for vehicle @
& s7 \" r1 _; z5 f; H$ X3 Z( R- ~                                @.Destination :=
. G) [8 ?7 G9 N/ b                                rgManager.nearestFreeStation(@,track.~);
; \5 R' c9 _1 i4 i' a2 t                                newDirection(@);   ! B, A3 V  @1 j1 F
                                if @.Destination /= void then- A/ B# v: @$ \+ o! \" g! l( j
                                        @.Destination.NumReservation :=
" }" V# p5 d2 Q+ }& A6 d. h, T                                        @.Destination.NumReservation + 1;. K5 A; S6 s8 K+ S7 Z
                                end;
- W) ?7 r7 t. p* b                                @.CurrIcon := "drivingHome";- ~" Y- T* H  m3 U, p
                                @.DrivingHome := true;
! }* L0 ~1 ]. [& a: y2 X( x                        end;! x4 O3 v7 ~3 E
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
2 U$ H& F+ I0 P2 Y& {. Y& C                        part := @.transpOrder;
$ ]% H# L  w* \" K                        part.move(@);-- load part
4 ]; s, w: w+ Z) n( i* y                        @.CurrIcon := "load";
0 Q7 Y; R. u1 j+ L( T1 v' L                        GlobalDistObj := part.globDestination;& N% y  Z9 z: w
                        assignLObj := rgmanager.rgAssignL;% o! b5 m) N# D- k3 ~9 I8 Q6 p
                        row := assignLObj.getRowNo(GlobalDistObj);0 F( T' g0 Q+ N8 ]
                        if Row = -1 then -- since 705 _4 z$ H; Y+ [) H  }- f
                                if lan=1 then
6 r* \5 s; F' e2 i' w! k                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
( Z1 {6 x$ O7 e4 H! @                                                to_str("in der Andockstation: \"",?.~.name,"\""));8 \: m+ \7 j1 N/ u
                                else
2 {3 r  A& Z7 {7 l                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
# d5 K3 N( o) n) T/ G                                                to_str("in docking station: \"",?.~.name,"\""));                                  b8 s& u* O# P. t
                                end;
; F7 ?' \* {5 }4 V0 R. k                        else" Z+ c: l% k( |" j2 x' H* l
                                @.Destination := assignLObj[1,row];
( v9 _# ], c8 p5 R                        end;                        6 q+ D) ~9 g$ i: b! c* W+ C
                        newDirection(@);* H4 E' [$ V: f7 A
                        @.HasOrder := true;: i# ?/ ]/ Q6 l" u% @. Z: p, T! b7 ]
                end;
, s) N/ e1 W# o5 p1 D        end;. U9 @4 w+ ^: W: S
end;        -- of the method
) X( I" S8 g4 l+ o& E  d
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 * G! ~5 h( T0 p$ i- \0 W
# m- a7 j  k9 M0 r# @* C, H3 j
这是AGV_putin中arrive的method。# s, C) L1 W' j% M# u( l

) u: Y5 ?/ t1 n4 y当到达物料速度越高时,这个报警更多,
! ~+ l& X& Y  k5 l' E可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。) X2 D/ g. `' G. e* E* s3 M6 G
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
- H. M5 h" {+ n- a6 A
! z8 ^& p0 W' R, _) i( w9 L另外一个小建议,就是move,所有的move都可以这样
( C& B6 u8 c1 m3 R% `  ~5 o& r/ sif not move() then debug end
* z3 r9 A) @) [. n! K# Q  H/ x这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。1 ]+ F7 }: a( _6 U* u( Q4 @8 ~1 l
plant simulation中的free libraries有AGV模板,* p* X% d' `/ z' p
里面也有案例。
6 g4 q2 H+ f  X! g; C9 D我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
' D! y) r! _2 x( j$ s' K- {2 j/ E. m& B7 Y& w& V
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
% @' H. O2 G( |. J  i( t$ |3 O: |+ g1 _. X/ L0 [/ v* Z2 T* o9 d
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
+ l" G/ Z8 K7 F3 Z2 ^& [" T  X7 b这是AGV_putin中arrive的method。$ Z$ Q, w" o4 w* b# e: @1 h& m3 A

6 G6 b1 y9 f; R0 `+ R) Q  R) g7 |2 \当到达物料速度越高时,这个报警更多,
, t" l' j0 c- p4 ~# ?- k0 Y  i
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-26 07:14 , Processed in 0.016294 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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