设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9947|回复: 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'* A# b  O+ P+ A8 {; \$ r. h: M
*/6 q2 I4 }8 m$ [/ C# r) b
is" x' l; m; U4 N2 j9 Z( @
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
; B8 ~$ T* {9 b. U3 R' Jdo
! ?4 G3 [  u) |6 K8 G8 {        Lan := rootfolder.Internal.Tools.AOLlanguage;' i6 z: p1 \) g& i. V/ c" }
        if current = @.Destination -- else return1 s: X& c6 ~; E% G* @/ a
        then
8 o1 h1 M$ t9 t% K7 m. T                @.Destination := void;! {9 n$ o+ ]/ L# H' A
                if @.occupied then0 j( ~' w# f* J* F4 x
                        part := @.cont;
( F3 V  \9 f. b6 L, N                        @.transpOrder := void;, A& q/ s' {5 U( C! Y& I' E/ G
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,3 R7 A9 u  `) I7 F; O6 ~  Y( [* H
                                @,root.eventcontroller.simTime);
2 A$ X( i; I. K                        @.HasOrder := false;
" Z+ D% O3 q" {" p( n5 ?" \4 a0 Z                        @.DrivingHome := true;+ Q5 N6 w. l9 H8 ~* K9 T$ j
                        rgManager.tryToStartTransOrder;2 ~9 t8 A; T2 r. X& o
                        if @.Destination = void4 \( O" i" F! \. P: i7 ~2 @
                        then -- no transport order for vehicle @1 V0 D, h3 N1 ]1 B( G
                                @.Destination :=
  @6 O+ `. b/ ~: H) K                                rgManager.nearestFreeStation(@,track.~);
. K- ]/ y1 \% `+ T! ~6 g, z0 f                                newDirection(@);   
0 @$ I- E0 g7 J0 [9 {                                if @.Destination /= void then
5 P3 m; H7 x. W# y. W  b                                        @.Destination.NumReservation :=9 v. i- K7 I( a# O& O2 M0 [. B
                                        @.Destination.NumReservation + 1;  e" z, K3 g% Z
                                end;
4 o" j( I% C9 l, B" i/ s                                @.CurrIcon := "drivingHome";
+ Y0 I; l! o$ E' z: k# e1 Q) w                                @.DrivingHome := true;& W8 @2 \2 v# O2 T2 E3 q- q
                        end;
, h  A3 x+ @- W) y: ?% Z5 V. M/ y                else -- the vehicle @ is empty, both vehicle and part are in the same dock station4 L$ m( M3 w, K! k6 }
                        part := @.transpOrder;
- N* C+ B0 F" f) D8 U" ]                        part.move(@);-- load part
+ ~& ~2 |% K6 C* F& Q8 w. T5 d5 ?                        @.CurrIcon := "load";
7 M* E) F% x& R; r                        GlobalDistObj := part.globDestination;
: ?' |: f' ~  M: }& ^% N                        assignLObj := rgmanager.rgAssignL;
3 U( i" X7 X5 x2 i                        row := assignLObj.getRowNo(GlobalDistObj);
, V, J* B# t$ N6 X) Q* f* a% d                        if Row = -1 then -- since 70
1 o8 C3 Z, t) h2 W6 `                                if lan=1 then
% w" H  Q1 A7 L$ ?                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),, S* R/ K! _, ?5 P/ Z) }
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
9 P  Y6 `. M+ z, v, o2 T8 Q. K                                else
! @& t& ?, P! S# V  D                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),& M( v3 q8 p7 l6 T" I" A
                                                to_str("in docking station: \"",?.~.name,"\""));                               
1 R2 i$ Y' K+ B5 G                                end;( x. c% p/ O" W) X0 Y- l; b
                        else' ]/ @; H- g4 w  K# U
                                @.Destination := assignLObj[1,row];
& n* v: H4 V% R: z                        end;                       
! i' O  E& s) J6 Q) a                        newDirection(@);" T$ I/ Q+ g$ V# G+ S
                        @.HasOrder := true;5 d' `2 d$ F) O; L
                end;5 z4 b$ M8 P$ W+ g
        end;
+ R& R" W6 E2 Y# M4 ~end;        -- of the method
8 ~$ M# S; ?. S
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ! r# o  @& t6 p$ y8 N
; y( g/ S2 R& o  v1 Z; C5 a  r
这是AGV_putin中arrive的method。0 p8 e6 W6 p9 q

9 O5 q$ V6 r2 Y7 p# J6 }  ~8 m当到达物料速度越高时,这个报警更多,
* {. p1 p# b! r: Z) m可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。9 r8 y' |% I, y
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
% q- R  C; q6 a+ m; l) M6 b% x, I9 W7 p! f. k2 {+ `
另外一个小建议,就是move,所有的move都可以这样) ^8 [* u/ B# w) l
if not move() then debug end
$ A3 u6 h0 M, I+ I9 s2 Q6 Q" c1 G  U7 D这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。/ ?% V( H1 y; P/ l$ F, x2 E
plant simulation中的free libraries有AGV模板,) `: D: M- C: F6 `: ^7 Y
里面也有案例。
/ i. c3 w$ r* y2 [我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
& L3 h" ?; M7 w  r
! Y+ L9 f" a$ ?  |我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 6 k7 x! D0 L$ ~/ A+ e* |) B

  {9 j$ G6 k. M那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
9 h6 t- j: K! i; }3 v这是AGV_putin中arrive的method。8 ]; y  B" p% M5 |
  F+ U/ ~/ b6 t% b! R
当到达物料速度越高时,这个报警更多,
( h# m8 r) O- I- D8 G
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-4 00:29 , Processed in 0.024544 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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