设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5897|回复: 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'3 V& ~; M3 z. r; s2 J
*/: l  o) r2 U% p( }! ?8 |. O: J
is3 ?$ D) m( w$ U% \' @
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
" n" @/ a, a7 F2 Z* Wdo
  g. I( E0 i9 t        Lan := rootfolder.Internal.Tools.AOLlanguage;
8 ]9 B. H9 i& S9 c2 Y& e3 f; }1 z        if current = @.Destination -- else return$ f+ b* R( ^2 [6 p; w* h( v- D) V
        then- @& m+ f3 g0 [9 S
                @.Destination := void;
* G! T8 t; `1 Y! A6 t( |# O                if @.occupied then# J! B3 T: S/ T# ]" [  n
                        part := @.cont;
4 c- w% [, ^1 U6 U                        @.transpOrder := void;
. e5 ~8 p/ [) h: _                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,$ v6 ]4 d- Q2 R0 [0 R
                                @,root.eventcontroller.simTime);
5 b# C* [5 ?; A% e                        @.HasOrder := false;
2 c( l1 X/ c1 l# y# C5 }                        @.DrivingHome := true;1 j& U/ S7 c8 Y! Z9 H
                        rgManager.tryToStartTransOrder;! U+ h+ ^" m1 L& H" s* R8 h* X
                        if @.Destination = void, V6 K  I. v6 `" x
                        then -- no transport order for vehicle @- E" f8 `) u7 W2 `2 Z3 O
                                @.Destination :=
1 E& O2 J+ d: i& g' r: d                                rgManager.nearestFreeStation(@,track.~);+ u9 Q4 p7 K4 L; W
                                newDirection(@);   7 c" Q' R/ @' ?
                                if @.Destination /= void then& m- w& o0 T: H1 @! c8 G" K
                                        @.Destination.NumReservation :=
" i, u$ K' w- W& ~2 f# n                                        @.Destination.NumReservation + 1;
" e3 B. r6 O$ j- ~( ^7 F% A# R                                end;
7 P$ i+ u" E) F# j# |                                @.CurrIcon := "drivingHome";
9 D9 e9 l  q1 A. _! g; f2 W$ S                                @.DrivingHome := true;/ u( U7 E* a0 S/ C. Y0 n
                        end;9 L& ~% n, W/ F
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station  A2 ~* q* d5 T: W
                        part := @.transpOrder;' M! D6 g' d' H9 f) ^
                        part.move(@);-- load part
; [% A( X4 S2 I% l3 C$ N                        @.CurrIcon := "load";: H1 A# G# t4 C1 u! ^3 n
                        GlobalDistObj := part.globDestination;
$ X/ F2 p( A9 c( Z; n% d  g0 O                        assignLObj := rgmanager.rgAssignL;
& K+ F- z: U, t* _0 G- m5 ^                        row := assignLObj.getRowNo(GlobalDistObj);6 j' g$ U3 G0 u( q+ ?# A; s
                        if Row = -1 then -- since 702 T( F  D) j, `$ l0 }3 L
                                if lan=1 then, A; @' p0 i9 o, I3 C
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),. W- D3 ~6 m+ G# h7 _& A
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
: ~, g0 H( K/ P, O  t2 r                                else
* }$ ~0 s! P" G4 F( i                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
7 q, p$ u5 r# l: ?: F/ q                                                to_str("in docking station: \"",?.~.name,"\""));                               
! J7 @' O# n/ k3 A5 [7 f7 T: M                                end;( S' U* W! `0 z! r8 I
                        else! W! O/ t2 H1 d6 {( Y% J! Y
                                @.Destination := assignLObj[1,row];1 N! o  y' W- b
                        end;                        + I% J" h; P4 G* j8 }* F) [( j( k& b" x
                        newDirection(@);
8 r) p2 r+ M8 C% R, Q                        @.HasOrder := true;
7 q* R/ O: V' e  J& c; u- B                end;
: o% t, F# K& l& F# `) y6 ~4 Y" S; ^        end;! M! L( q0 ~: P6 i) [' o- Q
end;        -- of the method0 H: n! T- ]# o" w$ G- e! w$ H
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
  g  R) l; T. a/ \+ G2 Q4 A7 l- f5 R9 p9 R. `! q7 W' h. F7 [5 U
这是AGV_putin中arrive的method。
: E$ ^; J& S. |0 ]! l& {( g, j* h# W
9 H) s. B  g" L. P& v当到达物料速度越高时,这个报警更多,: h. f7 S$ U& t, D% Y! u
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。, S9 r1 E" u3 I! E- m4 O( k
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
" Y6 i* T1 V) B: r; P0 `2 L4 }2 G; z/ V8 m6 H1 E
另外一个小建议,就是move,所有的move都可以这样
3 v$ P: b: p1 N2 y  h/ c" uif not move() then debug end
" o7 V3 }! `% c% V" n* L这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。: S0 t+ H! B  H/ `" X9 P
plant simulation中的free libraries有AGV模板,' h9 n3 t" a0 m. R8 K: U6 S9 @
里面也有案例。
7 t0 S0 |2 l2 U+ }. u我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。% B: x4 {" g# Z& o
' t4 i3 P9 O- M/ L" {# Z& T5 J
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
+ E. G* ], C- R7 I
. m+ L, L! }) \# }# E6 G/ v: J那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 5 M3 z" q* a  u0 t
这是AGV_putin中arrive的method。: q0 H2 U, x- b, c$ k
, K" f  _3 `9 v: {" v3 h. F/ u
当到达物料速度越高时,这个报警更多,

$ u/ s- ]; x& u# n% ]另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-12-30 21:10 , Processed in 0.016406 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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