设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6088|回复: 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'
1 b+ f* D  l6 R, I*/: V  T$ l! O# R" I+ R$ p
is
$ E2 m) h* d  N' m$ Q        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
' g2 O( b: X/ ]- y1 `5 kdo9 e4 {2 A; F1 m9 T# d; H
        Lan := rootfolder.Internal.Tools.AOLlanguage;
) k; A% x* Y- P% E' M4 u        if current = @.Destination -- else return
) c: c5 x6 D1 P. [# b0 f3 L        then. R* e4 h9 P3 F. C# z- o, o
                @.Destination := void;5 p: a7 q0 @' h/ M2 \5 G: n
                if @.occupied then
) s( U+ F) S1 I# w- \2 M3 {                        part := @.cont;
; K* ?  ^  U) N/ |1 D                        @.transpOrder := void;
' G8 ]" U% |: R) u0 g( r/ |& q5 A                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,' A0 \% O" @; c& }
                                @,root.eventcontroller.simTime);6 j0 f4 d1 z5 p' T8 n- b# _
                        @.HasOrder := false;9 n5 l4 s" P8 S: n0 x9 C* u
                        @.DrivingHome := true;
/ w" T7 t# f5 h# A( u8 K+ c) r; [                        rgManager.tryToStartTransOrder;
/ k8 j$ X7 f+ Z                        if @.Destination = void9 ^; E% w3 _" K( y( W, v9 o
                        then -- no transport order for vehicle @8 E; G/ X+ b+ c, L' p: o
                                @.Destination :=
5 [8 s( u/ c9 R7 Z3 V$ B                                rgManager.nearestFreeStation(@,track.~);  q2 ~0 v, ]* O6 w1 W$ T
                                newDirection(@);   
" `5 i) K% G1 B6 r- Z5 O                                if @.Destination /= void then2 f, f3 B+ h$ o0 L9 R  V  B
                                        @.Destination.NumReservation :=
% ~! B% D7 v" a7 p0 R- ?+ U                                        @.Destination.NumReservation + 1;
8 |6 e0 {5 o5 _5 P9 ]                                end;
. a7 Z2 H* F1 {) n3 a                                @.CurrIcon := "drivingHome";7 D+ a4 R  F  A6 C0 N' d" }+ x
                                @.DrivingHome := true;
  l8 s/ l4 c) H# }                        end;
. z5 |6 n" w3 |6 `                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
. l2 }5 V$ Q# ~) D5 k8 p2 x                        part := @.transpOrder;9 p2 c( |$ @) v. B, `$ X: Y+ E$ H
                        part.move(@);-- load part+ D7 W5 S1 [3 Z1 i8 V  U1 O
                        @.CurrIcon := "load";
; L3 b3 h, {. q3 D                        GlobalDistObj := part.globDestination;
, I' }1 ^4 e7 X! M( I% T                        assignLObj := rgmanager.rgAssignL;
; R4 H7 O# S" \) ], I' ]6 C7 f                        row := assignLObj.getRowNo(GlobalDistObj);
6 v9 y! ], K' u6 {0 d$ _, b                        if Row = -1 then -- since 70: L( T  Q. j- ]! ^+ x/ C8 @5 D% E
                                if lan=1 then& P, d7 V* B8 x5 p) Z
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),- p2 H" e$ u. p9 T8 c
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
5 R1 j- Z5 O" w1 L                                else
& d/ Z1 J9 h# x+ i3 c  z3 {( I* s" |, z0 e                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
$ t, A8 Y1 o1 |! i& h                                                to_str("in docking station: \"",?.~.name,"\""));                               
2 Q4 _" G& f$ Y: K6 R4 I& a% ^                                end;8 \6 K4 n: Z) d" ^
                        else
( ]2 v) Z# k/ r# U9 |) ?4 n4 r                                @.Destination := assignLObj[1,row];6 I( Y; w2 C8 Y" r  B+ ~4 k
                        end;                        " b" x2 @* X) ]
                        newDirection(@);
# Q# C0 M9 p# J  X1 z. G% L9 u# N                        @.HasOrder := true;0 |' }1 L8 h6 |' o7 F  T9 Q
                end;
* `- K) {4 Y5 \, X. H0 [        end;1 q# P" `. u- k4 P, b  l
end;        -- of the method* a' V: e& W% u1 M5 A
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
! ^8 X5 B  j/ ^# X6 M2 [7 G5 b8 c0 Q. k
这是AGV_putin中arrive的method。- K- l* h7 G4 m- [0 q
( J" r( F1 R; Q2 E- _: l+ [
当到达物料速度越高时,这个报警更多,
2 B) N' y3 b* o! ?, p* C0 s可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
; R2 P0 W8 j6 {% i程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?: A  l6 z8 }0 v0 @
7 K' l7 k( s( V/ R. a
另外一个小建议,就是move,所有的move都可以这样; R, j5 C7 s0 R2 h
if not move() then debug end2 q) C" e9 `* j3 u7 t( _% h1 j
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。) f" S  g. V% O3 [
plant simulation中的free libraries有AGV模板,
$ D# |) H4 J% v. p& }& t7 j里面也有案例。) ?5 J0 |( e5 p1 W3 ^% {( ~9 r
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
" H) w/ q* B0 W. z2 i! l1 \4 h3 \
& {6 H0 J4 ?0 N3 B; O- _我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ( }& i7 L0 J1 m& D8 [! C3 u, u
% ^& ~$ z$ Y6 W& J9 n
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
% c- Q% X. g& \这是AGV_putin中arrive的method。2 D; E9 f4 S! D: c

$ _# E% J1 f5 t5 i  C0 i. m3 }当到达物料速度越高时,这个报警更多,

$ N/ y$ G8 ~: \1 I" N另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-17 14:53 , Processed in 0.018418 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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