设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10010|回复: 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'4 \, h  S6 s) g
*/; A! X/ V* n. I; m4 c
is
% u6 V' @. K% y2 I5 r% _        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
, T! ~3 S- |( ~; N( V2 S9 wdo
  w* z; o; l9 C% X1 l9 M+ W        Lan := rootfolder.Internal.Tools.AOLlanguage;
0 Z" y8 f2 d6 Y; G3 ?% \        if current = @.Destination -- else return# E& X1 \0 {  _$ A: y* R4 ]2 V) z
        then
1 c% J: h3 p* o4 ]" ]                @.Destination := void;
& r  C! e/ x. |/ U6 L9 e                if @.occupied then* n: y" H1 f1 ~# F0 Q% C
                        part := @.cont;! r7 m) f9 }. v: l2 D3 F: R& Q
                        @.transpOrder := void;4 v9 ~0 V( P1 f8 v3 c
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
3 n/ C( Q. q: c" j* X& ^                                @,root.eventcontroller.simTime);
) _5 j4 [5 F- I$ ~( j+ g                        @.HasOrder := false;
* x9 u5 J( e# i" _6 B% i% E8 ?! b                        @.DrivingHome := true;
+ A6 C! q1 k7 f) Y3 j+ q                        rgManager.tryToStartTransOrder;
% A5 r9 T. J2 g: j                        if @.Destination = void
5 Q3 ?8 E; C: a1 `% O0 K. M                        then -- no transport order for vehicle @
, [8 k. z" u( @7 ^0 G( ^                                @.Destination :=9 m7 y+ k+ r+ I' I
                                rgManager.nearestFreeStation(@,track.~);- V' Y" W( V6 q
                                newDirection(@);   1 U# I& i& M( b
                                if @.Destination /= void then- k0 P( H" j% f% B2 P
                                        @.Destination.NumReservation :=2 j. \/ w3 r9 e0 S5 p8 a5 \) _% @
                                        @.Destination.NumReservation + 1;) o. n6 K' ~) |! L1 h% a
                                end;
6 k& S0 |, w1 A5 j' h                                @.CurrIcon := "drivingHome";4 G, l/ M& X- L. L/ I7 z; B0 n$ j
                                @.DrivingHome := true;  j- V' Z' u' |  y9 b. T
                        end;! G# o) J: h( L" V  _$ M" y& i4 R+ ~0 [
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station7 V5 r) h( J3 v1 N' r
                        part := @.transpOrder;
% M/ \4 m5 k( p) l" }2 O8 V# E& @                        part.move(@);-- load part
, I, f. x  @- P2 `6 e                        @.CurrIcon := "load";
" E  R( U3 h1 T2 n                        GlobalDistObj := part.globDestination;3 L: J2 ?; M! k
                        assignLObj := rgmanager.rgAssignL;  V7 {" z% T' W4 l- r; d0 h
                        row := assignLObj.getRowNo(GlobalDistObj);' E2 E( @# G: r) E
                        if Row = -1 then -- since 70- A: q2 y/ Z, F' O. ]
                                if lan=1 then
0 q- h0 Z3 L( \2 P" H+ n! ]                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),: a+ M; {$ f" x5 L, K% x
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
/ k3 C- P: w8 e7 |7 O! I$ N( ^                                else/ ~' S4 Z+ W5 ~! F$ o
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
3 u3 f( d  ]7 N8 q+ `  V+ [: r                                                to_str("in docking station: \"",?.~.name,"\""));                               
: F, ]3 f; i( U9 v+ ?) J                                end;3 g4 d8 ~9 v9 h2 W
                        else* s5 D+ @) f& J
                                @.Destination := assignLObj[1,row];: `3 S* }. W. s$ ^! S7 w4 Y
                        end;                        # m, h: i. }+ `9 W% [, U5 M
                        newDirection(@);
9 z* }7 ~: y7 o) Z; R+ O                        @.HasOrder := true;
/ {( ~5 j, N7 g4 t- ?# P                end;
8 }! l0 A0 U( U* w3 S9 f: r2 m        end;9 h. Y! A8 F/ X$ \- k7 z' \8 S+ X
end;        -- of the method5 `/ o8 _! N* V  p/ G
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ! h# N  S. w* j: j% v4 M
7 Q; [3 m/ E0 u5 w
这是AGV_putin中arrive的method。9 A) W* Y7 z' |# P3 G

% c6 Z. U, f" |: W( m- j8 o当到达物料速度越高时,这个报警更多," \4 T4 s8 p* n5 Z5 y" a, i
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。  M; G) q2 Q* O$ E
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
. m/ N& h1 P& o9 N0 ~$ s+ Q! u8 g* q. l& ]: b8 G
另外一个小建议,就是move,所有的move都可以这样3 |8 g$ r# y7 c) c3 Z
if not move() then debug end
! h! |; f; x5 ^3 L7 W这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。4 C: E$ y! r4 @9 e2 m* i9 I0 H
plant simulation中的free libraries有AGV模板,
! B- v7 k2 Q# @4 r里面也有案例。
8 x# B! e* [7 j+ v我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。) f( m! c0 T5 `, e+ L
1 i  G& A6 O, b( |4 Q# n. a; d- J
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
3 j) s9 b$ t8 q0 {# O. I/ g; j) ?7 ~2 j" d" {! Z2 P/ r5 w
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 8 Y2 w/ S) |; @# a: ?1 C) ^
这是AGV_putin中arrive的method。. F8 K. l3 C7 s" p
& {6 b  _% W7 b3 K
当到达物料速度越高时,这个报警更多,

7 Z  a' t, v2 M4 n8 q另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-7 05:53 , Processed in 0.017887 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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