设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6915|回复: 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 i. ~" g/ j8 ]' M
*/7 |4 H( K( Q& V  a% `
is
, g" u5 m* K( C        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
) B% A; Q( M5 ^+ hdo
' g* j5 `9 N. j2 f+ A1 I& V        Lan := rootfolder.Internal.Tools.AOLlanguage;& J" M! i# c) d9 l8 C) O
        if current = @.Destination -- else return
) ]8 c& g5 w6 g; y" [        then! M& \: `# t5 k. t7 Q! O# P
                @.Destination := void;
) G5 ^+ z# L" b4 a, [                if @.occupied then  s  G3 p' b' d  k- }. b" V6 D, e
                        part := @.cont;
" ^; a1 J/ D. J/ F8 ~+ T5 K                        @.transpOrder := void;, \0 O# W$ Z" c  o
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
3 ~' c5 z* }- |. z4 `* [                                @,root.eventcontroller.simTime);
8 ^. w0 X. G9 ^' l5 @                        @.HasOrder := false;
. ?) Z. @) q* x# E: H( B  j" `                        @.DrivingHome := true;
/ z9 x* Y( R7 ^* d( F, P! z                        rgManager.tryToStartTransOrder;. y' M5 n8 V  K2 B0 h/ w6 v
                        if @.Destination = void
, C! ?  F" h4 v) k$ m( A                        then -- no transport order for vehicle @
3 m5 ^! P3 n  a5 ~" ^5 g8 J                                @.Destination :=
6 @& {) v  Y9 J4 `2 z5 T                                rgManager.nearestFreeStation(@,track.~);, X! g* h9 i, _6 _7 B
                                newDirection(@);   
- q/ E" w6 u9 V4 P  `" `/ q                                if @.Destination /= void then+ H/ ~# Q. C% F: a/ H
                                        @.Destination.NumReservation :=& y0 P& A. ?! {) U0 J
                                        @.Destination.NumReservation + 1;0 H7 _3 Z- j( a5 |' M  u
                                end;
5 B4 ?4 S5 O. B                                @.CurrIcon := "drivingHome";
; }4 w$ D. x1 }1 V$ t7 ]8 H4 Z/ i                                @.DrivingHome := true;
, ^" O/ f) i6 W- s1 m; ]                        end;
% Z" Y# ]2 K6 R6 g# u                else -- the vehicle @ is empty, both vehicle and part are in the same dock station, k! `0 {4 i" o9 `' J! l
                        part := @.transpOrder;
7 @2 \, @8 T$ N: T8 q                        part.move(@);-- load part
9 }7 c1 y( {  o& L                        @.CurrIcon := "load";
' a: W( R1 z# c3 v: p: w                        GlobalDistObj := part.globDestination;+ |" N" o9 e( J
                        assignLObj := rgmanager.rgAssignL;
2 y0 r2 j# _# ^5 \! `4 x/ o$ @                        row := assignLObj.getRowNo(GlobalDistObj);
0 D  R% t0 m7 l7 v  q% e                        if Row = -1 then -- since 70' ]  d7 y- A5 r- G. R' a  ^, j- B0 t
                                if lan=1 then
7 ~. ~, s# j) y0 G6 h/ Z                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),$ X8 H  D* N% S3 \% c2 o
                                                to_str("in der Andockstation: \"",?.~.name,"\""));  u6 z7 Z! ]' x/ |- w
                                else
  E0 d: @7 ]) o# T9 ~- i                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
* h8 g: ~  z  y; z/ K( t                                                to_str("in docking station: \"",?.~.name,"\""));                               
* }5 o" A. \& j- d& R# P* C1 ]* A                                end;' ~8 g' q3 H, T
                        else
9 _& N% L. m& C( K$ [+ h+ z                                @.Destination := assignLObj[1,row];
; a+ ^% X; X2 ^. @0 |8 C, ?* F1 V                        end;                        8 \* R6 i+ ?* ^
                        newDirection(@);+ v" e6 M. Y9 |7 k
                        @.HasOrder := true;
7 Q; R& B( L5 s4 ~                end;( T6 J& y# I) A3 S7 F; k& y
        end;2 K; P2 Q& b0 a5 b" ~  {( |
end;        -- of the method1 S1 q; ]" [# ]) M
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ' d3 s& u4 G6 S: E4 D$ M
3 T2 L% L6 A; A2 L/ T( \5 e; X
这是AGV_putin中arrive的method。
. ^2 ^( H, b2 |1 _% p. ]2 v
( l4 s# g5 I8 I8 H( x当到达物料速度越高时,这个报警更多,
0 N7 e" c7 O- `1 ?4 P5 N2 i" R可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。+ X$ d& E. N1 L5 A2 f0 t
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?. ]5 L  j0 V6 J# g! k( H" K6 v

) U6 l. K" B$ c6 [- _另外一个小建议,就是move,所有的move都可以这样
6 ~, y. p( Z- O' c) }6 G/ @if not move() then debug end
& a; h+ h8 x* g& O8 k  U这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
; [8 f/ L+ \" |% lplant simulation中的free libraries有AGV模板,
8 Y0 ~( ?& ?# L" W5 b3 W. i里面也有案例。4 ?. m, b. M, W& X! U
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。! }/ ^( J6 I  O' r

" p9 j* N( y/ Z1 J; s我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 / U- S# W% W6 `4 L' I" x/ @; {

. H$ J6 F& h6 ?3 e那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
, `( A7 ]1 J# x! x这是AGV_putin中arrive的method。
, t$ n( Z, r) ?: Q. L" h
& K  q/ L1 m8 x: b7 I当到达物料速度越高时,这个报警更多,

2 s, R2 @' g  H) U% W另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-6 15:26 , Processed in 0.023707 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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