设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8120|回复: 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'
4 {6 l3 u+ T, b( Q" F* n6 l*/
+ U+ P& M; \. {, ~is
# f, p3 E/ q- j, \7 H4 G        part, GlobalDistObj, assignLObj:object;row,Lan:integer;: `6 z5 M$ m8 A' }# j1 l
do/ Y$ a/ D% K) r+ n/ m6 O
        Lan := rootfolder.Internal.Tools.AOLlanguage;
! i: w' O# \9 _7 o5 z1 `        if current = @.Destination -- else return
. [* j- b# X* g. J# H        then# h$ X* ?7 Y) |0 K5 Z+ d' O
                @.Destination := void;$ D6 P2 O" L5 B9 F1 W
                if @.occupied then
" O# @$ _/ X$ d6 p                        part := @.cont;
4 `% t4 V5 p: z+ p9 b; C' a! I' r                        @.transpOrder := void;
! p, s- @5 w: |. x5 M1 w+ l                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
2 ~% |6 t1 z) a) B                                @,root.eventcontroller.simTime);
9 N2 K& z- g. t! @3 q5 P                        @.HasOrder := false;9 e2 Z. ^3 b: n% f2 N' j9 ?
                        @.DrivingHome := true;
3 `2 }% m6 i, `% }# V                        rgManager.tryToStartTransOrder;
9 W% W: J" o! C) N0 q; y5 c                        if @.Destination = void
! u5 b' o, e& {& {                        then -- no transport order for vehicle @
3 @1 s0 V/ @& W# a                                @.Destination :=
& x5 }! M: p4 Y                                rgManager.nearestFreeStation(@,track.~);
+ t' B# r# V$ H  u; e5 f                                newDirection(@);   
: H6 e+ ~, h. S9 B- F) o$ _                                if @.Destination /= void then) J0 i, _. I  P
                                        @.Destination.NumReservation :=
: ^) L& X2 f, a" y+ R8 ~( v- ?) {                                        @.Destination.NumReservation + 1;
  O& E& T2 W. b: J& r                                end;* L9 q+ I. \/ s( ~
                                @.CurrIcon := "drivingHome";
( Q7 s$ J4 O1 S& A8 |* p3 g9 c                                @.DrivingHome := true;
) L3 J6 N) j7 M) J# Q* m1 i4 |; R                        end;
( O; m; l6 ]1 N2 G! v% S4 c. A- [! ^                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
" i4 ^( z* D. J' @! ]# h* z                        part := @.transpOrder;! ^: m3 ~' R( Z: K" ]) T
                        part.move(@);-- load part
6 @( u; Z& }* `: t$ \; N                        @.CurrIcon := "load";1 ?4 M  ^/ p1 V8 }( [" p- M
                        GlobalDistObj := part.globDestination;
7 P: L9 {, C# e, e5 I                        assignLObj := rgmanager.rgAssignL;* V3 X2 q& l1 v) M
                        row := assignLObj.getRowNo(GlobalDistObj);
7 U% h4 H" L( ~( W* y                        if Row = -1 then -- since 70' ^: b5 k3 A9 |0 t
                                if lan=1 then; g( G5 T5 y% T2 W4 r
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),* k, X( n# G' E- W+ W0 E+ ?
                                                to_str("in der Andockstation: \"",?.~.name,"\""));% ?- s' h# Z& e  }  o
                                else
2 Y/ L, X$ ?4 e  k' v6 o3 o" w                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
$ |$ T& k# g3 O1 k1 ^" s                                                to_str("in docking station: \"",?.~.name,"\""));                               
; d5 i. a! a6 T9 y- y4 K$ F& ~                                end;# ]( P" i9 x7 @: C3 `5 B
                        else
1 ~+ G% l  @8 F                                @.Destination := assignLObj[1,row];
. \( w+ k+ y, Y, P                        end;                       
7 L* M& I0 v& [" y( m! Y7 s                        newDirection(@);
4 p7 s- N: n- U% u! R) m+ P! N; M                        @.HasOrder := true;" ]4 b, x- T/ t
                end;
  F9 @) Y5 t, _5 N$ G        end;
1 x9 ^7 b/ |. e4 T8 D# F/ I: |end;        -- of the method
) s, b: i* x3 B
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
( d0 v* i: R+ J% k0 x8 Z1 \$ ?: T2 `) X5 X( J5 z' a  u8 o" r% v
这是AGV_putin中arrive的method。& s/ g' p1 G3 Z3 E4 D: J$ v2 v! q

+ i$ f" {+ U) O% r" o当到达物料速度越高时,这个报警更多,
, y  k# ^1 V! Q0 Z' B6 R6 n2 f可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。0 ?& c2 `5 T  M, q' c
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
. D3 l% Y  p# F' E! y! Z$ C% ]* V- `: s
另外一个小建议,就是move,所有的move都可以这样
% E6 R* W; F! A4 n, m3 @if not move() then debug end
1 F  j  U# d! q/ T- Y9 i" H这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
% m# {0 [9 i. Z$ g9 ]1 Rplant simulation中的free libraries有AGV模板,' w9 j% |: q4 l1 R
里面也有案例。
- L& e8 q6 ]* `% |3 D我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
5 Y" g# d4 G/ f' o5 d3 y9 j4 e0 F$ Z( A0 X! y1 C4 X
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 2 T8 v! J- u7 a" U4 }/ @: R
7 L; ^  Y5 a/ h9 E
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 + |% L4 e6 O1 E1 L" Y! W
这是AGV_putin中arrive的method。
4 N4 \: X+ x9 S' N9 q  I9 l# U
  t4 ?% J' D' u) D/ e当到达物料速度越高时,这个报警更多,
* B$ V: X2 i. n8 ]! q# h
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-15 20:46 , Processed in 0.023635 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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