设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8817|回复: 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'+ [5 R/ }$ G4 i! e& Q, ^
*/& o; i# N% y7 E! o
is2 Q! F* z3 `3 {+ L* J
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;6 e$ F: v; S! T( [& V) N; x
do7 S- W, B5 C4 ?7 [1 ]/ u3 |
        Lan := rootfolder.Internal.Tools.AOLlanguage;
1 h' `7 u( _; L% K+ Y7 Y( s        if current = @.Destination -- else return4 ?. T  }4 @; w7 K
        then
' B" T5 ?- D( I" F7 g                @.Destination := void;. f; l2 a: ]4 v: O0 H; y+ [% j# N
                if @.occupied then, j0 Z6 v6 }7 w: e# G. w. M4 ~
                        part := @.cont;
. n2 X& a0 X- O3 B) |* h+ \' J' C                        @.transpOrder := void;
; W# S- h% W* c2 b- r                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
/ a4 l( X2 x9 O- I5 j                                @,root.eventcontroller.simTime);2 h% b* m& i* _- N- _
                        @.HasOrder := false;( ?: b9 V+ {( H  E+ R
                        @.DrivingHome := true;
1 C6 R5 {- z2 Y" M                        rgManager.tryToStartTransOrder;5 ?( m. Z/ i  @) K
                        if @.Destination = void1 |2 `0 t$ i1 J+ N0 p& z
                        then -- no transport order for vehicle @
* \5 S" M1 n5 A+ `/ [' \% N6 i                                @.Destination :=4 v8 ~$ S/ |4 g1 t
                                rgManager.nearestFreeStation(@,track.~);
1 r3 {2 `- c# t8 T                                newDirection(@);   ! f. {, [/ W+ d
                                if @.Destination /= void then
& ~( a0 ?: ^: E( q                                        @.Destination.NumReservation :=
& o( D9 v. t! m1 O( A! n$ R% M* A                                        @.Destination.NumReservation + 1;. |0 _$ O  k2 B  P( c" k4 O; [3 \
                                end;
9 y; L/ F5 w( t6 R' X+ {4 f                                @.CurrIcon := "drivingHome";
3 {' Q" ?) ]. U                                @.DrivingHome := true;0 @1 @( u3 O0 F/ U! n+ U0 Y3 n
                        end;7 j5 E+ b8 q' a4 |* ]
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station' k2 |9 _  b) y3 F; p
                        part := @.transpOrder;
  ~' i6 p7 W/ U8 y2 {' \                        part.move(@);-- load part! X/ m* K+ E6 a/ n
                        @.CurrIcon := "load";2 t+ m; c0 ^$ Y' S/ ?# M- {1 R- e# ]
                        GlobalDistObj := part.globDestination;4 m, o- W1 \* U6 i/ O' ~
                        assignLObj := rgmanager.rgAssignL;
6 v. \2 |% o" g! Y6 M: u                        row := assignLObj.getRowNo(GlobalDistObj);3 r; W+ W5 N; X0 \6 ^5 F
                        if Row = -1 then -- since 700 ?' i4 D' _6 Q0 g+ k3 I3 K; ~
                                if lan=1 then/ r& g* d3 D8 y1 {
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),1 q  k- y% c% O( h) r& N
                                                to_str("in der Andockstation: \"",?.~.name,"\""));2 K# k: l1 D' a' y
                                else
: U5 E* G4 L+ T* Z                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),. Z* |: M* H4 J  q0 O$ B0 j2 B
                                                to_str("in docking station: \"",?.~.name,"\""));                               
1 ^) [$ }& r# k5 b* k                                end;
+ v$ O0 i$ Y% q0 h" y; x8 |- M' a                        else2 _, [( j2 M: @2 |
                                @.Destination := assignLObj[1,row];) `$ g! f* g, B, p, N' ?0 e3 A
                        end;                        + V& d( M5 K  s% H+ }
                        newDirection(@);
* G/ y2 O' O4 {% |1 \                        @.HasOrder := true;9 Q5 C) W6 s8 J  O7 t5 Q
                end;
7 g! p2 ?8 ^  }! }        end;! k5 Z% p, Q, F3 R) R
end;        -- of the method
( G' q8 n* N- ]' {
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
- _7 A3 x0 K' B( G  n+ C+ G0 a6 H5 Y5 Q8 ^0 t2 W
这是AGV_putin中arrive的method。
2 {+ Y: N6 S* M+ Z1 v: S9 V! T" f1 d. Y2 a9 `8 e; z. E- x
当到达物料速度越高时,这个报警更多,
/ |/ w1 |! m2 v+ [+ E* l) {可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
/ X* e; f( R0 E* ^& _, \$ D- p$ Y  T" f程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
4 q0 a4 R9 y0 Q5 r4 D( A
& [% t7 m, T8 _1 I9 g9 T另外一个小建议,就是move,所有的move都可以这样1 g) D  w" y4 L4 n, e2 l
if not move() then debug end. L1 w! _0 C5 m8 l. {
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
/ _) w! C- ?' ]+ c( R' @' k" C( e% xplant simulation中的free libraries有AGV模板,8 C7 `- b  M8 F/ v6 S
里面也有案例。: ]4 f; r4 s- u, O
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。3 J* x0 Q0 [1 _/ O- ?% V  y- u) S

# Z  K. c6 z: y7 I1 Y- P. f我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 * Y. L* v) |) B1 u! U& @. T
: q1 w8 i7 p* O, u! F/ ^* i
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 . ~) s. I7 o6 o' ^, k
这是AGV_putin中arrive的method。
& g$ L6 a. m; d5 c$ D5 B3 Q( o6 V$ X, U2 j, H
当到达物料速度越高时,这个报警更多,
0 V7 M) J" e+ t' i$ a
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-28 04:41 , Processed in 0.018552 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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