设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7411|回复: 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( R8 \8 e7 ]/ F" s: c" P*/
/ K$ M& e/ k( N8 B1 gis9 k& j& R8 F* O, V" }/ p
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;3 @. {8 w3 F# L! j. k! s4 u
do
4 ^- `" ^8 k' O: G: T! W. x" ^        Lan := rootfolder.Internal.Tools.AOLlanguage;& d4 L4 R8 x6 H' o1 J! C
        if current = @.Destination -- else return0 z' ?3 B/ G7 j2 N: R1 K9 ^4 L
        then
. h5 T1 S' V' K$ L                @.Destination := void;3 Y7 A; y$ T+ M6 Z. E( y
                if @.occupied then
  W. R- g3 u3 f5 C- d7 I                        part := @.cont;1 s: a- y0 p3 w2 _/ U! w
                        @.transpOrder := void;
; M" S  q9 l! F  {                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,9 r7 f0 n* B% d, m# T* P! I
                                @,root.eventcontroller.simTime);
- V0 \- a! `* g- M+ b7 M  ]                        @.HasOrder := false;
9 o, r: ~. I1 C                        @.DrivingHome := true;4 Z* _4 S! }- y/ u; Y% @
                        rgManager.tryToStartTransOrder;
- a- h) B( \( L7 |9 k2 ?2 N' o' n                        if @.Destination = void8 _% X% t' H% e5 n9 L$ a; M
                        then -- no transport order for vehicle @* S1 U' \6 R, \" y
                                @.Destination :=6 N' L, z, ?( b# j+ g: m4 n
                                rgManager.nearestFreeStation(@,track.~);, X7 j' V9 L* `4 V. e8 Z+ h% I
                                newDirection(@);   
9 E8 G- w$ P# F6 C8 T' P/ j) @                                if @.Destination /= void then' T$ C# J' ?/ o2 c; J/ {+ m# r( [* |
                                        @.Destination.NumReservation :=
8 N1 N: H4 O5 a  Z2 `9 J& [5 R                                        @.Destination.NumReservation + 1;
' E8 U7 z# L) T0 m7 j. O. w6 m                                end;0 g3 g5 i6 b) j7 h0 p+ l+ \" n/ e7 v6 A
                                @.CurrIcon := "drivingHome";+ ]5 t7 c; ^  T- _
                                @.DrivingHome := true;; F( q2 ~# y+ `* d1 T3 m
                        end;+ G- N) M# c- e3 p
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
: t, ^- [4 K+ W8 `                        part := @.transpOrder;; T3 I- m" ?0 H8 f
                        part.move(@);-- load part
# u4 l8 X% H8 b# |! l% @& R+ x                        @.CurrIcon := "load";
: E2 ?7 J& Z' [4 x* N& T                        GlobalDistObj := part.globDestination;
5 Y# W+ I3 Z# \# [                        assignLObj := rgmanager.rgAssignL;  D, `( X( `4 T9 u: p
                        row := assignLObj.getRowNo(GlobalDistObj);
# j4 U1 A8 _0 H                        if Row = -1 then -- since 70
1 y. y% z. n$ C' ?                                if lan=1 then
7 e5 r4 \  W3 V. Q1 L* s                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),& C* C% w  q, W! l; d* I+ f
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
, ^! U! |. S- s                                else
$ E, \: ~+ L, W8 f8 P0 n                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
4 t" b4 _, ?: X/ o5 n( b                                                to_str("in docking station: \"",?.~.name,"\""));                                9 l% v0 H9 M- T) `& Q7 U2 I
                                end;
/ i: C! d( Z' E                        else( j& O$ Q& A, l* b: h6 V
                                @.Destination := assignLObj[1,row];7 _, j# o: E2 i; e
                        end;                       
2 P2 |/ e% w# r1 E$ X8 `- m                        newDirection(@);4 o) @, x: q0 M4 S) o& _5 x: ]
                        @.HasOrder := true;# M5 k  n' q* {! u3 o! L
                end;
& ~. N+ @8 N; M$ @# q% d; u        end;- i' `2 |$ e6 W$ u0 ~
end;        -- of the method. p+ M6 B, g: b3 b8 U+ ?) a
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
! c1 e6 @5 i% T! O; D& D- K2 d2 C- W. g. ?% K; L
这是AGV_putin中arrive的method。
: S: K5 G; j8 Q8 Q# \" O. ^. [$ S9 [
当到达物料速度越高时,这个报警更多,
9 J7 Y' ?  Q+ r* t. X( y可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
% @% I4 E- S& W0 i程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?& q, a1 O2 s! N7 H9 h+ A

4 L2 W/ G# }' r$ b2 |' V另外一个小建议,就是move,所有的move都可以这样% e! ~) [: x) J" h1 @
if not move() then debug end9 f, L( W! n6 y8 d; Z
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
' H  G$ L/ C& ]& gplant simulation中的free libraries有AGV模板,1 ?$ ~# z/ Z/ w
里面也有案例。+ K- W6 B* M) S: S9 S1 O6 E
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
8 a3 Y# I* E& j% D% }( q6 M
/ y3 w/ j. V4 z5 [  g' b6 r5 r% U我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 2 S6 U3 _' O, J3 c
8 e5 j5 K# M) ?5 Z/ R" c; W! m% y2 l
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
- B3 \" h4 ~' U( n: v4 e' x' E; H. t这是AGV_putin中arrive的method。
( z2 h" L0 S4 ]1 u8 Q; x
  I3 `  d& @9 d% f- J当到达物料速度越高时,这个报警更多,
/ H4 R1 ?) ^4 u4 i' S  V
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-10 04:06 , Processed in 0.024896 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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