设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5607|回复: 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'
7 x5 E7 j& F& ~3 }% y4 x$ x*/
: R% E& [' i: S( W1 J6 y; jis4 ]0 x% T; l7 U
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
) p& K; ]; o1 Z' g& c& K+ B, _do3 ]& O3 V' c% y- `  Q7 l- o+ D
        Lan := rootfolder.Internal.Tools.AOLlanguage;3 g. H. n4 }8 u$ P9 T# l* P9 M) j) \  m
        if current = @.Destination -- else return; w& T. J' F) ~1 `
        then
/ L) J# W7 B) k+ S  T                @.Destination := void;% F" ~3 N) c- a0 J% G1 V# k
                if @.occupied then+ i  P3 I- h! D( G
                        part := @.cont;* A0 x7 v: p# s
                        @.transpOrder := void;: d( k" m- X  n0 N
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
' d) [3 T# W+ o7 I! ^3 `                                @,root.eventcontroller.simTime);
8 U! T4 w% B" K* c1 N0 x6 [                        @.HasOrder := false;+ w0 M) h- ^( X' r7 ~
                        @.DrivingHome := true;
5 N* n$ g: ~! v2 I+ w                        rgManager.tryToStartTransOrder;! W; _+ ~8 S- c  i4 Y6 F, X. y' ]
                        if @.Destination = void: m7 o9 y! ]1 M1 A4 n8 e
                        then -- no transport order for vehicle @3 _- s8 K. e8 Q& ^# `8 Y
                                @.Destination :=* k- ]1 T1 l, \0 T- V9 G
                                rgManager.nearestFreeStation(@,track.~);
$ s2 T# a. |9 g  R! W8 C0 I                                newDirection(@);   
( w- k$ Q& K$ B: `: ^                                if @.Destination /= void then
; v% }0 c9 H. r                                        @.Destination.NumReservation :=% V' r% ~, C8 c* d& J
                                        @.Destination.NumReservation + 1;! L# w: ?- v& e+ M
                                end;" D+ }6 ^& Y6 h1 K5 B: U: P
                                @.CurrIcon := "drivingHome";
4 W6 m5 B4 p0 K" O                                @.DrivingHome := true;: r& Y5 I: ~) z) z' @7 K1 r) b7 b
                        end;/ }2 F; c2 T7 s: R' v/ a
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station- b9 ?3 Y, Z# A. J: s
                        part := @.transpOrder;
( y0 i* n8 ?& ~" b                        part.move(@);-- load part
; C# q! `+ n( \! s7 x' X8 ^# G                        @.CurrIcon := "load";
/ Z3 b; ^) e+ O+ i; L                        GlobalDistObj := part.globDestination;
9 \& }5 S/ q9 c4 {. _                        assignLObj := rgmanager.rgAssignL;. r. W5 }- d4 N( p; D. i
                        row := assignLObj.getRowNo(GlobalDistObj);
: i% d  u! Q# ~: l. S0 L( n$ z                        if Row = -1 then -- since 70. E% }, T, c7 y0 a) R% c9 `2 W
                                if lan=1 then
' c% H% T: _2 Q- k3 M7 Y                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),, T7 q! \" _) s0 W$ }- K9 J
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
) W2 W% `5 z# k+ C                                else* l% o" L% P) s+ S
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
3 ^: |5 A7 w$ U* M$ `8 q: H" O                                                to_str("in docking station: \"",?.~.name,"\""));                                5 ^( u6 R* c0 U
                                end;
' W5 {/ U3 q3 o4 l                        else
$ \) d7 d7 V* {1 ~7 M& m                                @.Destination := assignLObj[1,row];0 k7 D- Q$ {+ ^; u7 E0 F8 p
                        end;                       
+ Q6 Y- P- F9 \3 w# f                        newDirection(@);1 e. I3 G1 c$ T+ h5 n/ Q1 P
                        @.HasOrder := true;2 ?2 |& K/ o8 o+ }. ]
                end;
* Y# z! Y; k5 _  d; I: u        end;
& m, U* T3 \1 @4 w6 V+ |) I5 mend;        -- of the method
2 p# M- e7 z+ H0 U9 `* r
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
  @6 {" i9 K+ k% U& @9 |( }4 D2 \! d/ @/ n$ M5 Q" {+ f- `( A4 W
这是AGV_putin中arrive的method。; }3 i3 x& f2 ^8 d" X' `

# L! Q* }! @5 U& ]  h! s7 W5 w" Z' @当到达物料速度越高时,这个报警更多,& r6 z" C0 i: U0 J+ z
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。/ ?- _( ^5 H  _) k
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?) a- L0 ]7 K/ c. n
0 N' y/ G/ h  d9 s
另外一个小建议,就是move,所有的move都可以这样( X; {1 g7 ~" h; J" y& \7 g. E
if not move() then debug end( x! y# Z) l8 c' W; ^9 f
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。5 M' \: D# q: [: b7 I
plant simulation中的free libraries有AGV模板,
* u$ J  o1 e$ N里面也有案例。* Y1 P6 V6 I5 p6 T# w+ H9 i, q
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。0 ^8 n0 {  v# U/ o4 ]

. |8 x& b" B! v, D2 |6 m我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 8 h  V& S% U) ^7 j
1 U) E: R/ [" R$ N/ k& y, f( H% D
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 : N: x4 {9 W  Q. {! c7 Q
这是AGV_putin中arrive的method。' I- `7 H) D5 c2 K, t

' S, n7 p2 q& K& K6 Z4 a当到达物料速度越高时,这个报警更多,

- E( A2 u1 g7 ?4 V/ ~另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-12-8 15:16 , Processed in 0.024599 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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