设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9560|回复: 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'; r( a) T- j0 Q4 T7 V
*/
* }6 [- Z& Q: v7 R" _4 }is0 _2 E& t  K7 S# r: t0 b  c
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
* K. g* H3 ~9 b# odo6 g3 @: B( _' j% T1 `
        Lan := rootfolder.Internal.Tools.AOLlanguage;  q) |. q0 O" x0 m4 S4 K
        if current = @.Destination -- else return
* G7 V9 Z7 g" I        then
$ V" |( T/ I5 w1 J1 l                @.Destination := void;% P# Y. @' @1 R5 B: H
                if @.occupied then
! g2 R3 P2 n" e  }3 c4 ]& S! D  O* O                        part := @.cont;
3 N  v0 Z6 u, N* G% ~* {% q                        @.transpOrder := void;  {: n8 d4 h- n1 ?; P/ _3 v! y
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
/ o# e4 m2 H* {7 ?5 C8 M4 X1 ]                                @,root.eventcontroller.simTime);8 O' \% d/ U! o. _$ ]; F( i4 M
                        @.HasOrder := false;
! X$ r  B8 d0 ?9 I7 e8 d8 ~                        @.DrivingHome := true;
3 Q$ B- E5 n  t3 a( P' Y3 W                        rgManager.tryToStartTransOrder;3 D6 w+ `5 {7 D, T/ t$ j( J5 g) d
                        if @.Destination = void
2 c/ O) M* L' X0 t                        then -- no transport order for vehicle @
, O, @. H* S, D& x2 s                                @.Destination :=
% d0 R# }% D5 f# r1 s; }0 s2 r. o                                rgManager.nearestFreeStation(@,track.~);
* ^9 _) F& x7 e3 }                                newDirection(@);   
  K  j, q, \& H1 {8 W+ o                                if @.Destination /= void then: q$ H1 G" j; V; c
                                        @.Destination.NumReservation :=
+ H3 `: A+ ?8 V                                        @.Destination.NumReservation + 1;
1 N0 Z& L! \& l  C+ ?  B                                end;& F) U) a' @. B  @, }5 o
                                @.CurrIcon := "drivingHome";
' l$ n8 P' j% y4 D+ I                                @.DrivingHome := true;
2 W7 D% Y' P3 ?                        end;" r- z* b! `, v+ R, p9 g
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
/ }7 v1 X9 G) H" [1 j3 F8 K  b                        part := @.transpOrder;- {8 r7 s: l4 ~7 c9 q
                        part.move(@);-- load part
/ T/ K3 X5 m1 }, R3 _                        @.CurrIcon := "load";
3 R1 S- `% U: Q0 k* |                        GlobalDistObj := part.globDestination;
  E2 |$ F: I; y! ]2 L& P                        assignLObj := rgmanager.rgAssignL;; g8 i9 _% y$ h; Z
                        row := assignLObj.getRowNo(GlobalDistObj);
6 [. r  G1 c  _                        if Row = -1 then -- since 70( F7 k/ }. |4 o
                                if lan=1 then
4 {  T$ }% K( Z- `                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),1 y" X: i, @- g, l6 Q
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
, z- s" @7 }( {0 A6 ~  ?) A                                else, ]) \5 h: [( N4 u4 J4 c
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),# `3 g0 ~8 ]8 {% u9 ^# p! x
                                                to_str("in docking station: \"",?.~.name,"\""));                               
# L* m1 J8 I/ Z                                end;
; i+ n5 H- ]; Q% Z8 j9 x                        else1 ~3 S9 H' b% o1 e( W; C2 ^* m
                                @.Destination := assignLObj[1,row];% T8 U- G  d% P' ?/ b4 d
                        end;                        9 S- o* T7 J* f  y4 ?" v
                        newDirection(@);' J1 n& N, L1 a# O% M& U
                        @.HasOrder := true;
6 T+ c2 ~  I9 Y) p1 I                end;
. W% k2 Z9 k! S% H" b  C1 O7 h        end;
" t6 P; y7 a& k" W: Y3 a: pend;        -- of the method
- s3 Z1 E2 T( d5 \' A4 h1 ^
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ( _. Y! {% z) f/ |* x1 f7 q

3 F* x% d; d0 i: m5 i9 l这是AGV_putin中arrive的method。
* E" p/ v( \9 C  L; h+ Y1 i
" }7 ?/ @$ h5 q8 v$ [( X当到达物料速度越高时,这个报警更多,
. ]0 b$ w. H% n+ d& R可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
) l; ]! y7 y: v3 j程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?4 @* _, A; q, b% p0 c% Y0 u
7 C/ |2 J8 c2 W* b
另外一个小建议,就是move,所有的move都可以这样) ^; e+ o% k# C3 ]9 c5 p
if not move() then debug end
# w4 |  b2 x% u1 `- s: {这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
2 R) O  t* B2 b8 `! R, Q2 ?plant simulation中的free libraries有AGV模板,
8 o. k. Z! M) {# N. A- D里面也有案例。$ T( D  Z- Y% y' E; K& ]0 I/ R
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。6 }# ^, \) @& G' `9 N# y* p+ {5 A
  }  ^4 G" |0 z2 e  r5 k
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
4 S! i! G3 |7 f; p
  Q* l$ B) @4 N那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ; F6 H' k' K+ |6 j
这是AGV_putin中arrive的method。
% L( A) n! {, e; L9 z% x  ^# E& o8 [! ~! w3 s  i
当到达物料速度越高时,这个报警更多,

, F7 m: Q! S  V, K7 z' I另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-8 02:01 , Processed in 0.019743 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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