设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10149|回复: 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'
0 {5 J( l+ \! U' e: B  z+ \4 f" X*/! U& k  n8 i% i' t+ i
is
& |2 j0 z. F7 S7 l7 ?6 w        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
* ]8 u" ~$ e" [2 v" @2 j4 ?8 ado
5 s6 W# W0 C( b! v        Lan := rootfolder.Internal.Tools.AOLlanguage;* W* y7 X# o! O' y$ e; S
        if current = @.Destination -- else return1 d; H5 a; h7 ~6 @! C% d, a* h
        then. x$ \# a  v/ M1 u# X- L
                @.Destination := void;
6 ~7 n" d/ g  n1 L; @                if @.occupied then
% g$ _! K2 m( X+ Q6 a9 @; i7 c9 G                        part := @.cont;
4 Y3 l9 e& _& u, e                        @.transpOrder := void;
/ u3 ^, ?$ z2 q( u+ o0 `- e8 {                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
- I. s  S$ _% T# @" i/ x% ?                                @,root.eventcontroller.simTime);# @& @  ^  p& o& ^& c& v/ l, c
                        @.HasOrder := false;$ S6 O5 v5 o7 r# t; S. K
                        @.DrivingHome := true;
5 n; d' D% \9 j, y; l                        rgManager.tryToStartTransOrder;
' m, N& M/ |5 T8 [9 v                        if @.Destination = void
! A, w% F% Q$ M; ~4 j& V                        then -- no transport order for vehicle @
( ]1 M& U& k! ?* I# N                                @.Destination :=: b. i9 d1 A4 {$ A' L4 y# `+ L
                                rgManager.nearestFreeStation(@,track.~);
8 i# \3 ^' a$ L: y# j" U                                newDirection(@);   * S0 i: ^% `* _% f0 `2 q7 A
                                if @.Destination /= void then
' J. |+ a1 Y1 }                                        @.Destination.NumReservation :=+ F; D8 {) J& Y8 C
                                        @.Destination.NumReservation + 1;' u) Y! B$ h: ~! Z7 c" ?" o, V" n
                                end;- ?- E* s) F+ u/ ^7 @6 ^4 W2 H
                                @.CurrIcon := "drivingHome";5 h; R8 U: p; a) k
                                @.DrivingHome := true;5 K9 `+ U0 m& u! z# Z4 j
                        end;
9 k4 E1 `8 L% j& Y$ b                else -- the vehicle @ is empty, both vehicle and part are in the same dock station  g" x" z  Q5 n  l
                        part := @.transpOrder;+ W# D; \% ^' P
                        part.move(@);-- load part$ F6 b& z; \5 C
                        @.CurrIcon := "load";
7 C7 @  c: j; u3 l6 k" i- L                        GlobalDistObj := part.globDestination;
' s, B6 ~; }6 B% K$ \                        assignLObj := rgmanager.rgAssignL;8 g: A* ]- T. b4 {4 O2 e0 A
                        row := assignLObj.getRowNo(GlobalDistObj);9 o3 W* O! o# P3 a. z$ q
                        if Row = -1 then -- since 70
$ R& u4 W: F2 Z4 _& Y6 P9 g                                if lan=1 then3 y! O3 q* C3 ?9 f8 w/ b- V. P
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),* p4 X, C! j/ g" D1 ]
                                                to_str("in der Andockstation: \"",?.~.name,"\""));; Y0 h! q6 Z2 P7 ~2 w+ {2 C
                                else; Q% }5 N7 V8 {1 N
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),9 {5 {/ h0 z$ w. V2 R. G2 ]
                                                to_str("in docking station: \"",?.~.name,"\""));                               
" f- }6 ^1 L7 v                                end;- T4 N0 I6 g4 b. H5 x
                        else- N" P; q9 m, \& f7 @! P9 S- l
                                @.Destination := assignLObj[1,row];
& ~! I( g. y0 [+ m; H1 ~                        end;                       
" F, v; W: o3 J; ~( J                        newDirection(@);! }  }7 N4 I0 m. j  x  Q
                        @.HasOrder := true;7 V+ R$ t8 v- x& A% V- ^% @) S% P
                end;
0 a- @. l7 \* x% u        end;5 M) m; s/ _& E' @# L- b
end;        -- of the method$ r$ k+ `7 r0 P% N! H( |/ T
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 + d# l4 O, g& _, H  p# f6 r$ X

4 k  q3 n( G7 [' B这是AGV_putin中arrive的method。: T9 O: T: o( i+ u
  J0 D0 s- ^2 M1 a0 f
当到达物料速度越高时,这个报警更多,
% }6 K4 l( x. a/ i可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。: ?$ r6 o/ r" J' W9 j1 K- o  ~# M
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?3 @/ k7 U0 f* O- d- @2 \/ Z0 c

# |) g& l3 t; R2 E另外一个小建议,就是move,所有的move都可以这样
5 d" K0 P  J: oif not move() then debug end/ r2 X4 s1 }: D0 X% Q& a+ K4 ?* Z+ B
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。" Z. m3 T+ d" l5 c
plant simulation中的free libraries有AGV模板,! \7 E2 x2 T. H3 s1 S2 Q& h) i
里面也有案例。, `2 O% A* P  G
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。/ x$ Z2 ~/ H$ t: j
: D% F4 t* Z; X9 q& [
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
$ P6 L6 h0 l+ Q+ l& \2 o
9 n6 ]* ?" S) l那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
1 x! Y8 b* U; [这是AGV_putin中arrive的method。5 g: b. R" @* s9 V' G+ d

3 F7 ^+ d4 j9 `  ~) n, r, t当到达物料速度越高时,这个报警更多,

: }0 \+ S4 e/ a( V2 h" b另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-16 05:57 , Processed in 0.019502 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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