设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7217|回复: 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'
* u% ]7 g% O2 z6 G*/" a  Y9 C; n5 `( b
is
# z; I0 A# X; Q* }* |        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
. t  F* V' M9 g2 ~$ q5 N+ _/ {7 g% ?do7 ?0 O* h$ a0 R% m' ^
        Lan := rootfolder.Internal.Tools.AOLlanguage;7 @, R! {) M2 J4 w7 w" J
        if current = @.Destination -- else return
* @: m9 R) R, L! g8 U" _& U        then' z7 r5 P9 ?6 W! i3 f
                @.Destination := void;6 x9 I2 e# o- l; ^  o0 G: `2 a3 T/ p
                if @.occupied then
! W0 ]; F2 z* |) w% F. H- Q6 P# o                        part := @.cont;
2 c8 e" L( \, A+ P& V/ {3 q                        @.transpOrder := void;
* {6 r* {. G+ j5 w$ @+ X& k                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
+ E9 a, Q5 C, z/ I                                @,root.eventcontroller.simTime);) A7 Q  }" v/ A: g0 ?
                        @.HasOrder := false;
/ [; C& A- b5 v- W0 Z% b                        @.DrivingHome := true;
# q! a; ^( j; O) S7 C% x- \% m8 }                        rgManager.tryToStartTransOrder;
! l; U, K5 x7 ~3 p                        if @.Destination = void. x/ r" |! M# f- v8 \$ ~1 x
                        then -- no transport order for vehicle @
  g7 O; L4 k$ N                                @.Destination :=1 n0 Q/ _' C/ M3 U( V7 @
                                rgManager.nearestFreeStation(@,track.~);
; }4 z; N+ Z+ d                                newDirection(@);   % {; E' x5 S0 U3 }5 T# D
                                if @.Destination /= void then
5 d: d# E) p" A; v/ g                                        @.Destination.NumReservation :=* u" {4 e" }3 y+ L; V
                                        @.Destination.NumReservation + 1;
  N) A7 D3 ~- {' o) u: G* U                                end;" D/ Y0 \  K3 N
                                @.CurrIcon := "drivingHome";
( W% k2 n" L% n3 ^! d) K                                @.DrivingHome := true;
- O& i7 N6 Z$ {+ k                        end;
7 n$ v3 Z, o2 }1 b9 b8 s                else -- the vehicle @ is empty, both vehicle and part are in the same dock station0 i- o- |! J$ J9 v
                        part := @.transpOrder;/ ?0 O. j# ~# v# n0 |# k% q
                        part.move(@);-- load part2 e7 K$ Q! L. U
                        @.CurrIcon := "load";
2 D* d6 W* K4 Y9 @' @                        GlobalDistObj := part.globDestination;
7 w4 v7 c& ?" `4 j                        assignLObj := rgmanager.rgAssignL;; n/ }  q) P" v) z$ u- j
                        row := assignLObj.getRowNo(GlobalDistObj);
$ Z; ?& i3 E$ ~& p                        if Row = -1 then -- since 70
0 R& x% @* ~. ]5 K* j) ^2 n9 z                                if lan=1 then
$ }0 s/ I& [4 [9 ]7 q                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),. ?; z7 f9 N9 z' q" a
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
* ?7 j( U- L' s3 Z2 x3 T$ [0 `* x                                else
+ Z! _5 f& H8 F                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
' ^! {% p* C' O, V9 D* Z  }: p                                                to_str("in docking station: \"",?.~.name,"\""));                                8 ~, ]5 C0 k: x
                                end;$ T8 d5 a* ]3 c# v
                        else2 i- G: a2 s6 I; ~8 F
                                @.Destination := assignLObj[1,row];- S5 g3 Q+ O2 ^. g
                        end;                       
  g* w' w6 R5 Z0 X& Q                        newDirection(@);, Z7 x, |& E4 o  o* z& c
                        @.HasOrder := true;
' J% ^. S' K& ~2 n+ h8 |                end;
  ]& p  F  C, z        end;
. K+ r! q8 m1 v4 R* Vend;        -- of the method
. E$ S& @+ u" Q: D* W# P; a/ c
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ; n. @' b8 O. L$ l

) K: o- g" a0 i7 I/ s2 y; G  y+ o这是AGV_putin中arrive的method。3 T% y  L3 S& [

; O3 d. Q5 M& h1 j) M" q当到达物料速度越高时,这个报警更多,
, S% q1 O" ]+ Z( p# c$ r% o, j" L可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
$ h$ v  u& C/ w' o- d程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?/ o! s5 V4 `/ x$ [7 Z% \8 e- I
4 m$ b3 ?; F) X) P7 O* W
另外一个小建议,就是move,所有的move都可以这样
' q4 V) g* J& V$ Kif not move() then debug end
0 H9 C8 E" X% W5 c这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
/ Y: ^1 P4 x- o1 O- a% rplant simulation中的free libraries有AGV模板,- z# ~4 h, U2 a! b0 K  X
里面也有案例。
0 G  ^- q# ~( K/ _# s8 G8 I; Z, A5 T我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
0 h, g0 j7 t8 \5 t. R7 r  k
8 R6 n3 l6 n4 T5 b我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
; E# y# h6 z8 i$ ~& G$ J9 e' [- G; a0 m: O
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 : i+ [4 b: g  {7 V0 n* l* A4 U
这是AGV_putin中arrive的method。
# l# j  Q! c* ^" B" F
. w9 A3 s* d3 v5 _当到达物料速度越高时,这个报警更多,
4 {/ J3 ]/ s! S) l) P# \# A7 @
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-27 23:46 , Processed in 0.015942 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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