设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7767|回复: 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'
  r9 h/ }2 ~4 A# J6 q! ^$ i*/
2 M/ d: n& N% ^" eis
$ u9 L& r" q) E        part, GlobalDistObj, assignLObj:object;row,Lan:integer;/ S( A2 e3 n, Y& g9 D% U
do+ [$ h" y* m7 C5 }" t+ j
        Lan := rootfolder.Internal.Tools.AOLlanguage;) v/ w3 v  h1 k7 v  W' S/ G- W* Z6 E
        if current = @.Destination -- else return% J: N7 [9 z  C+ T
        then7 T6 I1 {" d- m* k; P
                @.Destination := void;
, `4 T3 @) `' \. R% I( r                if @.occupied then
; a1 {5 @) r5 l, s7 p# ?                        part := @.cont;
- ~+ [& Q) m5 X                        @.transpOrder := void;2 Z4 @& r* L+ U& t
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,: _& I3 y! `5 D' @: ]* m& H1 |# W
                                @,root.eventcontroller.simTime);: j  ~3 U* w+ m9 g( [
                        @.HasOrder := false;
9 o1 |( c8 U6 K! c! z4 n( K& y                        @.DrivingHome := true;  p8 E- R: J/ \4 }" w' ]$ r9 w
                        rgManager.tryToStartTransOrder;
" P! b4 p  G# a1 B, l) R                        if @.Destination = void0 m% d' z. k; B9 C/ X' V/ R
                        then -- no transport order for vehicle @
' G! ?) O1 x5 U# O9 X5 p7 u                                @.Destination :=
4 c. ]6 G( g% J# V                                rgManager.nearestFreeStation(@,track.~);
0 u9 H- {/ h* u6 H. Q  H                                newDirection(@);   
+ G& r0 d9 ]- l$ x                                if @.Destination /= void then
. n7 n2 V# a7 V$ B                                        @.Destination.NumReservation :=  O; o2 U! X$ I  _* r, B. y7 |
                                        @.Destination.NumReservation + 1;
6 U3 w& e5 j! S+ C7 [                                end;
2 c" l8 K" N# A                                @.CurrIcon := "drivingHome";
4 ]  P* Z, f5 v- z3 e! d                                @.DrivingHome := true;. x- U, M* S* I3 p1 j
                        end;
2 \3 w, |0 {! `9 H                else -- the vehicle @ is empty, both vehicle and part are in the same dock station, y4 a4 `+ X4 X  {" Q" @& w- F
                        part := @.transpOrder;
7 x$ v5 W; v6 z. M6 t0 p  m                        part.move(@);-- load part
8 r5 s  w3 s- ?6 B6 O9 `                        @.CurrIcon := "load";
+ O3 s1 h- u; N% L& l. q                        GlobalDistObj := part.globDestination;
+ V: y/ H! X) p% n; c                        assignLObj := rgmanager.rgAssignL;4 S, a4 }/ s+ u7 a! S: K  E. D7 B
                        row := assignLObj.getRowNo(GlobalDistObj);. V% J3 W- _& O% u. N' G
                        if Row = -1 then -- since 70
3 z2 X0 E+ c/ {9 d; S; u# g' Z                                if lan=1 then
' h* G* v* S0 [6 G                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),5 ?1 L) F) J/ [/ `3 I
                                                to_str("in der Andockstation: \"",?.~.name,"\""));4 C' W3 p" }8 }3 q
                                else2 x  ~1 n) W0 @9 q  Y! B
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
' y0 S+ A0 \; J4 a                                                to_str("in docking station: \"",?.~.name,"\""));                               
0 I0 J6 b1 j6 M( w5 P! F. }) I                                end;
$ D8 ]1 c% W( r# j2 E: B  |                        else2 f  _3 L5 g  X8 x+ a9 q& g% j
                                @.Destination := assignLObj[1,row];
3 v9 O4 K0 E8 Z- ?                        end;                        . ^" Q" }9 A' }6 Y! Z9 l& d
                        newDirection(@);6 Z$ w. V# e0 ]  s
                        @.HasOrder := true;) r+ v; e. u9 i
                end;# [1 j/ S- z! |6 d0 Y! J% _
        end;
3 d0 }& g4 f$ U5 h" _; Jend;        -- of the method
$ \4 u9 g; }. v9 c2 I+ f, i' m5 ?3 g
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
. [- y$ B- d& p3 Y& S! }: w6 ~6 R! J- N/ b/ j- [! @8 C& j5 q6 x
这是AGV_putin中arrive的method。4 t. a. q0 g1 x# o9 K
1 w% W* }3 _" h' X0 N
当到达物料速度越高时,这个报警更多,
3 i$ V, e1 l4 T% t$ d可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。$ z4 b7 J8 _! `
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?5 ~) E0 L2 @7 f- e( C. C# a. P# M

. t1 u- |8 ^5 @8 B/ v3 P  F另外一个小建议,就是move,所有的move都可以这样! x1 C5 S) ?' N6 h$ a
if not move() then debug end
; Y; e# W' c  ?" p( c这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。4 X1 ^; t. n; }: N+ O4 V5 r
plant simulation中的free libraries有AGV模板,
( \& s8 l+ R1 ?+ A6 x* Q2 v$ y里面也有案例。
3 x9 W& v+ j' [5 m我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
( [% V+ P0 }. H+ Q6 E5 i# G  Z% f& D2 y% i- l, Q" m
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
& N; a- I# F3 C/ D+ m5 a% q, _- }7 j5 a
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 3 j! I) L; S/ q) i6 ?
这是AGV_putin中arrive的method。
  h" x3 s6 Y! v6 S# q, p
4 D0 ~+ T2 {: X当到达物料速度越高时,这个报警更多,
# g1 f3 ]: j( K
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-28 16:40 , Processed in 0.061919 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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