设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6553|回复: 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'$ Z' ?- h% u. [) Q* o
*/
9 l# w1 k' n% W$ Q6 tis) W/ I8 x, w, b% }) n* d& O
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;! T/ m! `$ \. C; a2 y$ }$ M
do& M; t5 \0 }3 y7 G
        Lan := rootfolder.Internal.Tools.AOLlanguage;' @" X+ I, d1 p! I
        if current = @.Destination -- else return
+ l; S" W8 E4 b% K3 a- j        then
! Y% u/ P' \7 c5 J5 K                @.Destination := void;; Z, }+ c' W9 i  g0 N) t& I+ q3 g. r
                if @.occupied then
5 w. o: R( b8 N$ `8 X7 n                        part := @.cont;
, t" U/ q: |1 k0 N8 Y/ {2 h                        @.transpOrder := void;1 p3 O- J* w  b0 i
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
' f/ b! E2 a7 S0 Q                                @,root.eventcontroller.simTime);) \9 f$ b2 E. Z, A
                        @.HasOrder := false;2 O; H5 v7 b* U% v+ o; H3 l
                        @.DrivingHome := true;: H1 P. A7 ~0 W
                        rgManager.tryToStartTransOrder;
* `7 c8 g/ u/ h4 z5 @. p                        if @.Destination = void6 \- T! w/ Z! X& n$ C
                        then -- no transport order for vehicle @5 S! k2 h* O- P( p
                                @.Destination :=% f" ]5 _; t0 S9 \7 \2 m# F
                                rgManager.nearestFreeStation(@,track.~);$ P, |$ W/ b, {+ K& @# o
                                newDirection(@);   
9 T* j% I: e( }1 R  l! R                                if @.Destination /= void then2 `3 ?( G& |' ?4 q  N6 e: g: r4 c
                                        @.Destination.NumReservation :=
- U4 y: i  s/ u3 x3 B7 ?                                        @.Destination.NumReservation + 1;' D9 Q" N& ]) ^
                                end;8 U6 ?2 V6 ?9 X9 K+ H) w
                                @.CurrIcon := "drivingHome";3 n. @2 F; w2 I! }: Y% r
                                @.DrivingHome := true;
: V- \# }7 f. d2 R! A( F! k                        end;" r& ~2 O0 \7 u1 i1 T
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
4 r, [$ A3 n; q                        part := @.transpOrder;
3 m& O1 W( U& w                        part.move(@);-- load part/ b1 b* K9 S& \6 h2 V, p6 F& y8 I
                        @.CurrIcon := "load";
# T0 D/ C" m# S; g( p                        GlobalDistObj := part.globDestination;
2 n* @+ U3 D% s                        assignLObj := rgmanager.rgAssignL;
8 a; ^1 ~4 U! c0 Q9 \                        row := assignLObj.getRowNo(GlobalDistObj);6 ~0 q$ Q. p; Q7 ]3 I5 {' L
                        if Row = -1 then -- since 70
6 C8 s$ n( W/ Y' e$ K% s- M% W                                if lan=1 then
' r, o8 {$ [; j/ P                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
# X9 X! a* N; G4 j* V; Y                                                to_str("in der Andockstation: \"",?.~.name,"\""));- Y" m& H  _# w3 b$ J
                                else
4 f1 S) b: ^+ M" p# H' i                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
: h; f: o3 b  C+ w( s                                                to_str("in docking station: \"",?.~.name,"\""));                               
2 X) S/ a  Q' J$ j# s) \! T                                end;! W. h8 t, |, m0 b
                        else
3 }4 r$ g: I7 F# d0 Y) Y- W                                @.Destination := assignLObj[1,row];( _  X% d7 B: A) P- e, |
                        end;                        & G8 A9 d- Z6 _# T7 z
                        newDirection(@);2 P3 R4 Y6 @" E$ S8 V
                        @.HasOrder := true;- R/ n( p0 G& L. I: |. I6 o+ u  P
                end;+ B1 s. d! V4 B8 ~2 L
        end;" l: ~7 A; a- v/ w
end;        -- of the method% `4 r/ x, k! _) N
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
+ p+ i& [* z4 s/ f  ~4 i4 f  o7 {% k" C. ]
这是AGV_putin中arrive的method。. H' o7 e0 \6 F! R% s) J3 J5 `% k

" c% \: M1 \. j- S- B& U  z" f, ~5 C当到达物料速度越高时,这个报警更多,1 a$ p& N% T- _) b. z$ w8 i8 X+ C
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。; Y4 a1 i2 U. a6 S  Q% b7 }
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?# w2 v+ C3 p0 L- A4 ]
1 _7 C3 W& g7 m/ s- @& e5 N
另外一个小建议,就是move,所有的move都可以这样
) c  X- p+ n  S( x& X1 P; f2 Vif not move() then debug end
3 ]2 F! V! S: E( p( T" n) X! b这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
& j0 [% e7 d; `4 X- |plant simulation中的free libraries有AGV模板,5 N  [  j( t1 I) Y- [
里面也有案例。
% \, @* X* _$ ~  [7 C我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
3 Y6 A$ r" N$ |2 }
- D0 v. H( O2 q- D! I: ~( [- f我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 # C6 r; ]7 @# d+ ]% x
+ J' j* Y# V2 _8 V! f& l
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
) W: B& T' i8 J这是AGV_putin中arrive的method。
- \0 }: X+ M6 X' W' W" b# F9 {% [
当到达物料速度越高时,这个报警更多,

; v! ~! w( a6 M* Y& V* r  @另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-12 13:44 , Processed in 0.018876 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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