设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7392|回复: 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'
, z. a" D; t& B* }2 V+ \: r*/
( e5 i& S9 H, bis
8 o- a* L* t: Y( V) t4 M        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
/ r3 Z8 H' E5 R6 K- Q/ }- wdo3 G4 U# ]  e) Q. |
        Lan := rootfolder.Internal.Tools.AOLlanguage;
, I: N5 M6 x; C        if current = @.Destination -- else return
6 @6 }8 R& I2 x0 z+ ~* h7 K        then1 W/ n5 ~, V. K+ R+ W( ^, O1 t
                @.Destination := void;
2 @6 h0 a0 s% u" E; I$ w                if @.occupied then1 p9 v/ E$ Q6 j! z# u7 c
                        part := @.cont;7 F& R% C; O! m4 B- d2 H& R" L
                        @.transpOrder := void;
2 U6 J1 F# ]& x% }6 C* C* K                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,6 e. P/ R8 J, \5 o1 `
                                @,root.eventcontroller.simTime);2 C: r7 E4 [- n: ^" k
                        @.HasOrder := false;- H% \. d2 u! P% W
                        @.DrivingHome := true;
; w) o% Z, p8 k; x                        rgManager.tryToStartTransOrder;
4 N1 w8 p, ?+ G. }                        if @.Destination = void, j6 i% u3 @0 ~; n
                        then -- no transport order for vehicle @
7 D8 P" B0 [8 @( r                                @.Destination :=
: c2 k$ f7 {8 D% y  p& K                                rgManager.nearestFreeStation(@,track.~);
" i# V6 N! y) ^3 E                                newDirection(@);   , r2 v, l  \0 `% t1 i
                                if @.Destination /= void then
# t- P# i5 n* T: q                                        @.Destination.NumReservation :=
9 K8 e+ H0 |% P4 R+ y# A. G                                        @.Destination.NumReservation + 1;1 \8 U% Q$ E6 G1 @; t- o
                                end;
$ Z$ ]. L* N3 H3 y" }2 c9 D                                @.CurrIcon := "drivingHome";
& f# B* C& ]6 H2 ^                                @.DrivingHome := true;
( Y, _7 d- X4 {( Q7 q! {# ?                        end;( U( z5 e) Q" `0 S5 X; j
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station9 l- j9 i0 Y4 z& V  R! Q6 w& n+ t
                        part := @.transpOrder;, B( @2 N; b7 u- }% C
                        part.move(@);-- load part5 `) S* |3 e; ^& w
                        @.CurrIcon := "load";3 D) g: ~- s+ v
                        GlobalDistObj := part.globDestination;
. @2 C% c0 p# u. f. Y/ m* C                        assignLObj := rgmanager.rgAssignL;
1 S4 _9 ~% ^" S                        row := assignLObj.getRowNo(GlobalDistObj);- u4 ^& }7 C: F3 B
                        if Row = -1 then -- since 705 P1 n- @' j, ?; N  z1 n& f+ u
                                if lan=1 then: i6 l( ~+ {) k
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),% s/ F) U# d# K1 J( P9 [6 X
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
1 H1 P" e: V9 R+ _+ X+ ]* R  ~/ }. z                                else
: k. X# @; S& y3 t: `                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),0 X6 y+ Z7 o; i# q2 X. U
                                                to_str("in docking station: \"",?.~.name,"\""));                               
) s- K* Q. H: |' @; I1 s8 M- P7 C: L                                end;
3 ]+ Y0 T: U% V! s5 g+ P" L                        else& S6 R4 h- S: i% u
                                @.Destination := assignLObj[1,row];% r1 a$ ]: i1 l; l
                        end;                        ! m: F# G( z1 B9 F* A) d8 h
                        newDirection(@);
( @/ _* O( J% `/ k* P                        @.HasOrder := true;' E- Y( E# o7 R2 ~/ \4 `# |
                end;
# X! t2 _0 l$ s7 A        end;1 ^8 Y. v% G: E2 T2 M, w% ?8 e
end;        -- of the method- \7 E) Z/ z; q1 K# O) d! v. g
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
: O. Y; ]% e! l/ v$ J% z, {  g. R" j0 Q) z& ^
这是AGV_putin中arrive的method。
. Q( I3 R4 q& }
3 _/ N/ R% z! y. c* n1 |% `: b& K4 h当到达物料速度越高时,这个报警更多,
4 ]+ z# H, ?: C3 z% g可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。2 @: L# G$ K7 ?8 x4 R+ c: M: Y2 a* R
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?( ~9 ]# S6 S$ A: S! n4 p/ i* Y

* R$ j3 G/ n: A( K1 @# i另外一个小建议,就是move,所有的move都可以这样
3 F' z5 h9 d9 @/ r& n# Sif not move() then debug end
! V9 \  p. p" Q这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。1 Z( [, U9 N# L- F! O4 T/ u! V
plant simulation中的free libraries有AGV模板,. H* g; l/ Y' q6 \+ y' @
里面也有案例。
( ?$ ^5 _9 C' h& D* B4 a我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。( ]9 x1 j9 f, m/ g" x+ p. b
2 N6 e- Z# b! @7 W+ `8 M2 A5 F
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
5 w2 y1 H2 j& Q/ ^/ Z. f, n3 ~
( p# `- S5 t; F8 b+ b9 Y那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
# r/ e# N; i/ J' t/ }) i! L这是AGV_putin中arrive的method。# G: G. B4 g. F$ L

" b9 ^/ c- P! T- I* y) ?当到达物料速度越高时,这个报警更多,
+ B- y9 g- i4 e2 u
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-9 07:25 , Processed in 0.019554 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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