设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8983|回复: 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'
! ^$ a# w* J7 r2 J# C*/
  r" s! r# |9 ]5 M! v- ?  eis4 f) p$ M( Z; y1 w- F+ y) x$ N
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
+ ^1 K3 q% K! e, {do
& }! b  u# s, b% o. H) T        Lan := rootfolder.Internal.Tools.AOLlanguage;
  s& @# ^5 G# c9 J) [; G        if current = @.Destination -- else return
: y1 j3 A1 m# j- |6 q8 Z        then# m2 l5 U( j- [( }
                @.Destination := void;& N: {- k( D6 y3 [: j
                if @.occupied then
# j* S6 j! X$ N6 a  _+ C                        part := @.cont;; D6 V$ v( L: t# _' f
                        @.transpOrder := void;  P. c1 d- N& M" X2 v, _4 F+ E
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,5 ^5 [  @: Y9 Z- E+ L+ `
                                @,root.eventcontroller.simTime);1 C% @0 ~0 Y  `) t: I
                        @.HasOrder := false;+ {! K- ]6 [' A
                        @.DrivingHome := true;
5 m2 G% u: A( K( W" ?, g                        rgManager.tryToStartTransOrder;0 J( ~; g! B$ u" {
                        if @.Destination = void
$ q3 k/ S& T$ }3 h  Z& ?+ T5 N                        then -- no transport order for vehicle @2 z" V0 ~2 `5 l! j: J
                                @.Destination :=  ~( L9 J2 R4 ?6 `5 E
                                rgManager.nearestFreeStation(@,track.~);8 D1 D% g% ~+ M) x2 u1 }1 {
                                newDirection(@);   0 n; E& S# J) x8 a" J( q1 _4 i
                                if @.Destination /= void then4 Y- z- j" `+ J& r$ b+ M
                                        @.Destination.NumReservation :=0 i4 p3 d/ _  [! s
                                        @.Destination.NumReservation + 1;6 b' Q1 e: ~& S8 Y7 _  Y) x
                                end;! B$ Q, D4 w, ]3 H& E* B/ }
                                @.CurrIcon := "drivingHome";3 F0 A% x8 k1 }( A$ `
                                @.DrivingHome := true;
; S. r" X- e( \8 z                        end;+ W3 Q+ `7 ]+ V- D0 o& Q
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station0 Y( S+ F. M0 d: x$ M: D
                        part := @.transpOrder;( z: `/ R, R9 v4 Y, |# T
                        part.move(@);-- load part
# U$ o) c1 |/ {, A; X                        @.CurrIcon := "load";0 k8 W$ r5 ~/ X3 o' H
                        GlobalDistObj := part.globDestination;
6 F! G; Y9 H3 \% b' ^6 e                        assignLObj := rgmanager.rgAssignL;
+ ^3 K# E, X3 Q  \0 m( I                        row := assignLObj.getRowNo(GlobalDistObj);  ?. Z5 S! t3 D) R: H. P
                        if Row = -1 then -- since 70+ {# r* w2 i( c- [  H( |
                                if lan=1 then
1 }6 }7 ]! O+ O$ t" J                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),$ j: @: ~1 K# J
                                                to_str("in der Andockstation: \"",?.~.name,"\""));1 t6 _6 |4 B8 u' H
                                else
0 m! ~" n8 p% X' }# E1 j                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
: C& X, O3 g1 F                                                to_str("in docking station: \"",?.~.name,"\""));                                / W6 d+ i, \+ ]) F+ j- _( H. c
                                end;$ h* ?( q' L& S3 T0 w
                        else
7 J5 X5 u6 @+ s9 X1 [, |7 q$ [, E                                @.Destination := assignLObj[1,row];; Y0 z+ t$ @; X% R. X1 ?/ v4 S
                        end;                       
: f  K+ o3 Q% R/ }                        newDirection(@);
2 J/ b2 ?( ]* B                        @.HasOrder := true;
$ R3 o1 B: m( \+ g                end;2 Z/ E+ y& I! }
        end;5 y! {" X- R! `3 b0 m; F0 a
end;        -- of the method
( w) F% \, {: U6 R& U1 n
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
- Z" }4 x/ ~: ]& d  d' F* C9 U* Y% s* K+ Q7 E8 e! H2 c
这是AGV_putin中arrive的method。
! N# O$ ^  D0 Q0 ]: Q: o5 _
% W# x, z1 Z. ?当到达物料速度越高时,这个报警更多,
8 j2 r/ a% H3 l% ^' @) Q% g可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
6 [. z# j" E* Z# M0 A0 T程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
, ^- W; P- H, h  a9 q% }) r1 Q7 U4 E2 P- ?
另外一个小建议,就是move,所有的move都可以这样
( J; X5 ]2 o9 @2 S* a4 Z' S# wif not move() then debug end
. I( {, k' @) h/ K$ r1 s. m这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
& U3 _% Q# j& B; e: u# q: _7 uplant simulation中的free libraries有AGV模板,6 S8 l$ E" v+ P& U, r, f
里面也有案例。
# ^0 t! J' q" |9 B: q4 t我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
+ ~8 M6 m8 ]3 k/ L; T3 o
$ f1 l# h3 i! }我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 " ~' b2 `) E7 Y

) T: N# l& }1 v5 j! s, y那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ( C# [# M  }" V% C1 a9 M1 F
这是AGV_putin中arrive的method。% j9 f1 G9 W: z* D) f% R# b+ @

2 ?! Q! B) u# ]" Z% s当到达物料速度越高时,这个报警更多,
/ i6 Q+ U* R) d9 g: Z
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-7 12:37 , Processed in 0.013612 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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