设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8319|回复: 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'
* c3 H8 c6 \- o3 k*/
( U  h2 S. ~, S* S$ t% Mis; _- u1 W. l! Q/ }1 _
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;& m1 q/ B7 }9 k& A# `3 O
do) {- t: x2 {$ v
        Lan := rootfolder.Internal.Tools.AOLlanguage;
5 G0 r3 ~! b- o        if current = @.Destination -- else return7 s- f' O/ r3 l7 k
        then: I0 i' Q* l+ K& M2 Q  i
                @.Destination := void;
2 d0 n* M; z5 r% H+ _( {, q4 k4 n                if @.occupied then0 m. e6 V# T6 c+ t' ^' K
                        part := @.cont;* f+ |2 u  F4 \$ n5 v- w3 \
                        @.transpOrder := void;8 m0 d  v: p+ F
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
* n- t5 n& c, C; G1 d                                @,root.eventcontroller.simTime);+ v+ ~. m' D  B! Y
                        @.HasOrder := false;0 k- h, j& Z/ }
                        @.DrivingHome := true;
  w: U( v5 A4 D                        rgManager.tryToStartTransOrder;
+ \2 _9 l: H1 T4 H' `0 I9 L& k% r: k                        if @.Destination = void5 ~9 Q% h' x1 b2 k
                        then -- no transport order for vehicle @* W) ]  ~" _" H
                                @.Destination :=9 Q" b0 t2 U  m9 U+ h) F
                                rgManager.nearestFreeStation(@,track.~);5 o/ g& ?! s- }/ U% h
                                newDirection(@);   ) ~( Y( D  v6 Z+ t  K4 T
                                if @.Destination /= void then
) y4 f; [3 m, H. U9 t3 V                                        @.Destination.NumReservation :=
  j: \; B( P$ S" h                                        @.Destination.NumReservation + 1;
5 U% ?$ J! f4 R- {                                end;: s8 @- z, ]$ i$ ~; \( I$ v
                                @.CurrIcon := "drivingHome";
; F( F0 p' B4 D$ z) Z2 e$ n                                @.DrivingHome := true;9 F. ^# z! n4 |- q$ A
                        end;
& P( s4 ~5 K' |, c) P                else -- the vehicle @ is empty, both vehicle and part are in the same dock station5 ^5 z) A! Z1 m% |4 e, N
                        part := @.transpOrder;  ?$ T  o1 d$ W1 f
                        part.move(@);-- load part
. V; u; G. _& e# t5 U                        @.CurrIcon := "load";
  w: A3 F" i. p6 ?! }# b                        GlobalDistObj := part.globDestination;
$ D1 |% l- ~" ]6 c7 h' T# h; [                        assignLObj := rgmanager.rgAssignL;
. \* i9 @5 [) H( f. i% d                        row := assignLObj.getRowNo(GlobalDistObj);
0 h# H4 r% x2 D, c                        if Row = -1 then -- since 70+ f- c1 O/ i7 V; b+ c) H* `5 Y
                                if lan=1 then' |- x9 E1 g5 [/ _- e0 s3 ^
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
. \7 `' K. `! _1 j/ o5 x                                                to_str("in der Andockstation: \"",?.~.name,"\""));/ H* \, [. j) c- J" R* \6 D
                                else
' r) ~) _3 X. t3 X+ e. |                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
( w2 P, u; k7 H. c, r                                                to_str("in docking station: \"",?.~.name,"\""));                               
5 q8 q& R" N7 m5 P1 E# I                                end;
: \" v  e% k1 E( p1 n' H                        else, P5 X3 l4 e5 ]% X, p2 T. m
                                @.Destination := assignLObj[1,row];- D# S. S( X7 n3 N' ?" z
                        end;                       
4 I+ u1 l8 G: S3 O                        newDirection(@);4 d. x' E' n7 z, E# t* t  A
                        @.HasOrder := true;4 Q& i4 ?2 }; u6 }0 C
                end;
" w( a) R# X% [, R. ^! O! H% n        end;  s7 x& S9 g. z# e
end;        -- of the method, f* h# A9 Z& T
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
- _  h) c( o6 R2 U9 k- p
/ n% \+ @4 d7 V+ v9 S" W' N  t: {这是AGV_putin中arrive的method。
1 h& l! c, E/ @7 }5 I3 G
8 X+ G# P9 k6 }7 |7 W0 t! [2 h当到达物料速度越高时,这个报警更多,6 K0 G1 K" Y+ Q
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。  N$ k! ?2 D$ p' `1 V
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?8 m  R2 X$ I7 T$ _
, P% E3 J4 r& k4 K7 ~8 Y
另外一个小建议,就是move,所有的move都可以这样
* P; `. V, m( \3 eif not move() then debug end" z. E0 `# B2 b
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
3 K& K9 R: d- T$ Hplant simulation中的free libraries有AGV模板,
, Y7 n) X  n6 A+ J里面也有案例。3 O' S' H+ F0 c" Y. r4 P" W8 \
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。% |  Q! s8 U7 K9 \# U
9 V" z. |8 y, `8 Q, `5 D* |
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
! X2 t' U* j$ a; I( u& k
5 f9 ~, ?& D7 I7 m那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 & F4 i+ T$ }2 F# g* W- {
这是AGV_putin中arrive的method。$ y5 h) y! d- g* ]# X5 f* e- s4 O

8 E+ N: c& {3 R0 Q当到达物料速度越高时,这个报警更多,

9 n% j6 x- b& R. W* e% S另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-27 14:53 , Processed in 0.017546 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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