设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7397|回复: 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 R, c7 @9 ?6 K! f+ x& i
*/
2 H% z& v' T+ ]* w% eis
: [$ K# m# b" v5 p        part, GlobalDistObj, assignLObj:object;row,Lan:integer;9 M0 a( T( p9 H) E
do
" b( ]6 p# [6 W  r  L        Lan := rootfolder.Internal.Tools.AOLlanguage;* Z/ L& r. _3 y  L8 b
        if current = @.Destination -- else return
0 g* h6 |4 w# Z. G7 L- y        then* W1 ]$ U2 j( t# q. m! t. d' g+ E
                @.Destination := void;
! `) Y, p6 a# ~2 C- K                if @.occupied then( ?9 j" p4 z  I# d6 U) T3 L
                        part := @.cont;, X/ H8 g- y0 A  Y; O
                        @.transpOrder := void;( K1 l1 j+ I1 k) I  H/ _  z
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,  L  N1 r$ q% o7 d# W; r  e/ _3 \
                                @,root.eventcontroller.simTime);* C7 T2 Y; p( r% _2 _. v" c1 H
                        @.HasOrder := false;% \" k. ?6 G2 z2 K. f: F
                        @.DrivingHome := true;9 f; b6 r% W. M* P1 M2 i
                        rgManager.tryToStartTransOrder;
& G  d+ w- ^3 c+ ^# r; i# g  s                        if @.Destination = void
5 A2 _' f; ~. l                        then -- no transport order for vehicle @# n( T. H, }/ W  j* J7 z1 J
                                @.Destination :=
6 M. N( Y9 W/ C, r1 P( B; U: c                                rgManager.nearestFreeStation(@,track.~);
' f7 ]- e; l( t8 l, e                                newDirection(@);   
0 H' p2 L# U) C' T/ W  i% l                                if @.Destination /= void then) k7 m: O& {; s" N
                                        @.Destination.NumReservation :=0 d: f* R$ i' ~7 a
                                        @.Destination.NumReservation + 1;
! h+ I; j# z7 j7 D                                end;' }9 e5 p: z% w/ u7 ?
                                @.CurrIcon := "drivingHome";
4 M! y/ ^% z; a0 Q9 S8 U9 o                                @.DrivingHome := true;
. F0 i$ K0 y4 r, c$ z                        end;
. D' g1 O- ?: E2 I6 h! X                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
8 s$ Q( `: E8 n2 X, V& }3 z                        part := @.transpOrder;
* l+ C9 D/ J+ `$ J% s4 a6 D                        part.move(@);-- load part0 L7 c' ?, r2 A! e9 V. I
                        @.CurrIcon := "load";
5 p4 `+ D2 f( a9 N/ k, C                        GlobalDistObj := part.globDestination;
4 p& n9 j! K+ ?7 e. P+ p                        assignLObj := rgmanager.rgAssignL;
( a: k; P* J8 b0 V' P                        row := assignLObj.getRowNo(GlobalDistObj);
7 L5 w. |! Z+ j/ N4 R" ?                        if Row = -1 then -- since 70
: `3 x1 a( a+ m1 y, D. e: E                                if lan=1 then' B9 l! M0 n9 m+ y5 Q
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),: r. o& K- [+ |# {/ w7 J. p
                                                to_str("in der Andockstation: \"",?.~.name,"\""));5 I3 D0 A4 q0 L
                                else8 R+ H. L. L2 e: h" k/ T
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
3 X. m7 K' j' y. ?! w7 S' ~* t  u                                                to_str("in docking station: \"",?.~.name,"\""));                                / z0 o! L4 U  J
                                end;
, D( l' `; C1 `9 o                        else% T6 t( v4 ]. x4 W% _
                                @.Destination := assignLObj[1,row];7 S0 ?1 m' E( ~
                        end;                        " ^* f; u) }; ?
                        newDirection(@);: I! p5 [4 K8 q( D! f% R
                        @.HasOrder := true;5 p# w1 b- g! e" E2 Q0 w2 J
                end;  p3 y3 q6 A; P
        end;# H4 \8 T* J+ m, s
end;        -- of the method" E# a7 c1 b( n! q  R
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
# p/ _* ^: H0 {7 R/ X- {+ w
" k& S# a! R1 B' Z9 n这是AGV_putin中arrive的method。& D4 z# D0 Q) ~6 l9 ]- G4 p* A: U

, Y0 Y/ m4 @* p# r$ A/ u  P& Q& Y当到达物料速度越高时,这个报警更多,
4 c. u( m# h8 e- `可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
! n) m6 n4 V2 o" n程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
1 w* Y- K# v  h1 N4 d1 D7 c+ r+ c9 I' i6 N
另外一个小建议,就是move,所有的move都可以这样
+ d7 t* {1 S. Rif not move() then debug end5 a2 [4 z$ W3 W1 [+ r
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
7 {9 o$ ?' `. C" S( qplant simulation中的free libraries有AGV模板,: R3 x) k! x( V- K( P( g7 {0 z
里面也有案例。( F) ^0 j* K: R! E
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
, J0 V% }5 p! l$ z9 b! e1 _/ a- s
9 I" u/ Z+ K( ?7 |3 y1 w& P$ _* R4 S我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
$ @1 s8 Z* o% Y) b$ D
; e+ m- M" m; g$ f! f7 _那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
1 _& o4 R+ r- x这是AGV_putin中arrive的method。4 S+ M3 i6 \$ m7 d9 W8 D
8 o% S' b# K5 o8 a
当到达物料速度越高时,这个报警更多,

" H! y$ u! o+ W另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-9 12:46 , Processed in 0.016863 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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