设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8743|回复: 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', K. Y0 e' }0 J8 U: o5 F
*/
$ L9 u3 A% ^' t. B6 ~, y# ~is7 i( ^7 C" i& E; g' D6 g) t" D9 z
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;; C5 A( A) ~+ D6 j6 I
do
) |. B/ a: f% E        Lan := rootfolder.Internal.Tools.AOLlanguage;( j! I4 X$ d+ P& J) W6 r* o
        if current = @.Destination -- else return3 T5 r% Q8 Z' V
        then
3 m$ A! l( Q4 \2 W( ~9 N                @.Destination := void;3 t2 k8 x) i1 U9 y+ ?
                if @.occupied then. s, U' R2 J+ ^: J; R) [/ C" m
                        part := @.cont;; B; r2 \) ?; v+ [! w
                        @.transpOrder := void;
! P  K  g6 H8 O! |+ m% Z) d# _                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
& J' V+ t; \1 e2 o7 v' s                                @,root.eventcontroller.simTime);$ I& y& B% D) @  M, W$ `3 n: c  ]" U5 t
                        @.HasOrder := false;- H# O9 B4 h( x% u8 I! A; O/ k5 Q
                        @.DrivingHome := true;, Q2 ?6 g; u  J
                        rgManager.tryToStartTransOrder;
  d* A8 `. J! c9 @( E) W                        if @.Destination = void, e9 E; f# ]# @$ |9 g$ ~% s4 I
                        then -- no transport order for vehicle @
( `$ c" T9 i- r                                @.Destination :=) b) E5 |/ i3 ~/ p
                                rgManager.nearestFreeStation(@,track.~);4 p; b( g- s6 v
                                newDirection(@);   
2 _# G$ \% ~7 e) w* w% u$ C* e3 J                                if @.Destination /= void then
  o" x2 N4 |- {; e; a) `% Z# P5 ^                                        @.Destination.NumReservation :=
, \! r! A; e/ D  G0 n                                        @.Destination.NumReservation + 1;
& b8 X2 W9 l; \, `4 t7 ^; ]                                end;7 l' `" Z* y  j
                                @.CurrIcon := "drivingHome";
- ~  N4 u8 w! H+ j                                @.DrivingHome := true;
% Q1 G! o, B6 u* a/ e                        end;
% C! T1 T5 I  X0 ?7 {2 c) o* Z                else -- the vehicle @ is empty, both vehicle and part are in the same dock station8 G8 n7 W6 z" Z4 Z
                        part := @.transpOrder;
' t0 E9 w3 m, I' y* G& T+ U                        part.move(@);-- load part
+ ~# |1 K2 I6 g+ u" j7 {* m- Q! ~                        @.CurrIcon := "load";
: H' n7 k, c3 L( v( x$ z: [) g( M                        GlobalDistObj := part.globDestination;3 B. r4 O$ c9 J9 |+ W
                        assignLObj := rgmanager.rgAssignL;' Q0 |" ?+ G( ^4 L2 ?) U, g
                        row := assignLObj.getRowNo(GlobalDistObj);
4 ]1 G1 f* i: a$ x/ l                        if Row = -1 then -- since 70
$ Q/ d' E7 a4 A7 m, w) }/ |. F6 T                                if lan=1 then
) y$ q$ J! X- n2 J/ |6 d. Y, Z                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
8 S2 c3 G( w1 y* \, d                                                to_str("in der Andockstation: \"",?.~.name,"\""));- s1 m6 c5 Q& {
                                else$ ~8 t& Y% K: V& g4 X4 \
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),' W! H- V+ T: w
                                                to_str("in docking station: \"",?.~.name,"\""));                               
! B/ L. H3 \4 e) K                                end;
4 F) z( t( f! P# e. G" s                        else- A; Y7 s4 M# c1 a# B2 D- j
                                @.Destination := assignLObj[1,row];
4 N; W* A( z0 @& Z                        end;                       
2 z6 v' s3 D4 Z* X, b                        newDirection(@);  r! o2 P" l" _8 R7 P
                        @.HasOrder := true;
/ N% f  j5 P- `2 w8 K- X                end;
" i2 \1 |. H3 f& I- i        end;
1 j" S" e+ z% k3 J9 G% nend;        -- of the method: f* B! w9 x6 G
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
8 I: N6 A" h9 l6 r, z! i) |- c1 x& x4 f# Z' E2 p' q2 Y
这是AGV_putin中arrive的method。
0 G7 }0 V% x. L6 y# i+ S- t6 O
. a, a& ^6 h/ q# w% @# P当到达物料速度越高时,这个报警更多,
7 N+ k+ M) g( d+ l$ D- p可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。& ^9 R' J# f/ l( p: h
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
7 r, l: m. I) G9 Y' ]3 t0 L
9 l* u( o* L& Q" q/ o- N另外一个小建议,就是move,所有的move都可以这样2 M: e" L" ]2 C" }2 r6 K/ L
if not move() then debug end5 R# i- n" x) g( x! H2 y
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
  |& x: d1 v  a  x: hplant simulation中的free libraries有AGV模板,
4 C8 B% w8 c! q" I里面也有案例。
& \$ n/ B+ T1 w2 S2 n1 K8 W我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。8 f) J# h" c1 E! I: u
- p0 t2 l: F5 j& V5 Z! U
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
/ S$ {8 o: i/ O/ [" P, K, X" H, z; Z$ N( f) u
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
, f! r4 J1 y! V% w  \- C这是AGV_putin中arrive的method。
: Z$ e- f3 y' v" k2 y+ O4 O
1 O* b/ z; L5 {! s9 C% X5 w当到达物料速度越高时,这个报警更多,
4 s. T5 ^; c$ h1 o! ~
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-23 21:44 , Processed in 0.016257 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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