设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7560|回复: 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'
& [6 _* b) d: g*/) U$ n; e# C, G8 y# G  K
is: v1 a2 D  S8 H8 e7 Z
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
5 C5 n! G) {% ?) q, M# Zdo
/ W9 Q( {6 u  g        Lan := rootfolder.Internal.Tools.AOLlanguage;" B* Z6 e5 J, d6 Q, `
        if current = @.Destination -- else return
) [5 F5 @' d: r6 R        then+ [# d/ e8 z6 ?
                @.Destination := void;
, s+ M# c& l! H# i' Z5 C' V                if @.occupied then8 X0 |- H4 Q! Q6 Q/ f
                        part := @.cont;
7 Z: w  N) J7 U/ V% o4 Q. F8 o4 `                        @.transpOrder := void;
4 J  W. K( o6 L; z& J; k+ s                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,3 z. ]; N( R& I& A) E* j6 e4 o
                                @,root.eventcontroller.simTime);
$ H4 y5 u5 h9 i                        @.HasOrder := false;1 ~5 D2 R* I' O: x# E# b# Q! z, e
                        @.DrivingHome := true;1 X/ s8 t  k- A) j8 t+ H
                        rgManager.tryToStartTransOrder;
1 M( q& Q& Z$ r, K9 Y4 L                        if @.Destination = void
0 X) u$ Z, g' X* {6 ^; I7 l                        then -- no transport order for vehicle @
6 d4 F5 B. o& a; a                                @.Destination :=8 q% [- d5 x$ d+ v; `3 M
                                rgManager.nearestFreeStation(@,track.~);; f' z+ Q. r9 E9 Y- V
                                newDirection(@);   
8 I9 }0 P; ^6 [$ x) B) \                                if @.Destination /= void then* n+ S) S8 Y' V. f* i1 u
                                        @.Destination.NumReservation :=
) S0 T3 Y: A, i8 W                                        @.Destination.NumReservation + 1;
  v4 d% K0 f$ }                                end;3 @' h' D" F8 ^" ?1 A- B+ @
                                @.CurrIcon := "drivingHome";8 s% k! u' ?; t" i+ X2 s
                                @.DrivingHome := true;! h$ Z+ O; z' e- N( _, P# J
                        end;' j% J4 u' K& M% i9 w3 U* `
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station, L+ t& f. V1 H
                        part := @.transpOrder;
7 Q* w9 H* `" J9 q                        part.move(@);-- load part
! C% V  s% S) g: a                        @.CurrIcon := "load";5 t1 X0 G, ^& }9 h1 I
                        GlobalDistObj := part.globDestination;
5 j# m: V6 ?4 S% Y                        assignLObj := rgmanager.rgAssignL;
3 `5 _* r" Y- W3 ?3 M5 e                        row := assignLObj.getRowNo(GlobalDistObj);
1 d3 l* q! S3 |; ?                        if Row = -1 then -- since 70
$ w8 J0 c! p* k8 y5 }                                if lan=1 then; P. S/ ?3 u& ]! k4 W' [! o. W
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
: j; H6 e  p& Y- v                                                to_str("in der Andockstation: \"",?.~.name,"\""));
8 b; U: e( d  o                                else3 c+ m4 u$ M* A9 V& H
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),7 A1 j$ e' P9 M0 K
                                                to_str("in docking station: \"",?.~.name,"\""));                               
# h4 G7 u6 W$ F; V8 H                                end;
8 h5 v4 M9 J2 E0 j. H+ `7 s! K                        else) Q& h, e) H: K6 f6 k; c
                                @.Destination := assignLObj[1,row];
/ z4 _: Y0 v9 c                        end;                        9 \% S) ?$ z# g7 a; @: {
                        newDirection(@);& [# l4 H7 j/ U/ Y+ o# ]  C! ?1 U
                        @.HasOrder := true;. b/ U2 b# o, D+ ?, G% [/ M
                end;
8 \5 K, b( J! R. u( F' C        end;
$ J/ F4 S  B; N" M" hend;        -- of the method8 B+ Y, @9 Z7 A$ R- m( e
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
5 [8 f7 V  s8 |. C) [, i
8 Z: k' h) ]+ o" x% C这是AGV_putin中arrive的method。( c& @9 ^+ y8 ~& v, l
4 q5 ?/ ~1 F6 O3 h
当到达物料速度越高时,这个报警更多,) R  I" ^5 B% Z- s" g3 r4 V
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
7 S9 P  n1 P/ f: X1 e& @程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?. c( n5 Y# Y8 Y7 h) s

, \$ v, k" _% `5 }另外一个小建议,就是move,所有的move都可以这样3 d- O3 h& z, g3 K/ s
if not move() then debug end
0 O: m8 O  ?( J这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。( V" X, G6 o. D# Y8 B
plant simulation中的free libraries有AGV模板,
/ M5 A; }  v1 r. t$ P( }$ o里面也有案例。
- u- b- {7 {/ t( m2 \1 `我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
" B' M) c( e+ S) ]3 x) V8 `4 v+ P  o* k( P# o
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ) M2 \# y) _6 ~! C* |
" V5 r5 l) S: M+ H
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 & S+ w) [. H9 {+ ~2 T9 s# G
这是AGV_putin中arrive的method。9 \6 K* v6 a( I6 M) x
- C, D0 p3 e/ l- _' G
当到达物料速度越高时,这个报警更多,

: e" N# f# G# l+ U; F9 O; U另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-17 20:51 , Processed in 0.019382 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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