设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6392|回复: 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'8 n' W6 J& p4 p0 h. S# ^) X" R
*/; N& p/ K% B0 n" d2 v6 M* ~
is
) }* W: i, ^8 [. j6 l        part, GlobalDistObj, assignLObj:object;row,Lan:integer;3 R5 e  @9 _. n) T0 q
do
8 @- s' n) K- S0 `# ^        Lan := rootfolder.Internal.Tools.AOLlanguage;
1 N: q2 L3 v5 o4 Q) w        if current = @.Destination -- else return, D- b7 h, Z4 B
        then" i( L+ c9 k- M
                @.Destination := void;  H  K% ~. X2 R/ ^3 l+ R
                if @.occupied then
* ]" ~$ E# [& m  `( N# m0 T                        part := @.cont;
* Q& W- M# S/ m( n# n                        @.transpOrder := void;6 C- s- q& H) X4 P5 Z
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,  a! @/ C) E' {  h! t3 o4 X
                                @,root.eventcontroller.simTime);: t% _& S2 |9 ^. m: m' \# A2 [$ x
                        @.HasOrder := false;2 j4 V9 Z6 @& |  O0 y( ~% P
                        @.DrivingHome := true;
% Q4 E- m' H. O0 R                        rgManager.tryToStartTransOrder;
( \% ]6 a5 q+ S- {                        if @.Destination = void  P( A$ F8 @( V" e, a
                        then -- no transport order for vehicle @8 t# h: t- U( [5 N6 W8 u
                                @.Destination :=
/ g% p! ]# i9 r                                rgManager.nearestFreeStation(@,track.~);! Q: i' L8 X2 W  K1 c; D8 g7 t
                                newDirection(@);   # z7 g: R  Q/ G7 x9 o( y  K+ G. p
                                if @.Destination /= void then4 r$ W. w3 l( ^" @- d
                                        @.Destination.NumReservation :=
0 j3 v2 X0 N* w2 c( s  T( Y% O                                        @.Destination.NumReservation + 1;0 |: R) R8 M0 z- g: S
                                end;+ [4 D6 z  r& |3 j9 e
                                @.CurrIcon := "drivingHome";2 T. @& I  F1 q7 T2 W  r
                                @.DrivingHome := true;
  w  q, G3 N) q# ~) t                        end;
9 p* U+ u! N; d( s3 w6 |. o, q                else -- the vehicle @ is empty, both vehicle and part are in the same dock station5 f% e" q$ v7 q' k& X
                        part := @.transpOrder;
6 h( |1 l+ B! p' S                        part.move(@);-- load part
. O# n7 b; M7 s3 ?9 x3 p                        @.CurrIcon := "load";
0 A: w( y9 P+ k6 x" M6 J                        GlobalDistObj := part.globDestination;( I3 J" X3 P; t* h
                        assignLObj := rgmanager.rgAssignL;
( y$ L1 x8 y# s/ j1 P- i, k                        row := assignLObj.getRowNo(GlobalDistObj);
  @, m$ r/ W* T8 C8 K                        if Row = -1 then -- since 70
; O4 e& k- M+ Q! k; b6 h; O                                if lan=1 then
. W0 F+ l+ k3 ]/ g, c9 e                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
  X$ t8 n& I: e& e0 m                                                to_str("in der Andockstation: \"",?.~.name,"\""));
" E8 y8 h4 U* o/ w$ X                                else+ _' o2 V' J7 \. K* @6 \! [3 W
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),0 {% R+ z2 C" x% e; ?
                                                to_str("in docking station: \"",?.~.name,"\""));                               
$ D& r0 ~2 w$ e0 s                                end;
& n4 c- m: t" X" B8 Q8 F! O                        else
+ M5 i$ w9 @) d( k, u  f4 O6 c                                @.Destination := assignLObj[1,row];, C9 E. I3 S5 Z4 c5 v
                        end;                        3 L0 p- k' G3 b+ @& A+ i) A* z. c
                        newDirection(@);
) n3 n" U: c  }% q3 G                        @.HasOrder := true;
/ E  W* j: R4 f8 L) r  @  V                end;
' W/ t  b5 m% ~        end;8 V5 ]1 _( M3 [2 j4 K$ P
end;        -- of the method
& Q9 R. p- i3 y- h; X
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 3 K2 U) `+ V7 A% z+ L' w
; X( B7 ?! b' w4 w' ~8 z" E4 X
这是AGV_putin中arrive的method。
% I2 x. I' R1 ^3 u+ p+ @. r4 J0 N/ E$ s
当到达物料速度越高时,这个报警更多,5 m  V6 U( j* m" a5 ^/ s- E
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。2 P5 }  c- t/ G' l6 D: S+ G* {
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
! P; L) a: W8 K, G) z' A, E
5 z. @+ D; e" f3 l& g% P另外一个小建议,就是move,所有的move都可以这样
+ d; k  j) V0 a8 {3 Qif not move() then debug end
. W9 B" N2 r; b这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
: r2 }1 W6 R: F5 d% yplant simulation中的free libraries有AGV模板,( ^! T! w5 Z0 ~' _
里面也有案例。- Y2 t! q, p% I( z4 `6 d5 M
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
( D" P/ A+ y. g! P- l
5 p( N9 ^6 `  D9 }4 P我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 % N# s, q3 b$ i7 m9 ]2 E4 b% k

" ?! b0 O+ w! I! Y, r! F那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
, ?5 a0 S" o- m; {) H" L9 p这是AGV_putin中arrive的method。! z- A* B! V$ f1 x- [
5 m9 t4 _8 ]- m$ b: J
当到达物料速度越高时,这个报警更多,
8 R; x) w* `6 w& Y
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-3 21:50 , Processed in 0.021484 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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