设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8570|回复: 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'3 C2 p( i5 [/ y$ y# ^  d: g% Q
*/8 M+ Q3 L: [: [: S# j  A9 F
is
4 y  J( c9 N0 _! G4 D3 q        part, GlobalDistObj, assignLObj:object;row,Lan:integer;. C, o5 F7 F2 c) D8 B2 _
do
2 i/ G. H. \! K& |/ B# h' ^5 }5 P        Lan := rootfolder.Internal.Tools.AOLlanguage;
* v8 Y2 \9 g- e" u( Z% X        if current = @.Destination -- else return1 h( v: f0 t+ y# s% O4 |1 C
        then+ u8 {/ Y& A7 Z. b; x2 y
                @.Destination := void;
3 d0 d, B! w  N, O3 O) r7 x6 C                if @.occupied then+ s8 F7 G, u: K  C
                        part := @.cont;
: k6 V! K4 G3 a$ s4 ~- p6 z+ |                        @.transpOrder := void;, P" i6 f, y' e- @' g8 ~6 H! Q! E
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,4 ^4 |9 L8 u6 a7 ]
                                @,root.eventcontroller.simTime);! m' S( g& s; h
                        @.HasOrder := false;1 I- H+ F- W' U
                        @.DrivingHome := true;
/ H3 N  Z' X( N1 p* q5 z# R                        rgManager.tryToStartTransOrder;) a8 e9 @4 i# {" p
                        if @.Destination = void( s" ^5 @' I: c+ U/ s
                        then -- no transport order for vehicle @
1 E2 K3 G6 ~  s( m6 x7 |: o% n, v8 T                                @.Destination :=0 k4 e3 K  L; O  s  A, u) \6 ?
                                rgManager.nearestFreeStation(@,track.~);
) i1 V$ h% H: ?* i                                newDirection(@);   
* Q1 V+ B# p6 r. z% ?' ^                                if @.Destination /= void then$ B$ O2 I0 {8 u$ z. w6 ?9 a
                                        @.Destination.NumReservation :=+ m& K6 G+ \5 l5 s/ @& U
                                        @.Destination.NumReservation + 1;
9 I7 e3 s: s% R4 M6 E                                end;* O" q# d3 E# u5 F' y! K
                                @.CurrIcon := "drivingHome";
" N1 u5 Z$ }2 b3 f3 P4 q2 b. ?                                @.DrivingHome := true;' b- \9 i9 s' V$ v: y6 g6 F1 B: _+ L+ ?$ c
                        end;$ E# Z' ?. u0 Z, r4 _6 Q
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station/ ~' I2 g. [4 h2 }9 S7 E7 T1 ]* |  _
                        part := @.transpOrder;
4 D& P6 b1 `3 T0 V; y                        part.move(@);-- load part
9 b$ j" x" g' [9 C                        @.CurrIcon := "load";
( V7 O8 a* j: g' G1 `6 @6 c  o& ?; {                        GlobalDistObj := part.globDestination;( X6 r* e2 Q: \8 \
                        assignLObj := rgmanager.rgAssignL;5 s/ V' c; S) Q2 z) y9 ]7 n$ l
                        row := assignLObj.getRowNo(GlobalDistObj);% Y" ?2 {$ j& \7 L& ?/ z  c
                        if Row = -1 then -- since 70" \! i& ^" ^6 g( ~% L/ t
                                if lan=1 then
9 @1 L! |* L6 h4 b! A* a                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),% i  t/ N, s, s. _
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
2 a! N3 F4 [* w# W: a                                else9 Q* V. i- z/ Z: n, z
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
4 F3 y; q. C, W" ?5 f' [( b# A                                                to_str("in docking station: \"",?.~.name,"\""));                               
6 s1 M, @. k# e' |                                end;
% p7 q7 u) s7 I9 J9 u( i6 ~' j2 M  b                        else' C" M. l( x5 [5 h  t4 f
                                @.Destination := assignLObj[1,row];5 b  U9 L( _' K  h6 w2 {* H9 F) Z
                        end;                       
: C' z) t% ]# n                        newDirection(@);
! @( j' N! }+ E5 V2 \6 E5 c                        @.HasOrder := true;% i2 T! y) i3 A6 J7 ~% E
                end;
% c7 l0 A" a/ Z$ {        end;
$ j) y, h7 |, e4 b6 H9 t, Gend;        -- of the method) v; i) }* v! A  r* f% q% W. J
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
6 f, N1 Y1 E6 v! {3 m4 r: R1 V) w
3 ]9 Z4 T6 `2 F( C6 ?这是AGV_putin中arrive的method。
1 g1 B6 d- Q5 Y. |
5 S/ s* M, K5 ^* _( G当到达物料速度越高时,这个报警更多,: f% Q& D2 N; K+ ~6 t
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
7 `5 ~$ `7 d6 N7 a% o) x程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?. t8 \; `, k! L$ {3 A( o2 r
/ p3 k' R  t# o& N* t7 p
另外一个小建议,就是move,所有的move都可以这样4 S9 d  c# E  K% Y
if not move() then debug end, R2 f) r; ~6 D+ I" j5 T  B
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。6 ~* ?. @0 T+ k5 v
plant simulation中的free libraries有AGV模板,$ D4 N; E6 ?% k% c
里面也有案例。
. f* w6 _! [2 ~: a; @我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。' F6 ]0 C4 c& F2 |* ?- e

  t4 j8 w) H6 z我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 $ M8 K# a) H: b1 f3 J6 y0 m0 h

9 A2 p! u( m  ^- a& ?3 W4 N那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 " @! Q* K5 j' |$ s" s6 }
这是AGV_putin中arrive的method。
9 s5 A% b2 o5 `% w4 ~6 o. W* C( J& h, U( n) m, I( ~
当到达物料速度越高时,这个报警更多,
/ u+ f  u8 T# i
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-12 14:44 , Processed in 0.024782 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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