设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8459|回复: 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'
: F1 \9 b& ^( V* V*/6 z9 X" ^  W2 A
is
- N  X+ b" B, w2 K        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
, }- T' x+ O7 [6 Z$ f6 H( [. ?, Gdo
: ?! [- K- W6 Q9 \        Lan := rootfolder.Internal.Tools.AOLlanguage;
6 Y; i# b4 k$ i) K( }        if current = @.Destination -- else return
+ `9 e, _4 z% R5 A2 J        then4 o; l7 b) B" Z
                @.Destination := void;+ B  X) l3 J! t! N$ w2 F
                if @.occupied then* T( `# U. U  Q
                        part := @.cont;
, E5 h% K  }4 R. `' q1 A, Q! p$ Z                        @.transpOrder := void;
/ x5 H8 B( E. x' f; {                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,3 V" V- ^( b9 h
                                @,root.eventcontroller.simTime);' I! I: T# e: d  s3 e% o
                        @.HasOrder := false;  v! M, G7 F4 X7 P1 |/ J
                        @.DrivingHome := true;
7 v, `/ |* B2 V; P9 c9 c5 H                        rgManager.tryToStartTransOrder;
( a8 S# a" N% S, x                        if @.Destination = void
7 R! F4 ]2 x' |: i" K- X! i                        then -- no transport order for vehicle @, r' p& i, d/ V# w, N; V- Q; H4 E' G$ T
                                @.Destination :=. Q0 m) |" A1 [: i0 j
                                rgManager.nearestFreeStation(@,track.~);
8 Q3 @) A) F* W$ k; d; l4 \4 g) |                                newDirection(@);   
8 E) A! L# }( \) ~1 P; J' E( J( v                                if @.Destination /= void then6 R( e$ Z) u3 y
                                        @.Destination.NumReservation :=
* n$ f1 H/ w$ W& k                                        @.Destination.NumReservation + 1;! {6 @: t8 j  e: z& F
                                end;  @7 {* a$ t; C9 D* o& o
                                @.CurrIcon := "drivingHome";. t1 R( F1 U5 j" `& n! k0 q
                                @.DrivingHome := true;
4 e$ \  V: V) B7 p                        end;
* {$ [; r: x) ^: s8 w3 s. ?; T* X                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
" J6 C5 w3 D! g& x                        part := @.transpOrder;
7 b+ [( z, h% T. W+ U' d# _- @                        part.move(@);-- load part" {) A8 C/ G* k  p# m
                        @.CurrIcon := "load";
! H: K+ F0 c" z4 t  [  y' K- {                        GlobalDistObj := part.globDestination;
- L! {; Y6 U/ V' Z( h( D3 y                        assignLObj := rgmanager.rgAssignL;
  y- x. L0 b& J% q# y+ t                        row := assignLObj.getRowNo(GlobalDistObj);
3 P9 }/ E2 A. O3 R' m1 O                        if Row = -1 then -- since 70+ K' X) g) w2 D& i* M$ J
                                if lan=1 then" q0 E. O' M# E
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
+ D2 c* h4 d& y/ B                                                to_str("in der Andockstation: \"",?.~.name,"\""));8 U& q- W& _2 Q  I! p
                                else
3 x" a* M+ ]" Y+ q                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),/ o. K  M; h/ ^# _0 S9 A
                                                to_str("in docking station: \"",?.~.name,"\""));                                3 [* S2 F9 ?' ]: n4 X' _2 n; A7 f
                                end;
2 x4 ]4 W3 q: X5 A) g; \5 x                        else: J1 A5 i7 K4 I
                                @.Destination := assignLObj[1,row];
3 v8 M  |4 P% Z& K% ?8 ?9 G                        end;                        3 j/ W* o$ s0 b  v/ n
                        newDirection(@);! T+ e+ A7 J) F0 C' y; E; n6 E
                        @.HasOrder := true;6 M. b/ [3 u. o; r
                end;7 N! P5 H6 @5 e1 n- m. A
        end;* T9 D$ E# b$ C! X
end;        -- of the method
: Z4 k+ ]/ O8 V3 H7 w( b( e
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 / [+ q: W  \. u* K: x- {

) ]1 m9 V3 \8 \  `: F这是AGV_putin中arrive的method。, B( s/ V4 \! a4 W0 O

+ i' Z( P" `# b; \当到达物料速度越高时,这个报警更多,7 Z/ M/ z/ T  c1 ?) Z: L- ^
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。2 ^% H! ~" z+ z
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?  ^; W7 o( f" ]' o! p) P/ l

% _: i7 N$ V/ R% X5 Y0 y( u9 L" m另外一个小建议,就是move,所有的move都可以这样
0 G, D9 ?  @, [0 Lif not move() then debug end
' V' @+ O$ ]' D# {8 I4 f3 G% D这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。. _+ g4 a/ s: \( D9 |
plant simulation中的free libraries有AGV模板,
9 ]- B4 ?  g! \! g. l0 s里面也有案例。
: a6 _' r2 T* B6 c# X& r我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。/ k4 U8 {, R" g+ X0 A$ t. J& B# t
2 t! W* d: S7 O+ h( C3 [( a
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑   X$ R% w5 a2 e
1 ?: b" _+ p$ Q# _" v% _: J
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 0 [+ N5 F3 k% S; x
这是AGV_putin中arrive的method。; f( }5 f2 O) p0 h  V
5 C+ E; ?" r" \$ H
当到达物料速度越高时,这个报警更多,

7 G+ K5 m$ h- v! s/ k+ O& H5 x另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-5 08:01 , Processed in 0.023342 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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