设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7004|回复: 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'
' n3 M" s$ u/ O. V7 {*/
6 ^3 l5 U$ _; G$ p5 Iis% F# X& Q+ [/ u  E5 e
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
8 [: p( L0 r& C# H$ Fdo
' J+ {8 e$ K8 @3 l, l9 Z$ r8 f' ?        Lan := rootfolder.Internal.Tools.AOLlanguage;$ B3 u* J# u- V7 V0 J1 m# w+ l: g
        if current = @.Destination -- else return$ @+ R( ]- O0 S7 T' H) [' `' t, S
        then. Q' E# C3 L( S( K4 X
                @.Destination := void;
+ }9 H0 P5 |+ M, }! X                if @.occupied then
, x) c  o, N" F                        part := @.cont;
# V9 ]( i. U- I+ }" z1 V) q                        @.transpOrder := void;- l1 J2 |$ y& p3 k. L( j
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
- v3 L. U2 n2 r+ b( I                                @,root.eventcontroller.simTime);
1 p" z# ~) m0 @, d2 h                        @.HasOrder := false;
' B+ K- x+ r1 M' d: q: U0 v                        @.DrivingHome := true;
7 U& _2 N$ O  e                        rgManager.tryToStartTransOrder;9 J) U/ H% @9 J1 a( {8 R0 W- |
                        if @.Destination = void
1 q/ |6 @- E" Z$ @  W& P                        then -- no transport order for vehicle @, A& N& I: ^% M7 {7 R4 ^
                                @.Destination :=
: d0 F# N2 @$ `/ J. {. _+ o                                rgManager.nearestFreeStation(@,track.~);
( n, e& j/ K0 |" t                                newDirection(@);   
! I! F7 K/ {2 @2 P' Q, J7 G" Z                                if @.Destination /= void then
, `: ~/ x0 s) ~2 a+ d( _6 m                                        @.Destination.NumReservation :=
1 p1 X& O$ [% j- y# M                                        @.Destination.NumReservation + 1;
" s3 b. X2 A% g7 ]1 p+ {! A$ ~9 D6 b6 r                                end;
% E! R. P* `. e  i; q% Q' S                                @.CurrIcon := "drivingHome";8 M! ~8 `  ?6 x% ^; ?
                                @.DrivingHome := true;2 M" w% e( e1 i& Z  S/ m9 i( Z: K
                        end;
$ |* T! w9 t9 p) x' c1 {                else -- the vehicle @ is empty, both vehicle and part are in the same dock station7 D' c3 T2 U. M% _& k# h
                        part := @.transpOrder;
% K$ t2 v5 j* H( l                        part.move(@);-- load part
) w$ @8 N, |( I$ D5 p+ ?3 w+ v                        @.CurrIcon := "load";; a, d9 u1 T: Q! f8 C+ l# i
                        GlobalDistObj := part.globDestination;
% D& }" U( |$ x: p                        assignLObj := rgmanager.rgAssignL;3 J9 h# z% h5 W, y! w. m1 ?
                        row := assignLObj.getRowNo(GlobalDistObj);
% ]+ G) W1 G% g7 F  K: b; }# w                        if Row = -1 then -- since 70
8 V, P# ^2 P; y# B. |                                if lan=1 then
& S& Z3 H' V+ N                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\"")," q* I- @: n2 g$ ]' w
                                                to_str("in der Andockstation: \"",?.~.name,"\""));# I3 b. X0 l  x: U
                                else
8 R; p' T3 e, N4 K1 ]% D                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),- S$ |* x* P5 Y4 |9 e/ E! E
                                                to_str("in docking station: \"",?.~.name,"\""));                                ' ]3 C& V. x& b" L& ^
                                end;4 c: x( }5 d3 {2 Y/ `4 G! q- ~& {
                        else
* L, J  y) N- l                                @.Destination := assignLObj[1,row];
& \2 N! ^2 q& R% M! E                        end;                       
5 G. b; r# p% {6 m( m, F" ]                        newDirection(@);# R6 T9 ?- D) \: \  a9 }
                        @.HasOrder := true;6 k8 ~- T! n' z4 v  O! L$ J: `0 x
                end;7 _* r7 }2 h* z& ?% k
        end;& E  E2 A# c2 [% O4 t! ~
end;        -- of the method
! _7 a2 ?, w, n; i
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 # s2 j+ e& D7 r" d
7 Z# L9 Y. H5 w" h7 f
这是AGV_putin中arrive的method。
- J+ s$ I. V) E9 w6 O  h2 w- R" w" E& x2 n# ^, m
当到达物料速度越高时,这个报警更多,0 n( }" J! c$ Q* v2 m
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
6 l' L* \0 E: k. f; {程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
. K% D) c5 I( B* ]
& E4 `& Y: k# T* V/ G5 T( U另外一个小建议,就是move,所有的move都可以这样$ M7 i) X. [8 j
if not move() then debug end: e. M" O+ r) {  q% l7 M0 y: Z6 K
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
6 P# E' m) L# z; _% Uplant simulation中的free libraries有AGV模板,
. f/ I9 |$ I5 U$ G& G2 I里面也有案例。& L5 M4 ]  g, i( W8 [
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。1 A' \+ V2 p9 y/ D

' y7 W0 ]1 n# U4 ~1 ?; o8 A我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ! n! A2 j7 {# ~3 Q

% O6 Q5 n  t" \+ P那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
7 ^* J2 F) Q2 m9 G) Q" s9 D* z这是AGV_putin中arrive的method。$ m5 j. z: B; k, _( l! D# r
; o+ A9 B" @) C# f: W
当到达物料速度越高时,这个报警更多,

6 e1 M8 n/ o/ z2 L8 Z: B9 H另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-10 18:05 , Processed in 0.019688 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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