设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6540|回复: 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': T- V, J! W% h  }. z! `/ U& k
*/% k8 R, ~+ V# g' x4 e$ [8 R
is
1 P; H/ ?& B8 T        part, GlobalDistObj, assignLObj:object;row,Lan:integer;4 i3 L. |1 `1 P% `& P) W) |
do1 _1 Q2 |0 ?0 D. G& c
        Lan := rootfolder.Internal.Tools.AOLlanguage;
; T0 A3 C" [) k! ^( Z        if current = @.Destination -- else return
* [# g! O- C2 N4 N& L1 d        then
# p, x3 V" Z3 j3 [                @.Destination := void;
% A2 I6 r" z$ O                if @.occupied then; B6 K+ O! T) x% N# z4 S
                        part := @.cont;  O3 [5 i3 ~( d; ]7 J9 t
                        @.transpOrder := void;
" `. U0 m# `& j" h3 c" P                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
0 h  q' M) z' B. M4 @! Q+ c                                @,root.eventcontroller.simTime);
- N& e' U9 g8 M                        @.HasOrder := false;
/ P* Q& E! e! ]5 L# O                        @.DrivingHome := true;
1 m4 D& ]5 T. e                        rgManager.tryToStartTransOrder;
7 q! w, @  m! C: r                        if @.Destination = void
0 ~4 l* i7 a' _2 \                        then -- no transport order for vehicle @
1 e4 d) e; G) k0 C& x' K                                @.Destination :=
+ c$ ]1 C- E2 {# t$ W                                rgManager.nearestFreeStation(@,track.~);
' w# G- c7 M9 n# i                                newDirection(@);   
: S/ u% G) }# o' M' e                                if @.Destination /= void then/ S' P+ p9 ^: X- |6 o
                                        @.Destination.NumReservation :=
; R- ^, V2 d  V                                        @.Destination.NumReservation + 1;1 w: j+ d! B& @3 o; N; [) y
                                end;* T; b3 m" l! z, |; x
                                @.CurrIcon := "drivingHome";
7 e4 Q; H( D$ @" ]                                @.DrivingHome := true;! A8 A* y( P' z/ \: K5 r
                        end;
! b" s4 M, ]! ^6 n# c                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
6 k1 P( r' Z" g2 v7 S0 u$ p                        part := @.transpOrder;
$ b/ K7 x- v* ?' @                        part.move(@);-- load part. y( j, m: j. N" n! M) b6 x* v) \
                        @.CurrIcon := "load";4 }2 f; o7 w: \# E% [& f
                        GlobalDistObj := part.globDestination;
" o! `, q: U( Y                        assignLObj := rgmanager.rgAssignL;2 ^  i- r8 S. V
                        row := assignLObj.getRowNo(GlobalDistObj);7 j" X% k( ]; s9 N
                        if Row = -1 then -- since 704 A$ j" t6 N8 j
                                if lan=1 then
0 y1 R2 }" \$ X3 R: o  v                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
2 O3 l5 R# S# J& C1 ^5 A; L$ {                                                to_str("in der Andockstation: \"",?.~.name,"\""));& y# h6 o9 t; }4 Q+ @0 l
                                else- c# N, i- F3 ^. {* R
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
, \. J% V& S+ y+ U: T' t' d( S                                                to_str("in docking station: \"",?.~.name,"\""));                                0 M. ?) @/ X6 F# j. [/ f
                                end;4 }& A* T% J, s
                        else
- _) i6 m% S2 X% h3 z                                @.Destination := assignLObj[1,row];
! O& j- p+ X4 Y! \8 M3 z0 b                        end;                       
. {, F* u$ g* p3 z6 c                        newDirection(@);( J5 {; V" P/ g9 R3 `. ~* V
                        @.HasOrder := true;
+ T, y! \* v( q8 i# I5 U: ]! A                end;& o5 p. {! |/ C0 c* {
        end;
3 G5 y0 |$ z, w0 t$ [) Yend;        -- of the method" G  U' K- B6 E
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ( @9 }# x( l' n7 j# X

# X) k. _% P/ r! n) x这是AGV_putin中arrive的method。
" t: U; N  @( d5 X" t# b5 ]% D3 C6 j0 f2 x
当到达物料速度越高时,这个报警更多,; \# {: x5 O1 L( Q& E
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
0 u, E% P0 H/ r% a) c2 Y: C程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
5 O' f5 x8 r1 l0 \8 G& \0 t0 x* ]0 A: r/ j
另外一个小建议,就是move,所有的move都可以这样9 B8 g0 ~2 t/ r0 W
if not move() then debug end6 V( V1 ]( H/ R% X
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。; Z! n* @) _9 u3 A8 K; M$ S
plant simulation中的free libraries有AGV模板,
3 Q0 }( L7 _) }4 G- m里面也有案例。% s' {0 o( I$ Y
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。$ q! M7 {- z) k. l8 s, ?" _
  d. U7 l5 u% @9 G, X$ I
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
" |9 [9 V% G8 f! X  `$ Y& A) X" U3 d9 [4 J8 t; |
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
* [  M  i- g# ]: y. a: e% a这是AGV_putin中arrive的method。+ I- T, I( r7 v3 G
* l2 r! @) C( c7 E4 ?
当到达物料速度越高时,这个报警更多,
$ T; [3 {# v6 {4 V+ V% }7 Z
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-11 22:04 , Processed in 0.017246 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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