设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5930|回复: 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'
+ D: Z2 a8 M, ~6 j! F*/
) L5 D7 X% B! b2 Lis/ X/ t: y! g7 a
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
. r4 w. u& A- u& kdo
5 N7 r. t. T/ h1 [- ^7 F        Lan := rootfolder.Internal.Tools.AOLlanguage;
: ?2 \1 J3 ]  D5 h# `        if current = @.Destination -- else return
4 }5 ~, X( N/ v' [  {        then
7 C& B* N: T' b+ h- i9 I/ x                @.Destination := void;
4 P$ W, ^' Y1 ~+ K  F* P4 x) L- h0 T                if @.occupied then
2 `- X5 A: m, X0 ]; R                        part := @.cont;; ^4 F  L2 W2 h. Z6 `' L
                        @.transpOrder := void;
6 ~0 Y* M# a# x9 y% h                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,  k& Z! J6 T% ^+ ^! x
                                @,root.eventcontroller.simTime);
3 E) C* P1 Y( j5 A                        @.HasOrder := false;+ B3 o  p+ L* e9 U% K
                        @.DrivingHome := true;% q+ s& l' F5 U. y, h1 m
                        rgManager.tryToStartTransOrder;+ a6 d& u3 g# b( N
                        if @.Destination = void, _% s( F7 w' Z8 U* ~* C: y4 d
                        then -- no transport order for vehicle @
. W/ b" w! I1 q2 |4 p/ h                                @.Destination :=
+ H* E. A1 Z( ]) L                                rgManager.nearestFreeStation(@,track.~);1 B- P1 K# y& [3 a& }, r
                                newDirection(@);   ' J! Z5 S) |! @! H
                                if @.Destination /= void then/ x$ z  a2 R- {% G, R+ \
                                        @.Destination.NumReservation :=3 ^- p3 c4 a2 f  d1 x* a6 k
                                        @.Destination.NumReservation + 1;
- I* [+ E4 @1 B; ?# H( k2 D) {' z                                end;2 O3 Y5 y( I" v2 v$ G# h' R8 B* G
                                @.CurrIcon := "drivingHome";
; W! e9 ^# N# d8 V5 o. V8 a                                @.DrivingHome := true;
! Q) ?( O3 P  K  i                        end;
' u$ e. x) K# I                else -- the vehicle @ is empty, both vehicle and part are in the same dock station; H, |0 F" Y0 `+ ?, y/ m2 e
                        part := @.transpOrder;  i$ S5 f. @" j/ V
                        part.move(@);-- load part
* {0 v0 o+ M3 ~/ m/ i' K                        @.CurrIcon := "load";6 B. i3 K" j- N0 e- Z5 B" v7 x6 m4 {
                        GlobalDistObj := part.globDestination;0 Q8 n* f. M! ~& V: i% u
                        assignLObj := rgmanager.rgAssignL;
$ m7 f' c; o: C$ D9 r+ }. o                        row := assignLObj.getRowNo(GlobalDistObj);, R- `/ K3 z+ b7 c1 g. P: _' x* M
                        if Row = -1 then -- since 70( ?. x" ?1 W: ~4 P& @- `
                                if lan=1 then
4 O: w/ |% P- m9 l  M' w                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
! X( ^4 B" V! Y( \: d7 [9 i                                                to_str("in der Andockstation: \"",?.~.name,"\""));
8 d' Y: S0 p( U1 F7 u                                else
. W) |- U6 A& ^) |3 n- A                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),  F$ }1 g' g4 d  w& G9 l( t
                                                to_str("in docking station: \"",?.~.name,"\""));                               
9 |+ Q2 `# h4 x% R5 Y( x# A/ \# m8 x                                end;$ y) O- J" ?. C0 b  u
                        else* T/ O+ s) i% H
                                @.Destination := assignLObj[1,row];
2 i+ b6 l1 V$ |! ~' F6 L                        end;                       
6 P( K0 L) Q  _+ d9 L. f                        newDirection(@);
5 p2 s7 p, l- I7 C3 L0 @                        @.HasOrder := true;
4 Q- L9 A3 O- J0 g                end;4 p! F8 k6 y) |4 X. H+ M# B
        end;
/ G+ T7 [' s8 o/ A/ Pend;        -- of the method# C5 x) C5 D1 O4 c8 X+ Y
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
+ O% v1 f! ]8 o6 q/ t# J0 i1 a- ^0 N% t6 r
这是AGV_putin中arrive的method。6 s( ]- h( n* @! q. M4 w; x! l$ `
5 j4 _4 m. `( H$ _" v* D0 ~, @& G; U
当到达物料速度越高时,这个报警更多,: x: w0 k: L' a0 X& U
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。" ^+ e( c2 c) C& N# i
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?4 S/ U+ {* H1 z5 e$ h/ q

4 J) Y( z1 v7 k' o9 o6 c! z; A另外一个小建议,就是move,所有的move都可以这样
/ v; I; R/ K+ }4 [if not move() then debug end1 q5 F5 p; B. S* S+ t' _! ^6 O
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。1 c8 v( P" C' e+ s% J) p. T; }9 Y
plant simulation中的free libraries有AGV模板,
) ~3 X! y  A! F& W8 P里面也有案例。
; w# z; {- u  M! f9 E我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
0 ^2 Y' n  A! K7 u* x/ k
/ A6 w; p3 {& s6 k% t, b我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ( D& c; c; z$ {+ _/ Y* V

( |" B& [1 p/ Q4 a; `- {; N( q那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
: Q% c+ d5 `9 `% N  h. _! O这是AGV_putin中arrive的method。
" g* P% r, N) }% k
4 y( f% u2 @; ^当到达物料速度越高时,这个报警更多,

7 W# a, q2 N; C; q另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-3 07:13 , Processed in 0.031020 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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