设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6603|回复: 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'
( @8 }8 Z% Z( L# {; q*/4 ~! j$ H/ }  U  B; m
is
9 K6 {# d* f" B0 B        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
% Z6 c" g, f) u* Y' {do
; D5 Q5 |: N7 e: G& d: n: [- Q0 t        Lan := rootfolder.Internal.Tools.AOLlanguage;
$ u4 P) A! X# ]        if current = @.Destination -- else return
3 Z- Y8 j% p( f! O0 S; H+ Q        then
8 m" [+ n& ~/ P2 U. C                @.Destination := void;0 ^+ X1 e, c7 Z9 |* Z! D
                if @.occupied then8 z) Y& g2 |% N
                        part := @.cont;+ R: ?# g. m0 y! H. n- M$ Y
                        @.transpOrder := void;
5 G* f1 q3 |& [. d                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,+ @3 u! d. p: P" v1 S1 z1 l
                                @,root.eventcontroller.simTime);
7 R6 u6 y/ v, ^( c. c2 b                        @.HasOrder := false;
1 p$ E+ w+ Q3 g8 [; i                        @.DrivingHome := true;/ O$ P( \2 Q) g3 ^
                        rgManager.tryToStartTransOrder;
# q9 F/ B5 `& _' n# m* h# p9 D                        if @.Destination = void* S6 S. X* H1 P" F
                        then -- no transport order for vehicle @- j9 b  o6 C2 m& [9 i% K3 X
                                @.Destination :=+ D" [; i/ v* {5 b9 s0 j" y* x
                                rgManager.nearestFreeStation(@,track.~);' \2 F3 U; l+ T/ p9 H# v+ u
                                newDirection(@);   
1 g& K: d2 F7 S& a4 ]$ v) r: k2 m# B) A                                if @.Destination /= void then
8 ~9 g9 n" c# R: _, H- o$ f                                        @.Destination.NumReservation :=
8 e1 Q- b0 L1 [4 B/ C                                        @.Destination.NumReservation + 1;4 d8 b3 Y; f6 p- n
                                end;! v% p0 |3 g2 V2 g" ^4 ^4 S) ^
                                @.CurrIcon := "drivingHome";: P, i6 H0 n) z; I8 @+ u5 g7 w! p! P
                                @.DrivingHome := true;
7 P( @9 y/ V# Q, ?$ o, p, [                        end;
% `% ~1 Y. d% j* x                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
$ y' A. U8 Q' ?. [7 z, y                        part := @.transpOrder;
3 F0 I- t  E9 Y2 Z; i                        part.move(@);-- load part
) l8 t  [7 H& w                        @.CurrIcon := "load";, _  f0 z/ i/ _6 U
                        GlobalDistObj := part.globDestination;
. H/ g8 g* O; e2 j- V: Z                        assignLObj := rgmanager.rgAssignL;
1 Y. O& x+ e  C                        row := assignLObj.getRowNo(GlobalDistObj);
, H* ]6 s, _9 a                        if Row = -1 then -- since 709 }* u5 ?4 D" _0 _' C
                                if lan=1 then
1 N6 V4 Y- H8 ~/ Q: j! h/ |8 ?' `                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),9 d8 C# r. C1 ~, R% Y$ U% ^' L
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
9 ?/ E. J. Y0 {1 m. Q( p0 [; z                                else- C( h" F' P* w6 r1 E
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),! I) g# r7 j; Y% t
                                                to_str("in docking station: \"",?.~.name,"\""));                               
; l+ C- t4 d. x3 n                                end;
1 {$ K! b  b$ C8 p; b% o                        else5 y4 t- z4 E& J$ ]$ }
                                @.Destination := assignLObj[1,row];
6 T" r( y8 c# G* G. z% B8 t                        end;                        ) A& Z' w. e9 ^9 H2 l
                        newDirection(@);, d) H! h* E$ G9 I& E
                        @.HasOrder := true;
" o9 w2 Y0 u+ ?. d: H                end;# e% X! I  A9 A# Q* M4 ?' @
        end;! D. B  f3 U. Q( k
end;        -- of the method7 p! [/ |; V' G9 N0 U6 G) g) {
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
8 H, \( H& y" K
* G4 Z+ ?/ d* @( O" a这是AGV_putin中arrive的method。# E6 p9 |. ~7 N+ b% u" G
! a7 S6 l8 V, m
当到达物料速度越高时,这个报警更多,
& H" J3 h9 [  Z3 \0 G; Z可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
% ?# J4 S7 `) N7 g0 x程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
/ h4 a/ o1 q4 q8 ?' f6 X8 J( S% w
/ R" E3 o0 f, }另外一个小建议,就是move,所有的move都可以这样3 g6 s6 r  L( T! ]. M5 `% a( ^
if not move() then debug end
* V3 Y5 j5 X% |$ v这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
' `2 s# C+ Z1 Q( v" splant simulation中的free libraries有AGV模板,3 Q5 a& Z/ e* `- y6 b4 X
里面也有案例。+ X2 ~8 K4 p. ?* v' o1 \+ F6 w
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
0 u. p6 e, M& U; C+ ^3 C8 U$ b4 E. H7 V) `: f7 \* o
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
# @. T' N9 Z. ]$ P% M) I8 Z
8 E; Q$ Y1 ^* o1 k! P8 }" G1 V那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 . Y8 q) J8 Q; r! U
这是AGV_putin中arrive的method。( t- V4 v; ?. g! ?! F- ]

" R  i* [1 a& `9 ^: r! l当到达物料速度越高时,这个报警更多,

) {- L& \  ]; M另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-15 17:06 , Processed in 0.018309 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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