设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6879|回复: 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'/ p0 a6 H) [% N) d: ]& b" n
*/
, v6 F. _2 f6 Iis
& j8 ^% K  ^9 w1 Y4 S5 e% P& a  t        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
7 p5 u, j( R) |! K# w2 @/ \0 O. H- ndo* N$ o9 q2 V+ u1 E8 }9 ^
        Lan := rootfolder.Internal.Tools.AOLlanguage;
5 p' T2 `8 j/ N- F        if current = @.Destination -- else return
- |! i, P- \# W: D- v        then6 ^  E2 }1 _" W0 D6 c$ Z
                @.Destination := void;7 N  H1 o" Y5 V7 w# |
                if @.occupied then
6 Z( K  d' s: Z: q" m                        part := @.cont;- ]. f0 e  g% F6 h' B8 e- n
                        @.transpOrder := void;! V- Q* {$ B' {$ u
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,, S: _9 j' i9 Y( F
                                @,root.eventcontroller.simTime);
2 G" f3 y% z- d' W" F                        @.HasOrder := false;( {, S3 o# ?6 q4 ^
                        @.DrivingHome := true;
3 a" w% z$ @/ ?2 W                        rgManager.tryToStartTransOrder;
. u) I( a1 |, ^1 K4 X' t# T1 o2 {4 l                        if @.Destination = void
0 m4 E0 p4 g/ z2 q- L                        then -- no transport order for vehicle @
2 }+ v/ L( w. }                                @.Destination :=7 w7 I) |0 e/ b: D  h' z9 W
                                rgManager.nearestFreeStation(@,track.~);  r$ s8 J3 P% ]# J# t( d! M
                                newDirection(@);   
  I/ e3 Q! i- ]( S, g: x                                if @.Destination /= void then
7 i/ @  U/ E- O" c( I8 }# ^4 d% G7 J                                        @.Destination.NumReservation :=- o+ _- x  {% b9 p: j) f! w
                                        @.Destination.NumReservation + 1;
0 ]- n8 I# A3 m: J3 g4 g& G! r                                end;& r5 x% ~% o; v: t2 g
                                @.CurrIcon := "drivingHome";
# ~# b2 h( I  y+ x                                @.DrivingHome := true;
$ O  ~3 l( y  N) u8 ^6 h                        end;8 s, B+ K  J: Q8 v/ ]2 E3 [4 `, b
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station2 p, P& Y0 @  [3 x1 m6 t
                        part := @.transpOrder;) o& W7 C7 r9 d, \6 \4 T# U
                        part.move(@);-- load part
! Y, ~9 }1 e$ n# V4 w5 {! a- U                        @.CurrIcon := "load";6 L" T4 U1 K  A5 S1 |+ x
                        GlobalDistObj := part.globDestination;1 {" @* x" C1 v( o. e
                        assignLObj := rgmanager.rgAssignL;
9 N. u; L( w( c' S1 U( o/ H                        row := assignLObj.getRowNo(GlobalDistObj);4 V/ t6 I: G- g. z
                        if Row = -1 then -- since 70
, h7 e8 L2 J- S' x; Q                                if lan=1 then! a' `+ ]8 s  t1 j0 {% W
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),0 Q6 C/ S+ u$ z' {0 Y% H
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
( @' }7 j/ j, i" \+ l5 `' L                                else
. T: r% ]% E9 T% \% _$ G+ j                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),( E5 q: \- W% B/ z( U& @( A3 M
                                                to_str("in docking station: \"",?.~.name,"\""));                               
4 f8 h. @& f) e4 P8 x* z& [) ?# Y2 ^  `                                end;$ o' V2 o7 `- m: {' |$ k2 o
                        else8 A2 v! Y. N* M' Y% M
                                @.Destination := assignLObj[1,row];
2 a. b% X+ b1 g3 h) A                        end;                        3 _0 Q% o+ j! Q) y4 P  i" t
                        newDirection(@);1 q, M1 p% G$ `% l$ {9 l3 ]
                        @.HasOrder := true;
0 q8 E" i1 W2 o8 J3 g1 {5 p                end;
# r& l% y, r# ~        end;6 a8 D  h6 U6 r9 S- q- ~
end;        -- of the method
8 p  F$ H- ]5 J- Z4 B- ]4 W
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ' D8 C6 u) i9 ~* r
* [7 Z& }7 F- N  t: l, c
这是AGV_putin中arrive的method。) H: [* h8 t- b

& q! C$ E/ u2 r8 F当到达物料速度越高时,这个报警更多,5 I0 S8 Y# n3 B  ]1 G- W
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。) E) t; Y& K' ^' E
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?9 e$ g+ k- m5 t. R- A3 o

( X! s! S6 C7 ?+ w' W5 x3 W0 p另外一个小建议,就是move,所有的move都可以这样$ V. {/ f1 j. v
if not move() then debug end
) c3 @) w) K2 b# H  a8 Z4 O7 O: j这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
% v& E1 }1 x6 V  W, e7 dplant simulation中的free libraries有AGV模板,
+ s) @0 {9 E- }+ b- w里面也有案例。
, p5 ]% n; L, K我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。. C" r1 e8 k! c7 o
9 j( `  m, `" B2 P0 E7 _
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
" [; a' i8 }( {4 @% L  r! ^$ l. V. U+ l& K
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
) t4 p, e9 v  }这是AGV_putin中arrive的method。
- o. d: ]. t. v) t* w7 E$ |9 d2 i( }9 c( A1 d
当到达物料速度越高时,这个报警更多,

) J( s( x/ l3 Z9 p# t/ Z另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-4 06:48 , Processed in 0.017647 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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