设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7877|回复: 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'
, o7 o+ ?& x% J! W. e* A, C+ q*/
" Q# g6 I5 |) _# m. Ois- y1 U& g9 Q! F
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
  g& e( M" F# @* m' v. F8 Ado0 _" F6 Q; t0 c- S% E. y4 S
        Lan := rootfolder.Internal.Tools.AOLlanguage;; A2 Z8 r# L, f4 p, ]
        if current = @.Destination -- else return1 l8 ?& _% u' V1 O2 V, X, F
        then
9 S' c( A7 O6 A3 f2 @4 h: \% L: R                @.Destination := void;
1 Z  P) [& p* q2 ?$ J                if @.occupied then) _0 z* y5 a* a: c5 H0 j
                        part := @.cont;
8 o1 a2 ?. t+ Z0 }7 r) n% p$ r                        @.transpOrder := void;* e/ n' n5 N9 n9 S7 S9 l  ?
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
: E( S1 ]" i5 K/ ?% w                                @,root.eventcontroller.simTime);6 e9 Z( k4 e5 o3 G# Q; Z& e' K
                        @.HasOrder := false;0 j1 B& V0 _; @" }8 \; x5 w9 F/ J
                        @.DrivingHome := true;
  J1 R) ?2 ^+ L                        rgManager.tryToStartTransOrder;# I, y5 G! d$ |% L
                        if @.Destination = void! N& p$ A1 i# F8 L/ j9 R
                        then -- no transport order for vehicle @
$ |" u6 a- O. P, u7 S, n. g- F. ~                                @.Destination :=% Q$ `$ w* j3 M
                                rgManager.nearestFreeStation(@,track.~);) Z. P' X- ~0 M, A
                                newDirection(@);   6 q( _1 K! }) m2 N
                                if @.Destination /= void then
! x( C4 b8 L' }* P                                        @.Destination.NumReservation :=
: @6 o# R' H' x" g+ h$ i                                        @.Destination.NumReservation + 1;
' X- x( N% d: \( k7 u# Y0 I& d; a                                end;
9 f' S6 p! b) K5 G- ~/ a                                @.CurrIcon := "drivingHome";
5 l9 a- D2 @4 t" ]/ L                                @.DrivingHome := true;
5 K4 B6 i5 O; o. g0 T/ Z                        end;
8 @! J5 D# n: w/ X- U% z' W                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
4 |3 O, g% }% P) p, G9 H/ b7 N                        part := @.transpOrder;0 u- J' N  G( T
                        part.move(@);-- load part) M$ e) T6 v- T5 Z7 X5 ~! x- o$ _
                        @.CurrIcon := "load";! T8 S" e5 a4 |
                        GlobalDistObj := part.globDestination;
, T- W" V4 w5 f" i                        assignLObj := rgmanager.rgAssignL;
! W# Y$ B5 c) ]& ]                        row := assignLObj.getRowNo(GlobalDistObj);
& ^- |8 A( i1 q                        if Row = -1 then -- since 70
. B' H  @# t" b* |# z, V( J                                if lan=1 then
2 x  X' h0 x6 P* J1 a/ G) J4 b$ b                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),& x# m/ |7 e  r" ~
                                                to_str("in der Andockstation: \"",?.~.name,"\""));5 k5 B9 _" A- i
                                else
$ i  i) a- Q, a$ ~0 @4 |2 N. v+ y! s                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
7 h, W+ s: _) I, _0 ]                                                to_str("in docking station: \"",?.~.name,"\""));                                5 `3 E: ]  c+ ~0 f7 c
                                end;
$ g" a5 S4 M9 D* ]2 j                        else, ~2 I" b" D( w* R
                                @.Destination := assignLObj[1,row];
+ T5 t" j/ L# W2 q; M                        end;                       
5 N0 @  [2 z# Q7 d) P                        newDirection(@);$ A. p+ A8 Q3 k( T) b2 a6 n4 g. e
                        @.HasOrder := true;  s+ v& J% Z0 l+ A
                end;7 B1 s" M. Z* c% S' p% h" @! A( }# z; X
        end;
: E9 X: S. ^' W: H; j9 gend;        -- of the method
6 W) y3 X  l% B1 T
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 / h) p* c5 Z' M$ ?& Z

+ @/ o2 u& ~) C$ M( Y& M' e2 `5 j这是AGV_putin中arrive的method。: F1 V2 W# ?$ R* @1 J6 b
8 [8 \5 n8 Y0 w* X2 m7 ]0 ^, k
当到达物料速度越高时,这个报警更多,! E9 I. ?7 X3 `, v8 G  F- `
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
/ n* `% w# c! A0 U程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?& @$ h8 i- f+ y  g( N) J3 w
8 P$ k0 \! j6 x( U" L) A
另外一个小建议,就是move,所有的move都可以这样, {& a! t: l# s' q/ U1 S9 y3 X
if not move() then debug end
3 g* b% R: g0 ?0 w2 R0 S这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
6 ~* [- V( y8 M( R$ Dplant simulation中的free libraries有AGV模板,6 V2 ~+ v. i, _' X
里面也有案例。7 A) r$ u# d' p' i' @4 M8 Q) x
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。9 ?0 y* Z  }  b. T5 G! ~# w  l. D
% |: u% @% v+ }! V5 H
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑   W! }; n! _/ l( Q; [
0 Y* A6 n' U) [$ g
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
+ z" i5 I  m" b" O, \! O这是AGV_putin中arrive的method。" l1 X. }& e7 v" M2 |3 K- i
8 Q6 J% p' t) y2 P' R3 `
当到达物料速度越高时,这个报警更多,
$ c: i; c& b$ j  J+ w3 s4 W5 ^
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-2 22:14 , Processed in 0.017405 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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