设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5870|回复: 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'
! p% K& Z! j2 j5 d*/
- F& I/ P$ O  A! Eis9 R, |4 [2 _" F/ |# M8 A
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
. _* A- H0 V& _" h2 Ddo
, A/ O+ F7 V$ x" @# E; \        Lan := rootfolder.Internal.Tools.AOLlanguage;6 B1 M$ `7 Y4 K# m8 v5 X( a* u
        if current = @.Destination -- else return
! e1 P+ ~0 T6 a        then
- h$ G- X) w+ j; g  O                @.Destination := void;* s- {- l9 F5 D: K# {* B
                if @.occupied then
+ j8 J+ w# `7 r' J0 x/ I                        part := @.cont;3 z; D; {  M: T, ^6 g6 ^8 K
                        @.transpOrder := void;
% N- B6 p4 y8 C# z                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
' N  P* ]' T4 t$ R( R                                @,root.eventcontroller.simTime);; g+ W8 P3 n- {. `4 ~* {8 E
                        @.HasOrder := false;# G; h0 ]* g7 _4 x/ ~& L
                        @.DrivingHome := true;; t3 t+ {- k& B: z$ V/ i0 d& }
                        rgManager.tryToStartTransOrder;
" q4 X7 N/ u* _7 D, J0 j                        if @.Destination = void
; p  I- g! [% ~' }( R- e5 a' L                        then -- no transport order for vehicle @+ y* U, `- t& r& c6 U$ N  [7 ?
                                @.Destination :=0 z" n! |/ e% n7 [& D9 N
                                rgManager.nearestFreeStation(@,track.~);
) {  f8 E6 G$ d4 L4 C                                newDirection(@);   % z% T$ A' z# a% d7 _+ t
                                if @.Destination /= void then
2 g; {& C# @( V  W  E: g$ |                                        @.Destination.NumReservation :=
' Z2 j# ~; O% o, }( o) Z  Q6 i                                        @.Destination.NumReservation + 1;
* s, H" R: }0 J6 X- C                                end;+ S4 ^1 q/ v7 k) `
                                @.CurrIcon := "drivingHome";
; H1 y, }) w5 k                                @.DrivingHome := true;/ R' W& `  T1 }, d
                        end;: d9 |: J: {/ i+ N+ F5 h) {
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
4 e! w6 U' S: K6 `, b8 G                        part := @.transpOrder;
( I& _1 c/ O' o                        part.move(@);-- load part
  J1 @+ Z& y* V5 Y0 s- v4 X$ \                        @.CurrIcon := "load";  s2 d( a! c; x8 F2 K6 k( s8 f. k" o9 l
                        GlobalDistObj := part.globDestination;0 u. M: H# J2 B( b) O
                        assignLObj := rgmanager.rgAssignL;
$ V$ m+ d2 R1 i4 s& b                        row := assignLObj.getRowNo(GlobalDistObj);( t# L) @6 y3 d: \/ C* u' A: |- M
                        if Row = -1 then -- since 70
' ^) f6 W) u3 ~8 M9 l, M( k                                if lan=1 then( u& W& D# {, e- Y( w
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
, i( ]5 m$ ?: n% C! X& ~                                                to_str("in der Andockstation: \"",?.~.name,"\""));
- Q  B( V- [) N% E/ L                                else
1 A' f: M: J3 a' |                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
) |) S! P4 \4 [. p8 a  G                                                to_str("in docking station: \"",?.~.name,"\""));                                4 j  `. @& Z+ h; g
                                end;9 [9 M4 g) f$ q- a- W5 n
                        else
- m! B4 x% y$ Z4 I# [/ \# M                                @.Destination := assignLObj[1,row];- J6 U$ ~: l9 t# B
                        end;                       
0 N& @- e+ r! L$ G; ?, Z                        newDirection(@);
$ U, W& e) t2 d0 m                        @.HasOrder := true;
+ h- j7 @; x) ?& f                end;
. M1 C* n, E/ V, G! Y/ Y+ e; ~        end;9 t* _+ c. z- ~9 I
end;        -- of the method
' S* V, `. z  \9 E/ i7 Y
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 3 X( Z! H1 ]8 \7 a; v: Z) U
& C$ {6 B) M. ]' O% V; X/ Y" K
这是AGV_putin中arrive的method。
* X5 W$ o' M& W$ c5 m. L, \" \( a" x5 H& ~( ?+ d) \) ^  \/ y
当到达物料速度越高时,这个报警更多,; ]6 ?2 F2 e( i; r/ j. F( x
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
8 P/ m6 k- g: U: H$ q# Z程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
0 w$ b; u1 w& E4 ^0 Z9 ?0 |0 {, {3 \4 g1 W) L" K
另外一个小建议,就是move,所有的move都可以这样, o7 q4 b" t) M% l
if not move() then debug end& H, I: W  T% h# b& G. b2 P
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。% X) D+ k2 O/ N' u
plant simulation中的free libraries有AGV模板,
$ f; Q8 \) z" E# O& B里面也有案例。
9 n3 @- A- i% _! ~/ Q我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。( v3 m- F9 q$ \( ^& u" p) d4 {, }

0 s) m, x! U) F9 M* h2 n9 R我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 # }+ V9 y" ?8 }" ?4 T" _% j

' b( A) h  @* O9 L2 e; l那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
, z! H. s) E, K5 f这是AGV_putin中arrive的method。
7 v6 Q& N5 \' ^% A/ ~3 d& Z7 Y, r" e/ ]" e, K- s
当到达物料速度越高时,这个报警更多,

( N- Z8 s8 f  L* n! j# F另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-12-27 23:38 , Processed in 0.788279 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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