设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7185|回复: 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'
2 k3 A% w, {& ~: T! b- U5 b5 |*/% [1 ?& m  ^, ~2 B6 P$ h3 y' F
is
' J( v6 f# A  f( w, I1 E9 b) s        part, GlobalDistObj, assignLObj:object;row,Lan:integer;9 V6 a) q2 |2 l3 H& w2 B6 H: q0 Y
do5 _: C$ j7 q( A* }
        Lan := rootfolder.Internal.Tools.AOLlanguage;! J; [. y+ E/ H! i6 u
        if current = @.Destination -- else return
0 j: I' c' M7 B0 H) S$ e        then
: U; D* l& @: X4 g" b7 l$ |3 `; o                @.Destination := void;
# C3 S- w" p# s8 p- V3 S& H4 n                if @.occupied then& D, U7 i: |0 x& B  @0 b% K2 {
                        part := @.cont;
' l, b3 @8 W9 K' i% X, L                        @.transpOrder := void;" U$ w5 t6 [" o; C5 f& g1 `* f1 c4 O
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,8 A7 H. h; W4 h
                                @,root.eventcontroller.simTime);% m$ P5 F. G6 Q; |4 i
                        @.HasOrder := false;
) K0 S6 Y" @4 j/ A# `' J7 s; D                        @.DrivingHome := true;
; L; L% O9 f( ~                        rgManager.tryToStartTransOrder;' h! ^0 @/ R& [
                        if @.Destination = void
/ h  t7 g$ K2 S# y# v% ~  t                        then -- no transport order for vehicle @
8 @* V' ~7 ]# }# o/ v, w                                @.Destination :=4 Z! y: i9 U0 V+ {( o! Q
                                rgManager.nearestFreeStation(@,track.~);
: B/ ^2 ?% d  F4 T" T                                newDirection(@);   % g3 V5 ~+ B) x7 u' I7 D
                                if @.Destination /= void then% ^: {! f# k0 D5 m. K, t4 f
                                        @.Destination.NumReservation :=$ m( V3 G$ q, H/ F! h
                                        @.Destination.NumReservation + 1;
- v0 d+ L1 }) Z9 c* U, G) _                                end;" N4 {  d7 F( s0 n
                                @.CurrIcon := "drivingHome";
. [$ K. d$ m9 K* w! {1 I                                @.DrivingHome := true;4 x5 ]) u& ~* [( i: D3 a& M5 u
                        end;  Z& h6 u( [) h0 l2 ^- y) \1 G
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
  E. x1 r! `, W: E# I0 \# ~+ w                        part := @.transpOrder;+ b6 G' W- e+ q) M
                        part.move(@);-- load part, N" S* _' E9 O4 {* P6 w
                        @.CurrIcon := "load";
" n9 i$ H  q( q% x" i                        GlobalDistObj := part.globDestination;
0 E, z" n2 p9 k* h                        assignLObj := rgmanager.rgAssignL;
  i) Y! _; k+ r* W: n                        row := assignLObj.getRowNo(GlobalDistObj);8 I1 e  R6 B9 m7 H% {; O
                        if Row = -1 then -- since 70
0 l1 W+ v# E5 d! k                                if lan=1 then( M9 P) u! a9 s. f
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
% O" q; m7 a, y1 w6 N) N8 q                                                to_str("in der Andockstation: \"",?.~.name,"\""));* e7 u% }9 ~- k
                                else; |3 H& m$ S5 |2 S
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),) Z5 D* ?6 _1 W: B8 |7 z, m8 b
                                                to_str("in docking station: \"",?.~.name,"\""));                               
# U0 F% V5 e+ y                                end;
8 s' _' M- b) S                        else  `0 z5 R! D8 x  L8 C, w6 u. p1 y" \
                                @.Destination := assignLObj[1,row];- e" u, V( u4 I/ q3 p6 w
                        end;                       
$ h, ?, e& `& a$ J  M                        newDirection(@);, ?$ W2 V7 X1 h  j4 p  G
                        @.HasOrder := true;
3 `8 C( K' S3 V  x0 ^                end;: s( i- n. ^# N
        end;6 H7 I. M1 e5 e1 L7 V3 |
end;        -- of the method, x. t3 ?: c5 X3 n9 s# K
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
3 }+ k+ R, {4 o! a) D7 R! e$ R+ E1 t! f  h
这是AGV_putin中arrive的method。
" u: [) f0 q* P5 ~) D- ^% E) h# K& ]7 l2 d* n& r
当到达物料速度越高时,这个报警更多,
  M! K( j8 P4 k# S: w8 g" i( b* y* E7 \9 M可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
( P' x! Q1 N- d, e3 X5 R程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
6 H5 I; F$ |8 C1 {
/ e( d% S( H& I; w8 u6 T另外一个小建议,就是move,所有的move都可以这样
* l. t5 W( a; Z4 }& d% A* Tif not move() then debug end
% e! A) j5 L* \8 W8 C! S+ O这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
+ \/ q5 A# G: i+ kplant simulation中的free libraries有AGV模板,: H6 Y2 G" _$ M: z
里面也有案例。
7 u% f- F# v) H我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。# d: f9 K( p: d0 D/ J9 v; |
8 ?! {: k8 b: {0 T
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
  x4 C9 Y. Q, z! x" V: q- o
" `9 R' b5 p$ B  L- P( z那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 , l  e) J  u( @& g( z  L
这是AGV_putin中arrive的method。
5 o7 X! C4 o& R6 A- h/ k! p. c* x, f7 ]+ ~; O& t) v1 _/ F) V
当到达物料速度越高时,这个报警更多,
0 `, p0 i' M+ o" K7 _1 T
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-25 15:27 , Processed in 0.019589 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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