设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10013|回复: 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'
; @5 h% t, J4 b' @' u8 e*/
. v0 t, ~0 w- ]is! W1 U" ?" F/ `3 g% [+ R5 r" F8 {
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;* l+ S# J! ]2 [+ m/ \0 T
do, b7 w" y4 E: L) U$ M# w  h
        Lan := rootfolder.Internal.Tools.AOLlanguage;
5 b3 C6 U6 g- v3 _. I& A) n7 ~/ i        if current = @.Destination -- else return
0 n* l% c+ i' f( \: g        then
8 _6 ^5 H, Z9 ?: f% Z                @.Destination := void;
) b+ k) x# x/ K                if @.occupied then  |. o, [6 B/ z$ |# B* `, d
                        part := @.cont;( H- [  B' r$ x* ^( \: U" Z/ y
                        @.transpOrder := void;. V+ P* ^6 G: {, y: H( ~
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,) ]$ X8 Y, g# Y8 V; I
                                @,root.eventcontroller.simTime);
0 Z$ b+ u# F; _- Y% E6 r. ?1 s                        @.HasOrder := false;
8 L/ [7 O7 @2 _; i                        @.DrivingHome := true;  X+ }# t; g/ p. w
                        rgManager.tryToStartTransOrder;
2 \) O  X1 ]/ N9 V9 \+ Y0 L                        if @.Destination = void7 k& |% L8 }6 S6 ^' n1 x. \
                        then -- no transport order for vehicle @
" S9 Y$ P* l: o( Q5 [4 x. w% R                                @.Destination :=# z4 Y# J9 [. M1 H
                                rgManager.nearestFreeStation(@,track.~);
, Y- Z6 g* ]! r( k                                newDirection(@);   
2 m* E/ ~6 Q9 D0 t+ r7 h: D: \- a* H                                if @.Destination /= void then. \3 S+ @& n" |# J
                                        @.Destination.NumReservation :=
* X% N4 {/ w) _" W$ E, O* s                                        @.Destination.NumReservation + 1;
4 L  h3 d" U4 b+ W+ p" Z                                end;
  x4 B0 j! I. {* Y4 V  K                                @.CurrIcon := "drivingHome";
6 @) O8 }8 T# L7 t9 I( i                                @.DrivingHome := true;
( A8 I0 l/ {9 {, p2 s! V* a! B                        end;
& a* P/ X0 N- E) d; M! R* o5 o2 \4 M% q                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
9 P3 r2 ^' j" \" l% R2 L! u8 E                        part := @.transpOrder;/ f6 q  t- j) X! p) x" j+ q
                        part.move(@);-- load part6 S; u! [7 l3 F
                        @.CurrIcon := "load";, M/ R( j; Q7 b! A3 g% E
                        GlobalDistObj := part.globDestination;
9 _  E( }8 }' s+ h/ \; h$ F$ ]1 `                        assignLObj := rgmanager.rgAssignL;
7 `- v5 m2 H1 ]                        row := assignLObj.getRowNo(GlobalDistObj);9 t( r& C: c( R0 T9 `
                        if Row = -1 then -- since 70$ o& N6 x! L3 i- V* Q9 \
                                if lan=1 then
1 t) u  P, j5 x  \# X+ X* d                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
- i4 Z) q: n4 D+ _: p2 p                                                to_str("in der Andockstation: \"",?.~.name,"\""));9 H, _0 z% h4 `
                                else
- [  f$ w; z; K                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),0 U2 i0 B% o; Q2 f
                                                to_str("in docking station: \"",?.~.name,"\""));                               
0 ~+ G6 ~( r  ~/ n! E7 c" V* g                                end;  S7 s/ z- `5 [9 n# @# }
                        else
1 e/ U; e2 V4 ]7 o; D8 U                                @.Destination := assignLObj[1,row];; T+ N# D3 o- @
                        end;                       
* \, V5 {+ D+ ^- F' w8 t                        newDirection(@);
* G, D4 b+ x- f' H                        @.HasOrder := true;
7 Z( X2 _6 v/ b! ?( G                end;/ `! y; G7 V2 s
        end;* U# U! d' {+ t
end;        -- of the method$ I$ }" H% e9 b! a- v
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
; D; A( k* n5 t0 D) _+ `) N. u: N$ m7 b+ m7 k5 R+ Z9 D/ E$ O1 M
这是AGV_putin中arrive的method。3 }8 |5 z. l! l$ Q7 u. S) [; x% k& m# P3 z

+ b; O. j+ n5 @6 V( j! x8 H当到达物料速度越高时,这个报警更多,5 J" C' p- K/ l0 j# j7 v
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
3 g( D  J9 G# l2 D9 E程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
5 d0 J+ T, ]4 o4 q+ K7 g4 D+ \3 v3 W# c3 P% _
另外一个小建议,就是move,所有的move都可以这样4 ^: n: e5 B. q9 G
if not move() then debug end
- C/ M$ |* S% g- Y$ l% W- d这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。  K0 _3 g  T3 c4 ]0 w( r% l
plant simulation中的free libraries有AGV模板,
" ?" q8 y. g9 c) ]2 ^里面也有案例。' @1 t7 u6 [; c7 H# Y% J* @2 C) c* ~
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
. H: }4 z/ a  u. V- }8 d/ w6 a- D1 `
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
8 S* e6 m- |* Q1 Q9 H. Z
. U; G, T- X% s9 B# ^, L% \那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 . U4 P7 p0 A: V- D' ]) H
这是AGV_putin中arrive的method。
8 ^2 S9 e* D+ s" M1 Z. m# {( ~( h& u. x- U# j, L7 H1 b
当到达物料速度越高时,这个报警更多,
- V! ]. k2 a' e4 X2 J, H
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-7 12:10 , Processed in 0.022122 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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