设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7438|回复: 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'  N( `6 \7 `; C/ k& o0 `! j
*/
: C/ d$ Y8 H( n5 I: A% Ais6 j5 E3 |/ N: V2 L" X+ ]3 d' G1 c
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
& Y! R$ ]# j0 H  n4 n6 [do
- Q* q  W: \& M) o8 O, [; h        Lan := rootfolder.Internal.Tools.AOLlanguage;  z: Z8 H1 X# }4 E5 w6 H) Z
        if current = @.Destination -- else return
% l3 P( A; L: Y$ c) `  X  s2 s        then! _3 I+ o; C9 R* t! d( t# r
                @.Destination := void;
  v" u  A7 w+ x# c                if @.occupied then
3 x0 v5 N$ {9 X  u( r2 y2 K                        part := @.cont;
! L9 a5 M; d/ |- }  J4 q: ~8 n                        @.transpOrder := void;
* R& v" p1 \) P. U) D# v                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,/ O! T2 g1 x0 w" }/ q
                                @,root.eventcontroller.simTime);
6 m) a8 e7 u7 h! b& j4 n                        @.HasOrder := false;9 g) U) G6 v6 `5 |% G  W. \
                        @.DrivingHome := true;  e& n( F; _- V3 i. G
                        rgManager.tryToStartTransOrder;  [& b( B5 l% m: l
                        if @.Destination = void, c1 B+ C% h& O. d( b% R
                        then -- no transport order for vehicle @0 ^$ w# Z: ?1 Z( z. |$ Q2 x" R4 S# ^/ V
                                @.Destination :=- ]! J+ a& h* b4 S
                                rgManager.nearestFreeStation(@,track.~);! a" g# I- |, p# ]: }  l" A$ o
                                newDirection(@);   
: V  }/ b# \; I; A                                if @.Destination /= void then
" Q$ A- i/ V, }, V9 k                                        @.Destination.NumReservation :=$ y7 |# ]$ K* B5 P( G3 Q' r; B
                                        @.Destination.NumReservation + 1;( s! H% X$ {1 h2 }' {
                                end;! B. o0 ?( \) S4 I, N
                                @.CurrIcon := "drivingHome";
) Y- J: m, r8 w* w9 V                                @.DrivingHome := true;
: n0 r9 Y. [' g. s: o# X                        end;
% U& g5 m( a) A, ^0 T, g                else -- the vehicle @ is empty, both vehicle and part are in the same dock station4 [7 F  F8 ^: d
                        part := @.transpOrder;- V$ R: F" L3 L5 n+ ?
                        part.move(@);-- load part
1 F6 O1 B2 B9 k" b                        @.CurrIcon := "load";
, c  Q2 u6 _( A4 g1 P                        GlobalDistObj := part.globDestination;; c6 t% p/ N5 b( K+ g( y
                        assignLObj := rgmanager.rgAssignL;
/ Z3 F- P0 l; f8 }" ]2 d, C, ^                        row := assignLObj.getRowNo(GlobalDistObj);
  ?0 A- X& k8 x+ C+ d: |2 a, k                        if Row = -1 then -- since 70
5 H# Q/ G4 p; M4 _& M8 n                                if lan=1 then, H8 T( n- F0 f
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
( k4 x8 O; t+ K5 x2 k0 w                                                to_str("in der Andockstation: \"",?.~.name,"\""));& ?: T' c; Q* w* y
                                else4 {6 c! I- {1 T6 x8 x
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
( t4 {9 [1 D1 I! ?. G5 S                                                to_str("in docking station: \"",?.~.name,"\""));                               
) E- F$ f8 W- t. N+ H+ L                                end;
% Y) \4 H% k6 d2 e                        else
- A) G4 N' h& E4 t                                @.Destination := assignLObj[1,row];
* q" q  G6 b! Y% n                        end;                        ! _5 f) W9 q* A3 `. ^
                        newDirection(@);% z2 X9 p  N; Q" o8 r
                        @.HasOrder := true;+ X4 Z8 t) N9 k" u" u
                end;
/ e( P* p2 _/ G! U        end;6 Q' C* h9 m9 @' {) U9 q/ e
end;        -- of the method/ U$ Q8 s$ [, f: E
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 5 @: a  q" W( j

& D) |% A; J$ ~这是AGV_putin中arrive的method。8 J5 j6 i  O( y0 \1 t

  b3 f1 e$ j0 T# N# t当到达物料速度越高时,这个报警更多,
. J: }) f  d2 M& R" i% Z' K可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。- _7 p+ ~, q- F+ p# l' \
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
9 ~/ o3 i5 @5 G4 g* n
6 A" m; {# ]. {+ D( d另外一个小建议,就是move,所有的move都可以这样* h4 H0 }" \/ X8 N/ e% W
if not move() then debug end" L8 u9 [! C: k
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。* D+ M- B" C2 s% g3 J. P. X
plant simulation中的free libraries有AGV模板,
" |  r; w( A: t1 [* o: W里面也有案例。- I* n9 E" }: k. S7 J8 R# r
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。7 p7 U9 z0 y) [1 \! d

  \6 r: L/ g9 D/ |# a我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 " `9 e& g/ l' ?0 O$ u
# @( Q. d% z6 r9 W  x! S' H' n
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 # z" i# b! m7 b. G& r" t0 B
这是AGV_putin中arrive的method。
+ e; J% i* p- ?' f7 D1 U/ V. n& T& W* {% f3 M
当到达物料速度越高时,这个报警更多,

. c& s; g6 e7 |: K$ Z另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-11 11:14 , Processed in 0.018407 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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