设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 4624|回复: 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'
5 G: E/ ]: f& p2 w*/
, c5 Z4 I, L( l& w0 fis
, {* `. Y: W% }        part, GlobalDistObj, assignLObj:object;row,Lan:integer;0 g7 X/ i7 {' W' X# Q5 d
do. {4 R0 N: i" s+ K$ @, e
        Lan := rootfolder.Internal.Tools.AOLlanguage;* ~. ~  q$ z5 \5 \% W
        if current = @.Destination -- else return3 x7 g, z( R  ]. x; ]5 V
        then
2 R$ i, [; H" k. ^                @.Destination := void;# H4 b0 a, l# C
                if @.occupied then; r$ K5 Y1 ~# u% N' V( \+ N
                        part := @.cont;
- o* ^* s- L. M, e. h' s& a6 ~                        @.transpOrder := void;* V3 P" V  }  Q) W* x
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,2 V) h! G$ @9 L9 V: {5 V+ H# z! N
                                @,root.eventcontroller.simTime);
# v( {  `0 R+ r2 D( I( ?                        @.HasOrder := false;
4 q7 l3 u! e3 k                        @.DrivingHome := true;
$ X% d- T* X% @( t                        rgManager.tryToStartTransOrder;
3 b9 ^! v6 Q2 `1 [3 C2 v( Z4 @                        if @.Destination = void
, D3 p; {8 h' H. r                        then -- no transport order for vehicle @( E/ `1 q, x" `, ^
                                @.Destination :=( ~3 k6 ~4 x$ h) m. }
                                rgManager.nearestFreeStation(@,track.~);
1 S4 j( [7 n- Y! e                                newDirection(@);     k2 q7 q- b  E- X, C2 S2 t
                                if @.Destination /= void then+ z) u7 r5 \5 \4 E
                                        @.Destination.NumReservation :=
, l" v, ?! r( R- B( ^$ k: j  q                                        @.Destination.NumReservation + 1;
% W  h+ v7 \8 I- B/ O+ \) o                                end;! }1 r+ ]; t& ^
                                @.CurrIcon := "drivingHome";
$ W: T: h# x  v1 L# ~7 I  [7 P) m9 j                                @.DrivingHome := true;
) P( U: {5 Y: G! u6 G( ^                        end;
/ \0 }/ Y: }' w. }+ ^                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
4 R  h9 W, `7 c0 B                        part := @.transpOrder;& I- ^8 x! J( i$ l
                        part.move(@);-- load part
+ V& N7 H# M% L                        @.CurrIcon := "load";9 Q! K# i! w  d0 P5 h
                        GlobalDistObj := part.globDestination;
  a9 Y$ {9 {% f                        assignLObj := rgmanager.rgAssignL;
' [8 Y' Y" }3 ^- {1 n8 W                        row := assignLObj.getRowNo(GlobalDistObj);5 G. @' `5 K9 q, |
                        if Row = -1 then -- since 703 @, _; p% J% s8 ]& x
                                if lan=1 then6 u  x- v* m- i* y) m7 j4 c2 l
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
0 H2 @- c  `2 K0 s) R7 D( n                                                to_str("in der Andockstation: \"",?.~.name,"\""));" ]8 N" q$ Z+ G6 J' Z. x$ }9 {  p
                                else9 @( ]0 n  c; z, s2 v
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),$ |1 v7 s) y% {) W* U
                                                to_str("in docking station: \"",?.~.name,"\""));                                6 N7 O  C" G& G
                                end;
# K- \/ X) x1 V; x                        else0 H+ C/ s) A7 P/ D: S' M
                                @.Destination := assignLObj[1,row];
6 z  _+ Q7 ]$ U7 ^  `) f# a                        end;                       
% A' t) B# |; ^                        newDirection(@);
. s+ D! \, g# ~                        @.HasOrder := true;5 z0 L* X0 ~+ m
                end;: f4 n% M# A# v. L8 w
        end;7 }6 D# a% ^9 x$ \2 ~: [
end;        -- of the method0 z( M/ _" y: O, t$ G; H2 S0 R" a
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 0 p% r, O# W$ w+ G

- y0 k+ C: Z1 }6 r( h+ x4 L这是AGV_putin中arrive的method。, L3 E/ G! t1 F0 z- t3 l0 x  F7 B

- ~8 ]' O- t  `# P: y当到达物料速度越高时,这个报警更多,
% |- q! j% M5 Q9 R2 S8 J, s7 _可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。3 j8 V# P2 t, A9 m& P' u
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?2 L/ Z, w, m  a4 {- m; n
3 N8 O" y, I' @' s
另外一个小建议,就是move,所有的move都可以这样
9 |+ C# b  y& dif not move() then debug end
. d4 S1 |8 q  r  ?1 z这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。9 E% P$ e. _; W  g9 r& C8 n% c: q
plant simulation中的free libraries有AGV模板,
: M/ d! d& `# d: P1 K. N里面也有案例。1 j* p7 h- Y: f/ ^
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。5 Y1 g- U5 |/ m6 H/ h# S
" k  a" y4 R) n4 J% R
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 : U% f- [, [1 g9 B4 N7 b) s5 y
- T& j: V$ T0 u) }2 z
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
  F: B. T- u  j6 @7 V: U0 X# a- q这是AGV_putin中arrive的method。
. k; d: y6 q: q7 i9 H  U& a
$ {* x( C( m( v. @1 i3 q9 n8 Y# O当到达物料速度越高时,这个报警更多,
7 I7 }) z0 i1 L! j, y0 n+ a/ z9 J" L
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-7-11 14:47 , Processed in 0.014490 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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