设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6581|回复: 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'
% N# c3 G1 @4 [$ z' r*/
7 R7 O& c* s6 Vis9 |- o$ Y1 x2 D; _0 T# w( ?0 K
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
5 }: Q. X4 b; x; jdo
  y6 u1 ?, T1 f' N0 {  \        Lan := rootfolder.Internal.Tools.AOLlanguage;
/ _$ U! r6 M  Z) N  w$ x3 B0 \        if current = @.Destination -- else return
& k: f# }" ^5 a" f/ s: L        then
8 H8 t  k" I" y( R" P9 V. Q& N                @.Destination := void;( ?7 Q' P5 a/ p. B) f0 A2 e2 F
                if @.occupied then
& D9 A" O# Z: [7 @1 j% @/ d7 T: c                        part := @.cont;
! o5 i: O8 P6 R5 B1 K9 E0 \                        @.transpOrder := void;' M5 j) i- H/ C$ b; n8 c  n/ k; Z
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,9 }7 _) ]5 g9 [/ k% {
                                @,root.eventcontroller.simTime);
2 H- @! n; {( p: F                        @.HasOrder := false;6 e/ X4 v6 x( `+ Z% B3 S8 j
                        @.DrivingHome := true;
0 o1 I# p* e+ M5 A2 T, v6 b                        rgManager.tryToStartTransOrder;# j$ j: e& S7 K4 D6 s
                        if @.Destination = void
  \) x+ r2 i6 _                        then -- no transport order for vehicle @
( R( _; H6 ]+ B$ l% L3 P                                @.Destination :=' S) p: e  Y% x  J2 w
                                rgManager.nearestFreeStation(@,track.~);: M! s. ]. p- Q
                                newDirection(@);   
( I2 Z, p) l2 b  ?+ Y0 A6 u                                if @.Destination /= void then+ a% ~: t2 |; k4 A, ~* r
                                        @.Destination.NumReservation :=# T: N! I7 i; _2 {" m9 b; m
                                        @.Destination.NumReservation + 1;
: E! k" r7 T" H. [, z                                end;) M' {! ~& s# J: u: t, K& u
                                @.CurrIcon := "drivingHome";
2 \' h- J) R, _6 S+ _) M# b5 f                                @.DrivingHome := true;
4 w; ^7 Y3 I7 N2 w2 b8 t                        end;
+ |' ?+ N, `% U9 ?1 E# [                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
! y% O- N, h" ~$ F% [; q                        part := @.transpOrder;6 U4 {2 ?5 F4 f* V3 }* @* i
                        part.move(@);-- load part
0 l. C' E! F0 o# D2 ]                        @.CurrIcon := "load";4 n) X9 n$ n/ u; h" Z/ X
                        GlobalDistObj := part.globDestination;
) |- `; {3 c, z- X2 f                        assignLObj := rgmanager.rgAssignL;
( G" q. [* m1 O: x6 S. y                        row := assignLObj.getRowNo(GlobalDistObj);
* a( f$ A% k0 m6 |6 d$ m                        if Row = -1 then -- since 70
) u4 |; ^' R" u' Z                                if lan=1 then
+ T$ Z3 L, G& f4 V+ D) I- g$ ~                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),& T: }: b2 |9 I
                                                to_str("in der Andockstation: \"",?.~.name,"\""));' f4 v" F7 @+ A4 @! K- t
                                else9 L! a& O* u3 S* n8 \+ {: Q0 ?4 {( d
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
# V. i8 B) l2 ^                                                to_str("in docking station: \"",?.~.name,"\""));                               
8 f* f* w1 s1 q  B7 K6 j7 _                                end;
% _: b) L9 `9 ^% `2 e* e; z9 r                        else
8 r% u8 D2 a' i3 l: m# k                                @.Destination := assignLObj[1,row];6 w. ^0 V; P# S: w, c% A' |
                        end;                        ; l5 ~7 a# S$ ^  ?1 d
                        newDirection(@);0 o! W% A, F2 ?4 d
                        @.HasOrder := true;. c2 X1 j  _1 c, L5 {( {/ P7 a0 `% X
                end;1 X% t3 z3 d; }' Q% j
        end;
9 x8 |1 K, f7 ^' Aend;        -- of the method
0 X" x0 E1 U! }. Y# e7 a9 g
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
# i/ z4 `4 g1 k& l2 \$ b) R$ {( T' I6 n- A  S/ h, u
这是AGV_putin中arrive的method。3 ]+ [7 j; J0 b. k$ z4 Z

/ k4 [0 M/ A+ q; t7 a9 l当到达物料速度越高时,这个报警更多,
0 f. _3 R* F( o; h可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
( F" j3 a! s" Y& e% i5 _6 S! N程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?+ r7 s- c3 p+ o# x  x. T) S

! e" V! z/ I8 P3 S; a7 h* E1 T8 s另外一个小建议,就是move,所有的move都可以这样7 c1 e: `4 e; N) }( f
if not move() then debug end/ m/ H$ ?% ^0 H5 c7 D& ?. j2 A
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
- z& N  _" ]( q3 P5 Mplant simulation中的free libraries有AGV模板,
1 I+ I, N) [: `  T: p7 W6 A里面也有案例。
7 A9 L  P. O4 u6 t; O/ P' @- ?7 h我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。& F9 Q' l+ x; n- n" u4 C
6 i/ }5 w( l' d5 o
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 4 d- a" N/ O* M! Z* ?+ N0 `
: G. R7 Z/ X# K
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 5 v% P9 S, Y- N% {! a! g  _
这是AGV_putin中arrive的method。
* N0 c$ O0 \8 V4 R& {. F& t
$ j9 p/ _' }" r+ |. E6 Q  a当到达物料速度越高时,这个报警更多,

4 C$ n9 s( X# _+ _) q( v/ a/ \6 ^另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-14 03:03 , Processed in 0.017931 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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