设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9523|回复: 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'
: a% B# X$ [" y* o*/( u9 J9 k- e9 J6 {( l
is0 P, Y4 Y. O' e/ n2 {
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;+ Z. M( T/ O( i
do
7 H% h3 ^$ V4 u) E        Lan := rootfolder.Internal.Tools.AOLlanguage;
. M: M! S  P+ h# E  v% u        if current = @.Destination -- else return+ c( K' E' `+ c. c8 Y* i6 J
        then) g" q2 f4 J& k# C, j
                @.Destination := void;
8 ?5 O( ^. r4 Q- K5 f/ o                if @.occupied then
% s' e5 E; A, p9 _( o                        part := @.cont;
3 d* l; S7 X% I( I+ K2 S$ ^6 n                        @.transpOrder := void;
9 ~+ ^( Y6 N' X# O$ @- `                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,' I' ~. a6 K& \/ O. H7 U& _
                                @,root.eventcontroller.simTime);6 M+ g9 ~9 D6 c% m( M
                        @.HasOrder := false;0 C( d" u$ y. k
                        @.DrivingHome := true;" P' A) t, `! S
                        rgManager.tryToStartTransOrder;
2 D1 c! N/ t/ s                        if @.Destination = void+ b; n) V- [6 q$ \+ \3 H
                        then -- no transport order for vehicle @
# g6 e6 p* v- k% L* N& F" J% P                                @.Destination :=
6 {7 W4 s' w) ~2 }4 v6 T                                rgManager.nearestFreeStation(@,track.~);
' J, [. J( _& k' m/ g4 Q                                newDirection(@);   
- u; r0 Z2 b2 B                                if @.Destination /= void then0 A# i5 {. t4 Y; M3 s/ P* k* ?
                                        @.Destination.NumReservation :=0 k' ~; n$ R- o7 K& g4 D
                                        @.Destination.NumReservation + 1;* k  Y3 U$ R2 z3 q8 D+ g/ t& @/ m
                                end;
8 n- r) \3 Y3 e# E" J4 d                                @.CurrIcon := "drivingHome";/ f) @6 o3 B0 e8 c3 ^) C% \
                                @.DrivingHome := true;$ F8 D- I% v/ s  D0 P: @) a+ B
                        end;  R6 v0 g6 p1 ?1 Y6 {' J0 n
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
/ @& C, l5 Q2 J                        part := @.transpOrder;
9 x# _2 Z5 j8 f  x% s1 E                        part.move(@);-- load part3 s' ]( N$ i, @0 q4 z/ O  l
                        @.CurrIcon := "load";
1 l+ \/ @" f" `+ Z% Y/ R                        GlobalDistObj := part.globDestination;4 A0 r, U- `: p+ ~' ?5 I* O
                        assignLObj := rgmanager.rgAssignL;
! Z( k! b8 c( ^! I% A0 K                        row := assignLObj.getRowNo(GlobalDistObj);4 B1 q: W. F/ J4 X* o- K1 n
                        if Row = -1 then -- since 70
+ z! x+ S6 ^" S) ~                                if lan=1 then) f+ Z+ S6 Q7 r2 @2 O
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\"")," O5 i( ]6 Q8 ^. P- w4 L  t/ s% ~
                                                to_str("in der Andockstation: \"",?.~.name,"\""));& D# v1 b; \) f1 W! B
                                else$ }* e% ?3 R' d0 F2 P/ v
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
* g; B. a, C" T# M+ p* M                                                to_str("in docking station: \"",?.~.name,"\""));                               
* v, J8 w0 V0 @; a$ p9 y  l' W                                end;% h* s' w8 z4 H1 I0 _" s+ c* Q2 l( Q
                        else) f5 T  a% G  j5 A
                                @.Destination := assignLObj[1,row];8 G0 R9 r7 E6 ~$ t. @0 _
                        end;                        7 _) a0 J' K" U
                        newDirection(@);  H2 Y& K+ V( P3 U; ^  s( [
                        @.HasOrder := true;' h8 W+ L4 M  J" i5 j
                end;
0 f5 v) ]9 o. k( c- S* T/ T        end;
& ~( n5 a5 s- L* fend;        -- of the method
3 s3 x' Y) M) t+ ~1 G9 [
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
3 S  c. Q) ~5 J) j1 `4 Y$ Z! y/ U( L, Z6 R
这是AGV_putin中arrive的method。. }+ ?6 t/ y, a! U: a
: k5 f  N$ I( u! a' q
当到达物料速度越高时,这个报警更多,/ K1 L) @% m% h7 J
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
4 Q0 m0 H6 [; i4 K& A+ M程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
0 y2 r% m6 W4 {7 h% p6 g$ m
: @: |; E! ]+ @0 O+ P, S4 A. x另外一个小建议,就是move,所有的move都可以这样
; S* X* ?, ]* r$ _: eif not move() then debug end' l" Z& f6 b5 D2 e4 ^# q
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
* Q6 W6 \  ]. U4 z& _: mplant simulation中的free libraries有AGV模板,( }5 {1 F, B8 V0 v# Q. K9 k
里面也有案例。
( L8 V2 G0 X+ |$ V5 H我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。5 r* z/ J- _1 j
2 x5 p8 a$ o, y' ~
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 8 [) r- o4 g) D5 G- j
( f0 _% _6 d7 ^0 @
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 4 o0 N. [/ S, A  j( {* s* x7 i! K
这是AGV_putin中arrive的method。
, N* |! ~: ~: G: x7 o' x/ }5 v, ]5 t. C( L0 B, P
当到达物料速度越高时,这个报警更多,
# L" j6 D* F- n, `% |' A6 O5 A6 p
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-5 22:50 , Processed in 0.032483 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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