设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10125|回复: 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'
  R8 K2 }% v; O4 |6 O*/
! Z# p; j, n) m* h$ G- Sis! m4 S3 T" p  \# ]9 }
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;& T, J% d0 F, m5 q. m4 p. o" A( N
do! ~6 U2 {) R( N9 S7 [- E8 f
        Lan := rootfolder.Internal.Tools.AOLlanguage;; T  j  o$ O' n
        if current = @.Destination -- else return! i8 e% H. A! D! t) v+ _. v' f
        then
2 N+ Y/ l2 |* ~( a                @.Destination := void;3 }2 l) Y' M, @+ J' J8 O- U& j8 T3 n
                if @.occupied then
2 Q+ w+ w: S1 A( ]* {8 `. p2 O                        part := @.cont;
0 w0 T  ]- ~; H( |" k                        @.transpOrder := void;
% }1 Q1 F( n+ q                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
& [# g7 M& t0 A                                @,root.eventcontroller.simTime);3 \) l1 d: A8 z& \3 H) m! {" h
                        @.HasOrder := false;: ?$ j% U# p. B
                        @.DrivingHome := true;( j7 y/ _+ q& C2 [
                        rgManager.tryToStartTransOrder;- {1 z7 _1 \# ]. P+ R
                        if @.Destination = void
! r4 u9 o$ f% a, B7 T                        then -- no transport order for vehicle @3 X) G5 k. r1 I8 y. n3 g- B
                                @.Destination :=
2 L$ q" w% b( ]7 Y7 I- ]                                rgManager.nearestFreeStation(@,track.~);
8 x+ G8 Y3 c' e                                newDirection(@);   ! I' M  k& j4 |7 E6 I
                                if @.Destination /= void then
. T9 ~2 i5 ^8 Z; Z9 N                                        @.Destination.NumReservation :=2 H# Z$ O# ?# t" n) L2 s* Y
                                        @.Destination.NumReservation + 1;* }% y/ |$ I( z( j5 H$ P0 [3 A$ X! b3 ~
                                end;  T; T3 X* r# F/ J
                                @.CurrIcon := "drivingHome";, E( a$ I' V- L+ m' c( r
                                @.DrivingHome := true;2 F1 G1 N4 h6 J" t
                        end;
) F, Z7 R# S3 h, D5 `- E8 ~# a                else -- the vehicle @ is empty, both vehicle and part are in the same dock station0 ]4 n$ ?4 a; V5 S0 e* t$ H, I3 }
                        part := @.transpOrder;  ?, ^7 P0 a9 Y1 R
                        part.move(@);-- load part3 e0 C9 X* j: K' s) E3 j) f3 _
                        @.CurrIcon := "load";
9 g' [8 e+ w: s1 {% i# ?                        GlobalDistObj := part.globDestination;$ e# z/ ?: g' h$ k0 u5 k. P
                        assignLObj := rgmanager.rgAssignL;
" V0 J0 L  P- ?' u: S, a* {, }                        row := assignLObj.getRowNo(GlobalDistObj);
0 }6 X) }' [% v4 z; [* r. r: e  W; U                        if Row = -1 then -- since 70
8 k9 z8 @0 S& D/ K                                if lan=1 then
' D5 o! r5 }" R6 C8 _6 e                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
+ k/ K3 e4 y# l4 w                                                to_str("in der Andockstation: \"",?.~.name,"\""));
( l5 {0 }+ C! R9 G4 J                                else
2 C' g0 T' M: \                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
3 A* b9 q' C: j# X2 P  w( L                                                to_str("in docking station: \"",?.~.name,"\""));                                2 P4 ^# J( d; E5 K( z9 S$ T" u
                                end;
& E2 K7 `* U+ b! g                        else4 n; I+ a% A) G- T
                                @.Destination := assignLObj[1,row];
, m( r# ?/ ^2 d- E1 A                        end;                       
8 A+ ~$ h: k! O2 i0 t                        newDirection(@);; f# c$ \% h. k/ J' `* Z
                        @.HasOrder := true;3 K- [0 k2 N" I0 E$ p/ k' U
                end;- j) X0 y" B4 Y7 [1 v3 t
        end;
8 P; g2 V; f- n$ m; C3 eend;        -- of the method
2 `) q2 W0 v3 X% ?& F# W3 }- b
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 , ?/ D' a! o* J; q
, ]6 ]( \, x) f% X3 c
这是AGV_putin中arrive的method。
8 h) U$ x. q# C6 d* @8 m$ |" J8 Y+ E& c% B/ ]* p; j
当到达物料速度越高时,这个报警更多,: a; @, B9 z1 M3 E; M
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。7 ]  a2 D+ N: f5 ?7 Y
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?- g! D$ A0 _% U- r1 y

" R$ C& I( y3 d% J( P7 @$ b# W另外一个小建议,就是move,所有的move都可以这样
1 ?) G6 j; x/ u, d. }1 F# c1 ^4 }if not move() then debug end
, I, P  [+ c" V: B" I; a8 q# w' j这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。2 y! S7 n$ f8 @8 `/ X  j& M
plant simulation中的free libraries有AGV模板,5 }( @/ F1 z$ @
里面也有案例。: J! E5 Z0 C1 }* R
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
7 _0 @  \' Z8 q- s2 Q
! w) b. B8 n8 l, j/ V0 V我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
. w1 _) w) o+ r7 }3 c* H
% }( L( J+ Q& m$ a3 j% V, W# H那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
9 K* ?7 z6 q2 x6 C3 ~2 b9 ~9 j这是AGV_putin中arrive的method。- v# ?0 T1 }2 ^0 Q' @( t* T3 N
1 P. D+ c# f7 T! B  h( k4 U0 f9 [
当到达物料速度越高时,这个报警更多,

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

本版积分规则

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

GMT+8, 2026-9-14 12:31 , Processed in 0.019075 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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