设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8675|回复: 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'7 p1 R; C8 C( C% q& o+ K
*/) L, s. ]8 S1 E/ Z; s
is. e+ Z  S& @/ s  c+ g
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;! c) E- ^8 O4 y
do  C% g& z, ~: z' U; [% y. i. c& u
        Lan := rootfolder.Internal.Tools.AOLlanguage;
, ?2 A% M0 \% T( a" d  U        if current = @.Destination -- else return& S8 W% b, v/ I
        then
5 W- M, |" r+ d                @.Destination := void;
, f& D/ w! p  ]) w                if @.occupied then2 |$ N& J7 |6 Y* u) T) e
                        part := @.cont;. c7 r! @1 P4 V$ q
                        @.transpOrder := void;% O! t  G, D- b
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1," z8 `( I+ h% S  g0 b
                                @,root.eventcontroller.simTime);( X$ o! O$ @7 _9 X0 T  X) T
                        @.HasOrder := false;
6 S- ]4 E4 Z( e                        @.DrivingHome := true;- k  }3 n+ n5 Y2 N+ ^, n6 N3 Q3 s
                        rgManager.tryToStartTransOrder;  M6 n+ n4 I( {' f
                        if @.Destination = void
4 C2 C% I) t7 f3 \0 L% Q) O$ w3 u                        then -- no transport order for vehicle @
4 g$ @, K) ?1 w! l+ w                                @.Destination :=  {$ d" R. D& s* u# j3 p, ]
                                rgManager.nearestFreeStation(@,track.~);
3 j  x+ m  V% Y- ~. A" D4 L                                newDirection(@);   6 U8 x  u  J2 u. U5 o4 h4 e  r8 h
                                if @.Destination /= void then, a! [1 q3 B# x0 h% _: ?; q/ R. t
                                        @.Destination.NumReservation :=) R; M& a- m8 w7 k/ X/ F
                                        @.Destination.NumReservation + 1;
0 x& `9 ^2 U$ M8 |+ ]% O                                end;
! D8 b0 T) v% N6 a7 h/ l$ o                                @.CurrIcon := "drivingHome";; f4 N2 a8 Y  x, d5 f5 O7 k
                                @.DrivingHome := true;
/ a8 l+ P# x+ b3 |                        end;. T+ t  l" h# ^. M# @/ W
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
! n: ^' Z+ P0 H! N( R: K& P9 {                        part := @.transpOrder;2 B+ L/ A7 J, C0 I7 z# w( u2 y
                        part.move(@);-- load part6 |' g) ?9 u. G+ B/ k. N
                        @.CurrIcon := "load";. D& K) ~+ A9 J6 u: ]
                        GlobalDistObj := part.globDestination;
4 r8 q0 q  ~; e6 j+ e9 o                        assignLObj := rgmanager.rgAssignL;
, r9 b  O  v% d6 ?5 j                        row := assignLObj.getRowNo(GlobalDistObj);
$ b: W! L. s. t* \                        if Row = -1 then -- since 70/ U0 v  N& W; l# N/ L% `
                                if lan=1 then
3 b: _' F- Q& b2 [* X                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
; G' U: x3 @8 p9 `                                                to_str("in der Andockstation: \"",?.~.name,"\""));
- [1 |0 P3 j' p# w) B, L& C                                else
% P" x5 ?1 k5 O: u: H' D                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),; q2 i+ K, J2 ~* |/ o2 X$ Q
                                                to_str("in docking station: \"",?.~.name,"\""));                               
8 W: k: B* q( ?1 E9 ?$ H                                end;
: R; J) g" y- B! {7 ~% n  N                        else
9 V' ]3 U7 O, w- P( x                                @.Destination := assignLObj[1,row];
( |) z. D+ ]  X2 l5 c$ A                        end;                       
4 ^+ H0 S, y' ^0 I2 y# Q1 I0 o                        newDirection(@);
' b( W- {" W2 ^% h2 j. E                        @.HasOrder := true;  ^& C+ b3 R$ o, b* D/ W9 \7 j
                end;
* a- Y1 M) f1 }) u        end;
2 t$ s' G8 ?  Z$ {) p# Rend;        -- of the method
% t- ?5 ]) n- t2 d
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 6 X8 U8 M- x: |) o) e+ r7 K, O; T
  @' `- L0 ^3 _8 |: K
这是AGV_putin中arrive的method。) J5 O6 w* k4 i# L  C

8 A8 }8 K2 k- Q& B  j6 e* k当到达物料速度越高时,这个报警更多,
- S7 g) b8 I+ u: s可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
' D$ C9 d- Q, @5 {- [( Q% n- {4 P程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?7 R4 r3 f8 C% o2 C2 I" g, L
* ~% j9 E! n0 a0 }5 g
另外一个小建议,就是move,所有的move都可以这样
* B$ d3 v; r" ?& R# B6 V7 tif not move() then debug end9 H5 P; e, y' t$ E/ k
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。4 ^& F1 [% s3 [8 d9 T
plant simulation中的free libraries有AGV模板,
) z1 _$ i9 E5 ?; k里面也有案例。
7 Z# J6 D' N! }% ]我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。: W# U  D$ g  c) }! B

+ T2 v8 q* i9 H$ E, G! Y. l我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 0 }" r3 e# I8 e

$ W* ]7 \3 J" e那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
$ K7 g0 }. s7 O; r% P这是AGV_putin中arrive的method。
2 h- s& J! \* y/ G! i# o4 b1 X$ l
当到达物料速度越高时,这个报警更多,
, Z% R! S  z8 \$ g5 w
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-19 15:55 , Processed in 0.015370 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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