设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10178|回复: 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'
; v# @! J8 g/ h*/
8 J$ ]# ^  _- l* j8 Pis% Z; r; }! T5 E9 i% h' H
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;; w/ e" m6 c+ ~3 b0 T( F
do
1 c2 g9 J' [% }: i$ R        Lan := rootfolder.Internal.Tools.AOLlanguage;
  I# s% Q& {: w0 W* u5 m$ r        if current = @.Destination -- else return
1 d7 F8 {  ]5 l3 x/ g6 B        then
; s6 {0 A4 G9 W: _7 q                @.Destination := void;
- _. J% Q( Y; T                if @.occupied then
# g4 @2 `" a8 O# P0 O: |                        part := @.cont;
+ w7 G$ r+ K3 x  V                        @.transpOrder := void;
- q7 i' y- [; U# w1 Q7 \                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,: |# n1 K/ `% M  ~0 f
                                @,root.eventcontroller.simTime);: T  s3 ]5 Y& q5 ?7 e* `
                        @.HasOrder := false;
* R/ W, p8 |  V: ?* @                        @.DrivingHome := true;
1 S" o, h& H8 T/ K/ S                        rgManager.tryToStartTransOrder;8 a. _8 T" k( M* s! @' q
                        if @.Destination = void% n6 d$ f. M, I) e/ @6 E( Y& k
                        then -- no transport order for vehicle @- w( v8 p; J* r0 b! L# z
                                @.Destination :=
  @" t( S- F, Y4 x                                rgManager.nearestFreeStation(@,track.~);
) R3 |  Z$ `1 y* U: T9 L                                newDirection(@);   ; t3 h- S5 e) T7 b
                                if @.Destination /= void then+ H4 k" x! i& r( f/ a
                                        @.Destination.NumReservation :=: k) O0 F1 V6 F) B
                                        @.Destination.NumReservation + 1;5 U2 m' d) d2 E6 c2 p
                                end;" L7 T( \. i" ^+ K/ N
                                @.CurrIcon := "drivingHome";
3 K$ _. C, O' ~* H) a                                @.DrivingHome := true;( h5 P8 E0 t! L% c9 g: W$ u
                        end;
1 ^0 F& ?4 _7 `, a% K: |8 n                else -- the vehicle @ is empty, both vehicle and part are in the same dock station/ a: i  N9 {/ K; C& @) x! }& s
                        part := @.transpOrder;( H; e) d9 \9 K; }$ q
                        part.move(@);-- load part
$ D7 F8 z. W$ a! S; ~2 |                        @.CurrIcon := "load";
! j7 G. D8 k) z' j) X0 M                        GlobalDistObj := part.globDestination;
6 i/ A6 x; Q& v; O6 T( @+ J                        assignLObj := rgmanager.rgAssignL;
* R& ^# `' Z3 q( D                        row := assignLObj.getRowNo(GlobalDistObj);4 X: k6 O: j5 D* R2 P1 s
                        if Row = -1 then -- since 70- U, I% Y+ t, G( M3 {; M
                                if lan=1 then$ ?9 ~. F! |: p4 O
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),* M! D0 F, K/ `$ M+ _3 E4 v
                                                to_str("in der Andockstation: \"",?.~.name,"\""));& c5 _; V$ D# g; r& t+ E4 ?
                                else
, J' k% K' t- H1 x                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
" n7 r: A8 _* _4 Z7 C; i  ~                                                to_str("in docking station: \"",?.~.name,"\""));                               
- N( h0 Y, u% r6 a  X0 [. K! `                                end;
  K4 c$ w( b. a2 O# B/ L  b                        else
$ n# \8 G+ P& ~: O- G% [, }                                @.Destination := assignLObj[1,row];
3 T3 u3 T5 x. T                        end;                        . _( G- s8 r; W
                        newDirection(@);& m% L* h; W2 Z& N. B
                        @.HasOrder := true;
' ^/ i. D5 {+ y: R! C                end;
4 L- s; q6 a& u4 U) ?) s        end;
6 l$ g. u8 [# v8 a, W6 tend;        -- of the method
# }, k9 i& F" m" e2 \
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
, `9 a- L0 g" x+ ~9 f; {$ L, c' I; i. L
这是AGV_putin中arrive的method。4 e) Y2 ]2 l: I) _/ A
: _3 Z( y" ?. D' j7 ^. R
当到达物料速度越高时,这个报警更多,
! J$ e7 H' U9 e; a- X9 s# ?: v可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。( b" k" E, r1 D  ?, F1 j+ P8 W
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?, v7 J4 p* T, O" ~2 x8 z
1 ?6 ^& }. d5 ]) c
另外一个小建议,就是move,所有的move都可以这样
% o( G6 {- P& T4 Vif not move() then debug end) B  ?9 @% w* w4 U% C5 f
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。$ p, y, E2 c4 G- _6 Q) G3 C9 V% }% g
plant simulation中的free libraries有AGV模板,. H( n( p0 \  @5 j
里面也有案例。
) |1 F' S7 {4 z3 e我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
. f. F& b" M  {. L/ |( w9 h
% C3 v* q9 s5 ]# E5 S- I+ p我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
. k  Y6 |# [1 N! U& V
1 j9 d% o3 a- D& [. o+ l: h/ L那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
. r% }0 V' y) j$ g* _) |0 r这是AGV_putin中arrive的method。5 h- I# l# ~% H3 P

# A3 u, c7 ~* H1 O7 J) c当到达物料速度越高时,这个报警更多,

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

本版积分规则

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

GMT+8, 2026-9-18 14:21 , Processed in 0.020667 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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