设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6075|回复: 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'
! K+ t; w$ P1 h! k: N7 Y*/
3 v1 T. Z8 x7 J5 L: m: ~9 V3 Uis5 E- L. u5 F  G/ k# M" Q
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
( L. B7 k" U9 H7 ]  Xdo
0 K$ x+ Q; }  o8 f: `8 h        Lan := rootfolder.Internal.Tools.AOLlanguage;7 q5 ?$ q' H1 x. e% q/ [
        if current = @.Destination -- else return% L0 h  s, L$ o1 H- y
        then$ [" \4 d& X4 Z7 @' w
                @.Destination := void;
, I; i" K" {" b, ~                if @.occupied then
+ i% I% E  ?9 Z. E9 M$ a  W- h- H8 ]                        part := @.cont;
  e; k: j6 O9 G" H3 e* r                        @.transpOrder := void;9 t( x; ^; x) W/ P
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
( M; I$ W6 \1 |4 P  a* Q                                @,root.eventcontroller.simTime);* X3 h1 r7 S8 t3 ^  ~( y
                        @.HasOrder := false;
  k1 [1 e+ {' L- j5 F7 F  H                        @.DrivingHome := true;* I6 r8 K* _0 o* K& F% m
                        rgManager.tryToStartTransOrder;
! ?. C7 ^: ?* ~  j                        if @.Destination = void
- P  d4 \# S4 z: N+ Q                        then -- no transport order for vehicle @2 J+ b& |# }5 Z
                                @.Destination :=& C& Q5 V, t( k
                                rgManager.nearestFreeStation(@,track.~);
6 |7 e. z; ?3 A. o5 Z% C$ z/ Q1 O                                newDirection(@);   
- l- h$ l; o# m                                if @.Destination /= void then
, [1 r1 \. |$ X3 R' t$ c+ A' f                                        @.Destination.NumReservation :=
; w5 A( L  O4 ]# `3 O, m                                        @.Destination.NumReservation + 1;% {6 p% N) {3 c5 }# G
                                end;
" ?/ B7 ?9 s+ r$ N( z) O                                @.CurrIcon := "drivingHome";
/ e3 r. X1 {. v                                @.DrivingHome := true;
" C, e, {/ G( E2 @9 N                        end;
% {  H$ O& u: d: b                else -- the vehicle @ is empty, both vehicle and part are in the same dock station3 i9 Z/ s$ D- R1 [9 E% d" G; `
                        part := @.transpOrder;
5 f* N! t, U  y- W6 a; r' }                        part.move(@);-- load part$ E, y! o! P0 W- Y" @8 ]4 I3 H* Z
                        @.CurrIcon := "load";
6 R7 d2 ?4 _% a0 w3 N                        GlobalDistObj := part.globDestination;2 N! I# N+ j9 ~- u; T/ R1 J# i
                        assignLObj := rgmanager.rgAssignL;6 a/ B- V2 o9 h  _- W0 {# l" l
                        row := assignLObj.getRowNo(GlobalDistObj);
) I/ V% i5 S; \                        if Row = -1 then -- since 70
0 `+ C; G3 j6 V" S9 F* y, i                                if lan=1 then
& [( j' t# J0 p' B7 g+ m                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),! T& V: c$ _1 r0 r
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
! T+ L% ~* [+ s: @) O8 E* q                                else
& k9 t% I+ M, m% k# ]+ W                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),- h" {9 f8 V' i  b! \; r; y
                                                to_str("in docking station: \"",?.~.name,"\""));                                - Q+ `" _$ A# B0 ]; ?! B' ^4 |
                                end;8 T, G# v& K9 U: e  {/ r, O4 W" r" {
                        else- i  s: z7 ~5 p& ]0 P1 e5 x
                                @.Destination := assignLObj[1,row];
/ d) a. h1 P+ h" ]                        end;                       
- k0 x# T: m; R: [0 U                        newDirection(@);
+ E8 r! v. }3 K                        @.HasOrder := true;
. x9 g1 }( |3 i5 X) ?" V                end;
, q& K& ?- M& Q7 \& I6 }) W        end;0 t& B: x4 k5 e% P. g. w# |7 A. |
end;        -- of the method" c: N$ y5 J' C8 R
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 2 j4 N+ k! r7 X# O4 I8 S$ j1 O
2 b. F* s7 I5 e" M
这是AGV_putin中arrive的method。
$ ~7 k- x3 @" K2 g* k1 A! s1 z# T( @5 ?$ j
当到达物料速度越高时,这个报警更多,9 F' p& w; d1 a6 |* j  c
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
; A! G8 x2 s7 ^+ F5 Y程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
4 N# ^: P, _+ ?1 c, S1 S$ m  [
; l5 x+ S6 d8 z# j8 z2 @另外一个小建议,就是move,所有的move都可以这样
5 s, Q( w1 G1 mif not move() then debug end
, y- C# ^  `8 y; K' L3 ~这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。' x/ B+ \. b# y7 _3 {' {
plant simulation中的free libraries有AGV模板,. e0 ^1 |. M1 L' z! Z
里面也有案例。
  k5 H6 c5 C! @+ ?我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
- k+ d6 V8 F1 F: w' V! j# q+ w+ Z' |; }! r
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
7 P* f3 E# a0 j  R, ~6 m$ K& G/ H- _0 @; Z
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 + a' R+ ~$ S; X0 V( W
这是AGV_putin中arrive的method。
8 t6 k3 r* O( v) q9 B! q; `5 Q, s$ E" V: D
当到达物料速度越高时,这个报警更多,

  G* g% }0 f, l" h' I% d8 o另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-16 12:28 , Processed in 0.021481 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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