设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6622|回复: 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'5 X* _7 b' D  p4 }9 q. j# n) G
*/. j# p5 c/ K# a7 k5 x
is* Q' K6 `2 D3 j' G5 g) j
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;, y$ A! Q$ x+ G0 ~1 R6 L7 l
do
* U# U( W4 Q% S        Lan := rootfolder.Internal.Tools.AOLlanguage;4 u& |' f# S% p5 s% c
        if current = @.Destination -- else return5 C2 K( L! K. R5 K  P& A
        then/ w2 l: G0 U+ B0 G' ]6 ]
                @.Destination := void;6 I" ?3 s. P* V5 v" `
                if @.occupied then  S/ `( t3 p% B) ~
                        part := @.cont;
. J2 ?8 H! P0 c: n! [& C! P                        @.transpOrder := void;
3 e3 }. Z5 L- s8 u! D                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
3 ]2 g& @' H7 Z0 ^  B                                @,root.eventcontroller.simTime);$ e) A1 h* _! n6 f; |; k
                        @.HasOrder := false;3 f( W- A& P6 g' i+ S6 O
                        @.DrivingHome := true;  k, j& a( S0 {, J  x
                        rgManager.tryToStartTransOrder;
  x+ T2 r. G. Y                        if @.Destination = void
) P! K0 [+ u/ l6 t                        then -- no transport order for vehicle @
" {& F5 H# o( i; z. [& U                                @.Destination :=! l$ o/ s* e( h
                                rgManager.nearestFreeStation(@,track.~);" X) f) g& I1 F% O7 Z
                                newDirection(@);   
1 m: M5 L5 n/ J* A1 d( s; B                                if @.Destination /= void then. r' c! A% h/ W: [1 x  x
                                        @.Destination.NumReservation :=
- G/ t0 c( {: a                                        @.Destination.NumReservation + 1;
3 |: t/ v$ S0 R- T5 y# |                                end;& P9 o  n% M- l
                                @.CurrIcon := "drivingHome";9 v5 ?  }  M1 x+ e3 I- r: i
                                @.DrivingHome := true;
. B2 \2 B5 G( M' x                        end;* ?: B4 A1 U6 ?9 b# I& P; k* k* p
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
6 x4 T7 B6 S1 ]7 N' \( n                        part := @.transpOrder;
) ~/ D/ @8 c5 k) I7 X                        part.move(@);-- load part
/ k+ T/ r0 ]% `( F2 n                        @.CurrIcon := "load";
) W; D' r0 l7 h- c                        GlobalDistObj := part.globDestination;
, ]! z+ r* N) G6 f3 W                        assignLObj := rgmanager.rgAssignL;% p1 g: z1 I6 C8 ~
                        row := assignLObj.getRowNo(GlobalDistObj);% j# ~( n/ |0 Q; Q, v% h
                        if Row = -1 then -- since 704 A; f/ M' Z9 v% F& @* h  i
                                if lan=1 then. Q7 W7 O! G  D4 x# L9 z- \
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),# i/ h" m* F) ?2 r' v
                                                to_str("in der Andockstation: \"",?.~.name,"\""));# p! B, P2 {* g9 g
                                else
. }$ n, T+ b2 x                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),  G) z2 C  x' T; R9 t$ p7 h
                                                to_str("in docking station: \"",?.~.name,"\""));                               
8 u9 l! n0 N! s2 j0 F2 t/ t9 T                                end;
: b. }4 @! A$ w- f5 ^  B                        else' V3 P( o  T' D
                                @.Destination := assignLObj[1,row];
5 D$ _# s' ^' C. m$ _. b, ]                        end;                       
  V# S7 h$ t# c4 I% j3 _                        newDirection(@);
1 b. _  U( Q7 N; N; Y# R2 W# U                        @.HasOrder := true;
: F5 k' z' L' o; \                end;' M& t/ Y& X3 N& L* R
        end;
8 z' S; U) _6 R/ zend;        -- of the method. e; [- a. u4 z$ L8 [+ T! o  n/ t9 \
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
, [1 t' |4 E. Y! F
2 T. W8 c" c9 K' p( l9 v: ^6 w9 [这是AGV_putin中arrive的method。  @, J5 W* V+ Q
% Y* w) b2 I" s. g
当到达物料速度越高时,这个报警更多,3 D- G2 b2 X% J* X, G, S
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。) Q  z9 w# Y( F2 r8 e+ Q) V
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?5 ]! u/ F6 y3 i6 p" F& C
1 t' S/ s, ~+ w
另外一个小建议,就是move,所有的move都可以这样+ l% |8 ^% y- |0 ]1 t5 d/ W% v
if not move() then debug end
! ~" _# }4 ]2 g# M" Q" y8 j! p* }这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
% a4 D2 _# W8 L1 vplant simulation中的free libraries有AGV模板,
- e- Y7 R6 a+ L7 }" M里面也有案例。% H/ x& \' o: U& t  u
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
1 w( l2 R3 v% U" r" p$ e  H
% _; _9 X) A) x7 B) U; j3 |我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
" y5 c/ k/ q# u$ h& ]: f% h8 P( B+ @1 _2 s1 k) D/ j% Q
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
- W7 @5 r- R- f7 n7 P& z1 o这是AGV_putin中arrive的method。4 A5 K6 ^. q9 F; ~1 x
* l$ G5 _" O1 s7 z' O
当到达物料速度越高时,这个报警更多,
; N. s0 }  l) ^' S6 ~3 V
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-16 22:17 , Processed in 0.017658 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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