设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10093|回复: 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'
2 |; K4 ~9 g; w3 Z) C*/. R% v+ l9 A+ R1 w
is
0 d& @* c  r# _! f        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
' ]# R: a& [7 W3 q! Ido/ K; k0 A( t5 R7 v4 }, E, T7 v8 m
        Lan := rootfolder.Internal.Tools.AOLlanguage;+ A. _; u( l+ J+ T/ e
        if current = @.Destination -- else return
+ t& N2 C: W+ z, ~        then2 J; H7 A5 O( _
                @.Destination := void;' r/ q0 t; p9 n3 S1 t3 ?2 z  K! [
                if @.occupied then
; t+ L0 n4 n' ?0 e2 y! @8 x                        part := @.cont;
8 m" W1 ]. y/ V! v( q8 f5 p                        @.transpOrder := void;2 j5 E1 C$ h, v2 w) g
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
5 K: X. S) o" M3 B0 S6 u- _                                @,root.eventcontroller.simTime);
4 I' q! t6 I$ P                        @.HasOrder := false;& ]; T7 ~6 L2 ?/ ]+ S9 f
                        @.DrivingHome := true;' |. E( \& O. B1 M, n% h/ B
                        rgManager.tryToStartTransOrder;8 X9 D# b- D: L3 f. {
                        if @.Destination = void' X# M$ i; U) t2 ~; `
                        then -- no transport order for vehicle @) b6 G6 q4 L7 F1 m- n6 a) K: @
                                @.Destination :=
1 r% J" E+ {& U9 f  o                                rgManager.nearestFreeStation(@,track.~);  v* I. y3 v) M2 o  U* `  }
                                newDirection(@);   . u. N& V) r+ E, j) w+ Z
                                if @.Destination /= void then
" u' H$ M, l1 j* O2 p7 T( I                                        @.Destination.NumReservation :=/ d" Z) c! e$ z0 @& x+ Y
                                        @.Destination.NumReservation + 1;. _7 g* Q# ~) x2 D! L" f. C
                                end;
. V0 y; w9 }% }0 B' ^* r                                @.CurrIcon := "drivingHome";0 A) U5 S/ o8 f; ~6 N! ?( j
                                @.DrivingHome := true;6 k0 A. U8 d( A
                        end;
+ Y8 b' `* o+ U  y" C9 J: {                else -- the vehicle @ is empty, both vehicle and part are in the same dock station+ l) Y, H; z" Y
                        part := @.transpOrder;
3 t5 j' L/ Y% F0 H                        part.move(@);-- load part
. |! a1 ]8 h: v' i3 k+ m                        @.CurrIcon := "load";
% P' E& ?9 z3 u2 F                        GlobalDistObj := part.globDestination;
8 U: @. i3 ?: y                        assignLObj := rgmanager.rgAssignL;9 [. ?' q( {$ {3 ?, {
                        row := assignLObj.getRowNo(GlobalDistObj);( w2 D/ M% R1 A
                        if Row = -1 then -- since 70
' K: b, W% k! U2 r8 K) v                                if lan=1 then& Y- ^& x# Q9 f
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),6 @) D" d0 q7 J. i) _) J. _) Q
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
  }& L3 b& w+ R: M( ], h, K                                else5 }. d0 k* f& o: }
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
  g4 G% E! V* j) T& e0 i                                                to_str("in docking station: \"",?.~.name,"\""));                               
. f  w( O" r' I, @& U2 B                                end;
+ s% n8 a: ?8 o                        else. e1 P/ g0 @( ]3 u; ?, y+ t
                                @.Destination := assignLObj[1,row];% l1 v8 D, F( _7 ^6 z, o* M% c
                        end;                       
% J* u+ J' d1 a- A. |                        newDirection(@);
. t7 ^1 M" Z) |                        @.HasOrder := true;0 ~! x% P4 d5 f
                end;/ U4 d# a" T, [; h; b  n; T+ O+ Q
        end;# d. d% Z- B4 m0 X& F# \# c
end;        -- of the method
# M( a' |) ]: T6 k* T2 ~
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 * Y7 ~( [# {5 i! I; A

' W% {6 c. W9 J, e这是AGV_putin中arrive的method。- P' Y" T: ?- V+ o, F& m8 ?! {

6 @# }8 N5 O  r5 j' _当到达物料速度越高时,这个报警更多,
% m; t6 e8 X8 C+ j可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
7 k# Z. P5 b% I程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
3 h- y, i1 m( F# ]1 x' D' F- g& R. G" Z9 R/ |- b
另外一个小建议,就是move,所有的move都可以这样
" l0 f4 B; v) N' Rif not move() then debug end3 `% |$ T: C& c7 R  F: g
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。2 J! p) Y5 A6 Q- M4 ]( o9 q) H& O
plant simulation中的free libraries有AGV模板,
! `" ~! J' @" b1 b) u( e里面也有案例。
, D! _0 M& C, w+ e" K$ m; K, O我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。9 {" K8 m, V2 ^1 y$ o! u; o- {1 s' ?
9 K# l- s$ R* y
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
- y& @' J% Q" }1 |5 |
' o% z8 D# z0 v. \; d那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 0 |4 x& n- C# s; n/ k# }1 o/ j0 _9 H
这是AGV_putin中arrive的method。
6 ?7 _. U1 _5 u" x& K3 ]9 {( c6 e& m1 B
当到达物料速度越高时,这个报警更多,
# {" a& m, t: R' ^) v3 `, L$ l) ]
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-12 23:47 , Processed in 0.020843 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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