设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8904|回复: 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'' Q5 i; y' k$ p5 m: P" x
*/' x; R( m( }1 I+ D
is
  d2 p2 G, {# f        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
# U) L& \7 x5 \' ?. V0 Ido" O4 C/ V$ S$ B6 d
        Lan := rootfolder.Internal.Tools.AOLlanguage;
5 S4 @5 I8 ^2 R7 c4 D        if current = @.Destination -- else return: `4 x' @, z' J1 R  f
        then5 {( r" @/ K: C' p
                @.Destination := void;+ L7 w* W/ V' W- ]! S( Z  U! m. V) \
                if @.occupied then2 p$ N5 b8 T6 L' L$ ]
                        part := @.cont;: M1 P3 O; a0 D- O
                        @.transpOrder := void;7 h, ]" ?3 o! H" L! R% M
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,5 p# X5 N2 [0 v  Y# {. a
                                @,root.eventcontroller.simTime);
3 c8 y" a% f9 T0 j                        @.HasOrder := false;0 s0 X  Q# V3 Z7 B, l% Q; R: P
                        @.DrivingHome := true;0 f9 u5 j+ q  g  ^  X) Y7 e
                        rgManager.tryToStartTransOrder;
; `: D4 m' a/ s( P) {                        if @.Destination = void- T7 ?' U6 j1 }# g6 f9 g8 j, G
                        then -- no transport order for vehicle @' R7 l0 P4 `5 V) B5 h, g0 n5 G
                                @.Destination :=& c  a1 Y5 {8 X& B
                                rgManager.nearestFreeStation(@,track.~);
% T0 l3 L6 }" a- U2 G" D                                newDirection(@);   ' H7 [4 L4 |' Q3 A( l# F
                                if @.Destination /= void then
$ n7 E7 Z+ l  h3 O8 [$ e                                        @.Destination.NumReservation :=
" J& l' h  U  j/ ?* b4 O                                        @.Destination.NumReservation + 1;
& Y" ^& u/ P+ }; m  a8 T                                end;
' H6 Y  i; z# V. i& B: x                                @.CurrIcon := "drivingHome";. A4 M' e! d2 a8 U: \$ p
                                @.DrivingHome := true;- a9 u/ s6 ~9 T! S0 x
                        end;
- o, s. m$ B* w) }                else -- the vehicle @ is empty, both vehicle and part are in the same dock station% Y* G3 p7 p2 {  h" J) }0 J6 `
                        part := @.transpOrder;
& N+ B& k6 W& m: \+ g! a. L7 }                        part.move(@);-- load part
- k# p7 k6 `( |8 n5 C                        @.CurrIcon := "load";# c$ R- Y% R! x3 H7 N( f3 ]5 m9 y) f
                        GlobalDistObj := part.globDestination;
7 s7 q5 ]1 |' P+ c; a9 B' Q3 i2 C8 P                        assignLObj := rgmanager.rgAssignL;& O2 d( C0 i( Q, e9 j6 H, d
                        row := assignLObj.getRowNo(GlobalDistObj);+ S- K: V, T$ e7 R- F8 V  {
                        if Row = -1 then -- since 701 V! v! T! y; Z! X/ E9 g0 n5 e
                                if lan=1 then. J1 ~$ E6 ^0 q" E
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
7 f5 ~1 b( c" n3 Y                                                to_str("in der Andockstation: \"",?.~.name,"\""));- u/ R5 F  @* o( T  I8 t2 t
                                else- x8 Y- g; l/ a0 U% D
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),5 h/ |; H2 m( y8 `- l- ^
                                                to_str("in docking station: \"",?.~.name,"\""));                               
$ U) W0 R: m" x, Q# _9 A' }6 a) l                                end;0 T" y; j+ Z) Z9 K9 X+ g
                        else, Z1 t. }3 U! u9 J& `$ z8 g
                                @.Destination := assignLObj[1,row];, b6 R& I  \, M5 N0 f. T
                        end;                       
3 P7 I0 {- o1 j7 X5 H                        newDirection(@);+ ]4 r+ Q" `9 `' C
                        @.HasOrder := true;
9 |) F! Y5 a' |9 C3 D" n* d                end;5 p! Q* ~6 p* H3 ^  }* X' t+ i
        end;7 C4 g  v: t# F
end;        -- of the method! p1 _8 l% k* s
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
) B1 H" \8 ?+ h( A7 H
& T) v4 w7 J# L( P4 }这是AGV_putin中arrive的method。  U) J8 s! g* x" I

+ ?3 s% E+ I- }2 u& e: g4 Y当到达物料速度越高时,这个报警更多,
4 T+ _! {# p0 P2 }/ d. T* k6 Z$ p' b可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。7 P. c/ O7 k8 ]; a
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
  ?2 k; L) t" r; O, z3 Q+ z  a' T' w( Q& M# m# f+ i# |) O
另外一个小建议,就是move,所有的move都可以这样
0 t% q+ ^- t+ Iif not move() then debug end- a; S: K- f4 J+ }; V+ s
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。; R8 y+ ?( R) S; w# K; X" {4 t, Z5 C
plant simulation中的free libraries有AGV模板,
6 f4 Q& b; c; ?8 {8 u  g6 O; J+ N里面也有案例。
/ c' b8 l' H+ x  [我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
% D$ S6 u. O7 `  y+ }2 e1 a3 g
) ^7 {: }8 o. z8 W3 j我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ) g' {( p! Q, S7 G% [/ C
$ R) T: q; Y/ y- H
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
2 ^  e1 d& N9 U; A, Z5 l这是AGV_putin中arrive的method。/ U2 B! }/ d! j% w2 p

0 n8 \7 _: A" f6 c当到达物料速度越高时,这个报警更多,
4 P6 F! ?4 \5 d- p9 `8 {: d6 r
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-3 15:09 , Processed in 0.019585 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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