设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9956|回复: 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': J( r7 ^; x( I% a$ z
*/7 Z" x6 u& _3 U  V' p# D
is
) }7 h' N0 S: B+ D, D/ P9 C        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
; Z9 E6 z) Z% Wdo
$ X* G8 Z" R8 o3 s# C        Lan := rootfolder.Internal.Tools.AOLlanguage;& |3 h7 J7 d+ U1 o$ I. u4 h$ S
        if current = @.Destination -- else return
; D6 v0 P- ^) S6 R: R1 E& J        then
+ i8 ]) I9 R2 M- z                @.Destination := void;
  X5 o' l  u' J, Q                if @.occupied then
; I" i9 @* }/ I4 q3 |: L                        part := @.cont;4 G, b) y* @* [5 a5 M- f, _4 b
                        @.transpOrder := void;" Q2 F9 s6 s2 Y- Q5 x& q. U
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
7 \2 a0 s/ i+ |/ Z( i: N" L                                @,root.eventcontroller.simTime);5 Z2 s  }( f# M
                        @.HasOrder := false;
3 U5 ^: [: y+ t                        @.DrivingHome := true;
; z2 i. N( ~9 b. K1 g9 n" c0 \' i                        rgManager.tryToStartTransOrder;
2 y6 K+ o3 @4 \- L( l) G                        if @.Destination = void
0 z% A8 }) R$ E2 c( S- P2 B                        then -- no transport order for vehicle @1 v9 P; t0 |# m7 E( |4 b
                                @.Destination :=
3 `) H+ i  y2 F. S                                rgManager.nearestFreeStation(@,track.~);
" A5 G  k; s4 W$ F: z% i                                newDirection(@);   1 `( d1 z# e, h- G/ [4 f
                                if @.Destination /= void then
2 m+ B' R2 q. l  u                                        @.Destination.NumReservation :=6 J6 a: X1 s% s
                                        @.Destination.NumReservation + 1;
7 a! R; m  c: m* ]3 q. G6 F, v                                end;+ ]$ ~0 g' B4 q/ e9 V% S7 X
                                @.CurrIcon := "drivingHome";
# j$ y: K0 i! E2 C: O7 `- _                                @.DrivingHome := true;
6 |- e% g4 v1 b4 K- P# [% \                        end;* \+ H1 n  e$ L# o
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station% J% D6 E4 F% \! \
                        part := @.transpOrder;' k  h; |0 g" z( m3 M# G* R
                        part.move(@);-- load part0 Q& n; [5 P* x4 T% p
                        @.CurrIcon := "load";
! M" c* z' M2 s3 d1 H4 b3 B7 S8 L" l                        GlobalDistObj := part.globDestination;! e' r! u* @- h
                        assignLObj := rgmanager.rgAssignL;
  O) J3 v* V3 Y' ]! i# b                        row := assignLObj.getRowNo(GlobalDistObj);2 f: o: i2 m* [' z. v
                        if Row = -1 then -- since 70% l* N+ a* h) P) `* ^% N! D
                                if lan=1 then5 K, T8 ?+ J! c' Z1 ^
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),% n% u# b% V( [6 J3 Q! [: [( k
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
' J  w3 `- W3 D                                else
" j. Q; Z; l7 E- h5 {( ^) j                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
- Z: H$ B6 p1 p+ |$ ^                                                to_str("in docking station: \"",?.~.name,"\""));                               
* \& L6 a0 H4 f! ]. P; `9 E                                end;
- Y9 a& S3 @6 |0 v, [                        else
  ]( D2 h, a; C- v  k                                @.Destination := assignLObj[1,row];. W0 P0 O$ f" o. Z( l
                        end;                        % f+ u+ F4 I$ k9 t/ Z( X5 o
                        newDirection(@);  e# E. b, }) J- Z* p
                        @.HasOrder := true;
, d6 M# b, d+ d0 {) J                end;  X( J: k$ ~* Z
        end;
, N" Q* J6 x/ k9 Eend;        -- of the method9 n+ y% r% A$ ]: S/ Q: \
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 " H. @/ \+ d$ H' I& W, F0 M

7 R: T: T7 [: O& c. b这是AGV_putin中arrive的method。) {9 W( O. a. j8 v1 v* ^  Z  }
; E. _2 D: M- g3 z/ V7 [
当到达物料速度越高时,这个报警更多,2 v# U% c7 D4 G1 P6 p' @
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
" i' H( r: I  n5 i6 w+ f& Q* [; o程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?' R# H9 a+ u" ^+ y* s

2 b. |) x& T4 Q1 e. s' T另外一个小建议,就是move,所有的move都可以这样0 S; K/ E4 v+ X- l
if not move() then debug end5 J3 m* E, _% d
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。7 I, Y9 l) u( J& L
plant simulation中的free libraries有AGV模板,
8 y5 ^- V0 C  f# h里面也有案例。! Y* g9 [4 v! |7 {
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。1 g  z7 M4 S3 |+ U& `1 j' v

* O/ J; F- Z' ?8 Z! P我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
% G& z  T- v5 f# ^% x6 k5 Q- e+ _* N& B+ b, [# w- @& o
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 1 c+ ]7 c5 U3 C9 C. U$ u+ v
这是AGV_putin中arrive的method。
) r) z8 e; H) I. L
/ b" e: B1 p$ J1 s8 s) y, X/ G当到达物料速度越高时,这个报警更多,
3 ]& f/ \: d% o# |+ N# l
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-4 10:42 , Processed in 0.017118 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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