设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9146|回复: 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'
1 x6 H4 [7 A3 {+ _+ j, }*/
$ f9 `3 r* q# v- Qis5 O# M4 j) @, O9 Y0 O2 B
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
  k; ?+ x' b- a" q, F3 R! \do
& S$ f1 o% i$ s3 V4 t- d; ~        Lan := rootfolder.Internal.Tools.AOLlanguage;
# ?, f. z/ n& k8 E- o# o  `        if current = @.Destination -- else return# O/ S* t6 J5 c7 ?% R) n
        then% v) F# a1 H( j1 B5 K  U
                @.Destination := void;" e  ?+ c/ w2 z9 X' ^; S
                if @.occupied then
. ?4 U# a% o. g* r; u4 L& T                        part := @.cont;
! ?5 l( N1 \/ R; O- ]                        @.transpOrder := void;8 V! O) u/ y9 x3 L
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
, c1 O  J# r! W4 Z                                @,root.eventcontroller.simTime);9 k9 ^1 K5 A3 p
                        @.HasOrder := false;
3 `6 @; B1 w  v0 u! m                        @.DrivingHome := true;
( v) I: o! e- d# w3 P/ @% X                        rgManager.tryToStartTransOrder;2 B, ~7 `) R' Q+ k; t/ f
                        if @.Destination = void2 i8 T4 u* y. ^3 ^
                        then -- no transport order for vehicle @1 m5 f& M2 D' M  o
                                @.Destination :=
. F- H& `# j  n+ T; ?                                rgManager.nearestFreeStation(@,track.~);- H# Z4 ?5 Y7 V4 P5 J& Q
                                newDirection(@);   : u# D( p" |7 y$ K
                                if @.Destination /= void then$ n7 D3 W0 t# ?) l
                                        @.Destination.NumReservation :=
  }8 j  A. c/ _1 q. @9 |0 x: C                                        @.Destination.NumReservation + 1;
& f  g8 `  L  e; `. p: u                                end;
% }1 s3 H5 F# G. L* O+ z3 D                                @.CurrIcon := "drivingHome";
- Y4 ~# d( z, U4 T                                @.DrivingHome := true;
5 J, ^7 C! z) }9 [9 U                        end;
1 ~- E* i- T+ m! @- E- g' x. e                else -- the vehicle @ is empty, both vehicle and part are in the same dock station7 N. r* y; |  P
                        part := @.transpOrder;& C8 f) E6 u# ^
                        part.move(@);-- load part2 W1 t9 j/ u5 e# h* U. r
                        @.CurrIcon := "load";; Q( Y7 G4 f, k; L3 H7 [' j
                        GlobalDistObj := part.globDestination;
8 f! M6 J4 c5 k" H! P1 F, Z                        assignLObj := rgmanager.rgAssignL;3 M$ G( ~  e  J" ]  R
                        row := assignLObj.getRowNo(GlobalDistObj);
. Z2 P0 `8 a. J# X. v& M                        if Row = -1 then -- since 70
9 Y0 e6 w# f8 C, Y/ J( n- t                                if lan=1 then" ~+ z' W# Q2 e. E! b
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),9 D2 G4 v0 t, v' e$ D  I
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
1 q! V& h* z2 ~2 A                                else
. \* x7 L5 ^0 g8 I  b5 T7 w; [                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),3 s; M6 @+ B' h
                                                to_str("in docking station: \"",?.~.name,"\""));                               
7 s9 u6 r3 e/ ]. b% J2 h) z) X9 Q1 A                                end;( D- |3 \" E, f- Y/ Y( m
                        else: \  `+ [% N$ w$ ?: w
                                @.Destination := assignLObj[1,row];5 p: k5 t8 H: m8 d/ g4 ^
                        end;                        + n* M$ s# |4 z+ [( W1 B( f
                        newDirection(@);2 I) h  m5 ?4 f; r/ G3 F
                        @.HasOrder := true;1 j  B0 }1 U  h/ I, F) W
                end;: l* H5 T1 ?; |! c: c+ V, P" h
        end;* s  @' _( v6 g& Z: a+ Y7 Z
end;        -- of the method1 {2 \4 A) R+ ]* b2 C" g* h0 S
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ' V, ]$ ]' R8 m# L- Q  @' f7 b
- u, }9 Z! b. E& R) D! `
这是AGV_putin中arrive的method。5 w9 B+ Y6 i& _$ h
# j8 F) [+ g; p" c4 J! {
当到达物料速度越高时,这个报警更多,
3 \4 z  d1 N8 N2 G- j4 ~可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。: e8 g& K1 |' d7 z& Z( m# F5 }- w$ v
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?/ {7 ]5 e7 N; f# Q6 M9 K1 H7 n
; V. K2 K: o3 N4 Z' p$ r& w
另外一个小建议,就是move,所有的move都可以这样
2 P: r3 B6 u6 Lif not move() then debug end
9 w: o# Q- ^, m) _3 F) a这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。' u$ g, [2 U- s( D
plant simulation中的free libraries有AGV模板,
2 A" h' t+ u1 [" F+ E5 P+ ^7 D7 Z8 e里面也有案例。
: R0 p- U# I! Q- c5 G5 m: @; R我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。  g/ P5 B" S3 t* u. t9 @
  v; e# e% `+ ^+ H
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 : f9 T& ], w1 J* d6 \
* H  Y# X; T/ B/ J4 K1 l
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 + [! ^( m9 p9 H& G2 A' J! W
这是AGV_putin中arrive的method。
& y, n; o2 J* I, m, C" r, x8 N9 m1 l. |2 K( a* r3 P
当到达物料速度越高时,这个报警更多,

3 r. S% m: J* i  w  y) p$ ]另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-16 16:00 , Processed in 0.017705 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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