设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9840|回复: 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', u4 n3 j: O: R' N
*/: @  `* I) b2 R; _* J
is1 i1 r9 z' P) ?3 i- u
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;$ o" @$ `+ F% l# a0 A
do
2 Y- H7 I; B9 U/ Z$ O& o, Y        Lan := rootfolder.Internal.Tools.AOLlanguage;- W6 g$ M+ Q! F
        if current = @.Destination -- else return  U* i. L  V6 L. f  T5 t3 S* G
        then
1 g) N& s( E) K: c! n                @.Destination := void;
  ?7 @! R( I) c. q& M' w                if @.occupied then
5 y, i9 Z2 ?- S- ]: @+ ~* O                        part := @.cont;
' v" p$ \/ v4 O# J) R4 d! J                        @.transpOrder := void;, N: ?2 A( L. D( s9 T* v6 A
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,; Z1 A0 A/ F" Z9 a% b+ R
                                @,root.eventcontroller.simTime);3 l6 ~8 f& `6 P( ~/ |
                        @.HasOrder := false;
5 E: z( Z0 C. o                        @.DrivingHome := true;
( _2 x  ^2 s/ o& n6 K$ Q5 S  p                        rgManager.tryToStartTransOrder;
) v+ {% H/ o6 l- l- k7 w# r4 D                        if @.Destination = void& F5 ?) N2 p6 D0 K( R. V+ f; l
                        then -- no transport order for vehicle @, ?2 U0 j- N( q5 V& {
                                @.Destination :=
5 q$ Z6 F3 T7 B, t4 w$ N1 R                                rgManager.nearestFreeStation(@,track.~);- Z5 e% E, _, g3 Z+ ?( R/ Q" A
                                newDirection(@);   5 B  O2 P' b: p/ ]9 \8 U9 ]
                                if @.Destination /= void then
* a5 o$ |. U, v                                        @.Destination.NumReservation :=
2 H7 B3 R, v+ E4 V; q$ ~7 ^/ W: I                                        @.Destination.NumReservation + 1;
7 F1 z" W; N+ l3 ~# v                                end;3 i$ Q! X, Q3 j2 f
                                @.CurrIcon := "drivingHome";
  r6 i0 x1 G- [' m4 `9 f: R                                @.DrivingHome := true;! s; g- W: j0 F# {. @* |) r
                        end;
! s) p0 g3 Y+ V3 |0 M1 P+ y                else -- the vehicle @ is empty, both vehicle and part are in the same dock station* m3 Z: t' }- `% L
                        part := @.transpOrder;1 A2 Z, ~" \$ k4 p; g$ X
                        part.move(@);-- load part1 O: C0 b! A8 Y, }% \% k
                        @.CurrIcon := "load";
* u/ d; t) }6 ?                        GlobalDistObj := part.globDestination;' ^  B2 Q$ E+ L* p) {' l
                        assignLObj := rgmanager.rgAssignL;  ]% P& Y3 M) N$ r9 c. F$ s8 c
                        row := assignLObj.getRowNo(GlobalDistObj);; o  ^9 \4 x% U% s9 h2 W) p' z2 G
                        if Row = -1 then -- since 70
7 F4 E: ^/ L0 B) L0 Y/ i: @# @$ H                                if lan=1 then
: M- r! Q( Y; A$ P$ X- `                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),! x1 @( c9 g! H0 u: Z6 {) c2 @
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
% o4 D3 _! N+ H                                else, X) N- z& H* [
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
/ T: B; P* u3 c1 m9 N- G                                                to_str("in docking station: \"",?.~.name,"\""));                                : r  ~$ I9 a1 J8 l5 ]
                                end;
0 a2 x* L0 |0 R8 Y1 `                        else9 k5 x8 e9 R) H, Q4 _7 |' h' k( P
                                @.Destination := assignLObj[1,row];
7 s2 ]0 X0 T/ c" p  u5 \                        end;                       
2 v2 X: S/ y" I2 d4 d( K2 `$ y9 B+ T                        newDirection(@);
1 a9 i, z) m/ ^# j! z9 ]3 |                        @.HasOrder := true;  u4 C+ J' c6 R
                end;, q4 g; K. J4 F3 M6 r9 i# ?
        end;" w% [9 F8 T' T% U- r% z
end;        -- of the method& z& Z, Q$ Z- u) v5 B4 g( P
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
0 a# V# [3 n& y7 U0 I" {7 n! }+ z& P1 C- h. C% {8 K1 Y
这是AGV_putin中arrive的method。
6 m: w9 [2 a% ?/ v
' Q. A# i7 f/ K  P* g当到达物料速度越高时,这个报警更多,
  k: t0 }' X6 A可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
6 z$ r4 R6 {1 N5 H程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
0 k8 n9 z8 i9 c4 _' S! A+ z# Y9 _) i) x/ j! x9 x7 x; M, N# ~
另外一个小建议,就是move,所有的move都可以这样+ I; G& Q! A  ?$ f
if not move() then debug end
) Z. W# D; J/ K" S" R这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。3 ^0 ^  s; q! A) a& S5 q* P$ U
plant simulation中的free libraries有AGV模板,
7 P- w; \7 K! k. t4 W/ M- C! m里面也有案例。
; b8 ^* D' ]: J* @# [2 v3 X我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
3 k# b* }, U9 T4 t
! H$ Z0 E2 O& M我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 2 l$ ?9 a. C, I5 y, }9 @$ X8 H% l

& V3 w" W" p+ @) g3 ]- M+ w/ _那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 " x' x! n7 X! T( ]
这是AGV_putin中arrive的method。
. q8 C/ W6 o) X: }6 V
4 @7 M4 o; S7 H& c当到达物料速度越高时,这个报警更多,

7 H# R0 ]$ z5 J3 R另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-28 13:35 , Processed in 0.016669 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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