设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9663|回复: 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'+ B- H, e4 k4 R0 L9 i7 B9 o" G3 g3 e& G
*// E% F& N8 ]" I
is4 o5 L9 R& r! H- y
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
2 H) D; ?( z& i4 t( I' Kdo# D3 Z, j9 w4 q$ a' n; a2 p
        Lan := rootfolder.Internal.Tools.AOLlanguage;3 b1 [' b% o) O
        if current = @.Destination -- else return. u3 H2 ]( a6 b$ u; O3 O
        then
! L8 @% M% t: q+ I6 W0 ?2 }                @.Destination := void;- f* p: {) m& U& J+ g
                if @.occupied then2 ^( I3 {" g7 v, A! v! Z
                        part := @.cont;
2 _: S; ^1 X4 y3 |                        @.transpOrder := void;
/ {2 P1 _5 V1 ^3 ?+ T' m                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,' ^* K% U# B; ]
                                @,root.eventcontroller.simTime);
$ p  L0 K* v7 v' v2 B1 ]) H                        @.HasOrder := false;, h/ Z  L( k. \& i! \; k0 q
                        @.DrivingHome := true;
- {. V7 a/ o! I# Q                        rgManager.tryToStartTransOrder;* d8 }5 P/ s5 u. b  J
                        if @.Destination = void$ ?" g7 S$ ]6 }( B2 ?4 C& _
                        then -- no transport order for vehicle @/ A- X  _5 N- V
                                @.Destination :=5 a2 S; M: T' s, h
                                rgManager.nearestFreeStation(@,track.~);
1 v" f: T, G! x; p' ]* M- W$ }                                newDirection(@);   0 @# z* y# }4 g; t6 J
                                if @.Destination /= void then9 f- W; ]# u9 P3 I" D
                                        @.Destination.NumReservation :=5 v+ S6 B/ ]* E' o& D4 e; K
                                        @.Destination.NumReservation + 1;& R7 F- t- p8 B1 R5 a8 A
                                end;( S9 a+ x9 I5 H: t- W
                                @.CurrIcon := "drivingHome";
3 x$ ^! U! @! B0 G+ r0 V4 ]                                @.DrivingHome := true;, @1 B5 E" D" v& ]
                        end;
) u2 S* v' i* C! s1 K- n. l                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
) Y6 W, M! h* B* @2 A                        part := @.transpOrder;
! t; r5 D, b+ N                        part.move(@);-- load part
- `3 o+ H; a% o! e8 M                        @.CurrIcon := "load";3 ]) m" _* r% i# M
                        GlobalDistObj := part.globDestination;7 I3 v6 ?+ h% K1 t7 ]. `/ j
                        assignLObj := rgmanager.rgAssignL;
3 D  Z+ {8 {$ \0 R0 m' f; x                        row := assignLObj.getRowNo(GlobalDistObj);
% {# a2 P6 i( W+ D0 C9 |! ^7 P& u                        if Row = -1 then -- since 70
+ \% a" t4 A+ U5 T1 {0 o                                if lan=1 then
- A) v; }9 I. d, |                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),* F4 T3 r* F/ |* _
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
8 p0 r7 N) P! W                                else5 N- J- \9 B6 [$ E; @/ Q: }
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),- |$ l0 z: s9 a' N7 L
                                                to_str("in docking station: \"",?.~.name,"\""));                                # _# l6 e; c  c$ E
                                end;
$ |5 w# H) }9 D$ w! [                        else( H, j. p# {/ m+ e5 H2 `
                                @.Destination := assignLObj[1,row];
  \. |4 G% k7 v  B. O# ^/ S                        end;                        ! U4 T' z- e( s8 M
                        newDirection(@);/ ~8 ]4 t  W5 O: u% j
                        @.HasOrder := true;
4 O5 H0 t+ e* f8 [2 u9 ^- r                end;: z+ P/ L0 @5 \3 {0 _- k+ N$ e
        end;
% ~# n" I9 r, U" p( e" X; a4 f5 d, rend;        -- of the method* ]9 x0 a5 o$ O
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
7 b5 k+ ?7 p. m8 u  M, ]7 _" V- E9 z9 ^) @) g
这是AGV_putin中arrive的method。
  U1 q- E: t2 U
7 w) X6 j" ]+ i当到达物料速度越高时,这个报警更多,# _5 P7 K% z5 L
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
1 e. p& I, W  v4 s程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
5 x( A! k! ^5 v, l( F' T$ y9 ]; {: e" t+ p9 O6 y- S
另外一个小建议,就是move,所有的move都可以这样. O7 {4 ?& x3 L& E  h1 _
if not move() then debug end; S. O7 N6 a" i" C; S
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。! r( ^" Y5 e* C
plant simulation中的free libraries有AGV模板,3 B9 X/ d% U, N
里面也有案例。
2 N7 Y& i/ q: @9 l1 x! n3 C( _5 w我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
* F6 |* k9 q+ {7 g) z/ f
1 G: l* y/ n* x8 W5 @9 Q我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
# p+ d4 K* \; ~7 B0 @+ l6 G! o2 a; y4 y  l5 Q. t7 n
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
' }  W6 ^! n; f- u# @( }+ Z; m这是AGV_putin中arrive的method。
; T- X3 g: ?' i' {6 ~8 ?  y# {) c: \
3 P" ~6 C+ x6 v+ k7 Z当到达物料速度越高时,这个报警更多,

, a. S3 l5 I/ t; ?另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-15 16:29 , Processed in 0.020412 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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