设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9762|回复: 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', f  w4 h' f; V8 J
*/1 j& D) F3 Y' i! d  G
is
! ]6 d! J0 T% K  w        part, GlobalDistObj, assignLObj:object;row,Lan:integer;' X7 k8 }: v9 J! ~) E( ~1 W/ C
do
  J' l+ S- J: Y. K! ^' m        Lan := rootfolder.Internal.Tools.AOLlanguage;& Z4 Y6 }9 j: O
        if current = @.Destination -- else return3 {' L' K$ O% E
        then: u! U0 b* e5 j0 t  m6 P. b
                @.Destination := void;
% s7 D0 d7 }( C6 H                if @.occupied then$ c- w6 r- k2 Q; m
                        part := @.cont;7 y3 ^( T& q/ u) i+ _
                        @.transpOrder := void;* \$ m: ^+ p5 f7 j7 _$ D0 F; f; S1 r
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,$ k& |6 a! H7 @; W/ @6 M
                                @,root.eventcontroller.simTime);9 l: i- E. K4 Y* y  X6 D2 P
                        @.HasOrder := false;: ~1 t- d$ N  `% \' `4 Q
                        @.DrivingHome := true;
% F% D3 s( {3 \3 N. ~0 S                        rgManager.tryToStartTransOrder;
/ `7 v9 b0 r' Y$ P# i                        if @.Destination = void2 z( [( M5 P% V) R, C" G
                        then -- no transport order for vehicle @" e  i( G5 [( L+ ]8 d5 X+ ?: a* [
                                @.Destination :=( a* z7 X! g) H, u- Z7 j4 r
                                rgManager.nearestFreeStation(@,track.~);
9 J: ?" U1 f, `4 \$ b8 c5 @1 h+ m                                newDirection(@);   
: {) y1 b0 a9 f                                if @.Destination /= void then0 v( n! A+ }+ I) |
                                        @.Destination.NumReservation :=
4 A, [# x: H- `$ R, U1 X                                        @.Destination.NumReservation + 1;
" q3 d. B4 d+ t( L5 R" A                                end;
. i1 p. R0 D. H6 d1 T                                @.CurrIcon := "drivingHome";
8 G; }6 \- J) z0 [0 ]( r! \) O                                @.DrivingHome := true;8 w. e/ [% M( U8 ]& M* \
                        end;1 e" U) {! r9 O
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
6 @# E' Y, z2 L: |' _/ I                        part := @.transpOrder;' A5 c. ]/ m7 a
                        part.move(@);-- load part
0 Z$ w) P5 Y: @. p8 L/ o                        @.CurrIcon := "load";: {% `2 Y( F5 v' O( s8 q) q! T! W$ T4 L
                        GlobalDistObj := part.globDestination;7 d2 _# C+ x  i9 O! r0 g: \9 G
                        assignLObj := rgmanager.rgAssignL;$ K6 n3 s) j' c( p4 I
                        row := assignLObj.getRowNo(GlobalDistObj);. i, Y5 J5 g( m! p1 Z
                        if Row = -1 then -- since 70
( F+ i, \1 b! B1 k, B- R# O/ |                                if lan=1 then' u% N% ~3 R7 B0 P9 r
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
8 J/ G4 `, B: o8 M2 M/ C                                                to_str("in der Andockstation: \"",?.~.name,"\""));; N# {8 ?4 ~2 L  ^  D8 R  y
                                else1 n" i# l6 R) _# C
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
& M7 B, b# R. [( \6 E( `" n                                                to_str("in docking station: \"",?.~.name,"\""));                               
/ u, O+ s+ Z7 X, Z                                end;
9 a$ Q$ |6 t! ?$ e! b8 Y6 [- e                        else- M8 p4 v+ z/ t& K
                                @.Destination := assignLObj[1,row];
$ c+ @2 C- H8 _) w2 V- T1 H                        end;                       
  O9 k0 S& @9 O/ x, H                        newDirection(@);
9 X& h3 ?" R! w4 D) ~1 p, t: |                        @.HasOrder := true;% p+ X% P8 R9 y( |3 j( m
                end;
# b# g! D+ V4 k' }! A" n0 v        end;
, R( l; ^5 \  {1 _end;        -- of the method2 G; F, v, _+ \; o( u5 l8 r) Z
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 3 L$ Z0 C: b4 j5 Z8 B6 p5 `% C

! X" Y% s. I: Q- S5 {+ `# q$ v这是AGV_putin中arrive的method。
& o5 ~: P: c1 f$ r: M$ T1 v9 P8 x- J. F/ s9 M# e2 K& p: y9 m: ^
当到达物料速度越高时,这个报警更多,
6 ~2 Y# N$ q7 L$ K) {1 ?9 Y可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。: _5 W5 H  q+ B' i; [% M
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
# A% j  u% j$ i9 b& H& _( e  S* [: n8 @$ u+ H- E
另外一个小建议,就是move,所有的move都可以这样
$ s5 f$ b8 y+ Qif not move() then debug end
# `) w5 F& o% b9 D这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
: L9 x1 z' W. g0 v( @+ C8 V: Zplant simulation中的free libraries有AGV模板,
( o9 h% v3 b6 C里面也有案例。6 F+ w( N  u" i/ J0 _; Q, e! q
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
& K! ]9 f4 h& y8 M5 J( l
# `9 z3 `8 v& w# Z! S1 A/ m我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 . \5 Y9 X, y! _) `

$ d5 M, }. u2 x5 Y) ?0 k那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 & y1 M3 V( l' p7 |
这是AGV_putin中arrive的method。; f* y! B; B; e# u
' [8 W5 X5 Y/ m  C0 m
当到达物料速度越高时,这个报警更多,

+ K- q( E9 Y! t/ S. S- ^( Q另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-23 03:21 , Processed in 0.018436 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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