设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7024|回复: 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 @) @4 N8 I( K& c5 Q*/2 }! H; B) `- F; T; N% L
is. u. Y8 m; ?: A- x
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
( R% r- K( f5 _2 P0 Sdo
- n" P9 |( K" f8 O        Lan := rootfolder.Internal.Tools.AOLlanguage;
' ^5 w) B; p( \+ F        if current = @.Destination -- else return+ S/ K- w% `0 ~& [3 T
        then6 h( m' e( h4 @
                @.Destination := void;/ P, k8 q7 V  {! n5 F: O) w
                if @.occupied then
8 B3 l- \# }( K: L: Y& d+ O/ ?" E                        part := @.cont;7 }7 L; S  I  w5 V% |) l3 Z2 @
                        @.transpOrder := void;
2 D$ F+ h; V; v3 d( _                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
4 I2 W5 \2 y, o9 s                                @,root.eventcontroller.simTime);$ d' v, m0 K' e# k' ?4 j3 l
                        @.HasOrder := false;
* }; A3 M5 M1 D+ N; J% T                        @.DrivingHome := true;
' }% C, r, ?1 j/ y( u                        rgManager.tryToStartTransOrder;
1 [7 V7 x- c& U0 M- I# A) ^                        if @.Destination = void
" B( }9 d0 g1 Q( V5 L0 W3 T                        then -- no transport order for vehicle @
4 ?) ~4 [" v5 l+ L                                @.Destination :=8 ?+ h2 R. e3 h' b+ P/ ^. H
                                rgManager.nearestFreeStation(@,track.~);! X( F8 e$ I4 ~0 H
                                newDirection(@);   
7 @1 u: W( e3 F$ L( M$ s                                if @.Destination /= void then% u* s+ z  j6 a7 W
                                        @.Destination.NumReservation :=! v& r+ G1 N* F4 S( L+ D
                                        @.Destination.NumReservation + 1;
2 c9 E- F2 S, U7 \- y/ x" |/ j! p( w                                end;. R0 I" J) m. v* Z; {) v  d
                                @.CurrIcon := "drivingHome";
" o( g. Y7 Q$ @3 N* R! [                                @.DrivingHome := true;# S1 c0 g: g' w
                        end;
  d3 l: x+ F" \( Y: J: `. O                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
& [2 \/ C7 |0 e# I# P/ ~                        part := @.transpOrder;
& e6 u3 \, p- ^8 E8 L                        part.move(@);-- load part! Q7 x2 p$ ]$ n7 ?$ L% Y3 C
                        @.CurrIcon := "load";4 p) u0 [0 ^1 g7 ?5 R7 _
                        GlobalDistObj := part.globDestination;. P2 G: a+ ~8 a9 j9 g
                        assignLObj := rgmanager.rgAssignL;2 x2 L4 ?4 h& @/ [
                        row := assignLObj.getRowNo(GlobalDistObj);% g' F0 A8 _2 ?# g, D
                        if Row = -1 then -- since 70; ?8 B  m& c; W0 d) `
                                if lan=1 then1 [% H4 N% K* u5 \  {! l8 c+ x- }  [1 X
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
' ^; _) f0 z% B0 q3 l8 _- m$ n/ n                                                to_str("in der Andockstation: \"",?.~.name,"\""));
/ T1 `& C) {* Z$ G7 K                                else& X0 |) e/ I9 F( p; {, _
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
0 e. n. g, ^6 L' ^+ E1 D, K$ O                                                to_str("in docking station: \"",?.~.name,"\""));                                % w$ k; D/ }. T2 ~/ _2 x* n" W) a- b
                                end;
9 B7 R4 y0 \. J: q5 U                        else
* i3 a- O2 F5 l* d- Z4 C! L                                @.Destination := assignLObj[1,row];: A; s( x" a/ b$ s: j) r
                        end;                        ) N8 F- r2 t) G( [$ J0 W
                        newDirection(@);
/ l1 f6 T, _: W. u& x                        @.HasOrder := true;
  Y* B1 \, E- H  d- d                end;
# i2 M0 H0 E: m5 X. l/ |# j        end;$ Z& z" Y$ x7 h" G  z+ k$ d
end;        -- of the method( p: n7 s, R- U# L' `, ~( [
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 9 z- m( J: c% U
) ]7 |2 l' u! e- o2 L3 L+ K' A
这是AGV_putin中arrive的method。
2 j' P# H8 u$ V6 B+ g$ _. g, ^6 F& c$ M5 S1 \4 c  R
当到达物料速度越高时,这个报警更多,0 d1 I9 K3 Z5 n# }$ f' c. R% F
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
, D- M+ g' E9 \程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
) j4 `' Y( C5 @# j
5 S3 Z/ E3 K/ c6 n6 o2 v2 U# J另外一个小建议,就是move,所有的move都可以这样
: b2 h* L' d$ H7 `9 o+ J! Tif not move() then debug end
6 Q1 v0 U3 \' F& ?2 L7 z0 x  f这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。; H5 @8 b2 h. }2 U( X+ G  E2 t
plant simulation中的free libraries有AGV模板,% d0 F1 t1 i3 z7 S! A. ^
里面也有案例。; R2 x+ K  [/ D. `
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。7 P! @4 j) T- a% @, M
9 a; t, i, b6 e
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
0 g% V8 Q  \, n' D% l( ~% d/ R" h( F) N( J3 V/ C7 I
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
; Y; ~* X( b& k, \3 n这是AGV_putin中arrive的method。* F& N; _  c0 V! h1 Z

& x% O1 V3 l- k( [当到达物料速度越高时,这个报警更多,
0 \. I8 d* t7 v- g- |+ X
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-11 23:40 , Processed in 0.020211 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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