设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10107|回复: 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'4 |! r: u6 ]  n& S
*/
+ S4 t  Z" S& E" O2 @is9 N. F9 ~) o/ H5 N8 ^8 ~
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;7 D7 z; u$ i. s3 U4 e4 ^
do
6 d6 M* i3 N6 a& ?        Lan := rootfolder.Internal.Tools.AOLlanguage;9 j+ q6 j3 ?/ \4 q2 m
        if current = @.Destination -- else return% O' m6 z" e* B# B
        then
# Z$ C( w7 r4 W" W' X9 c% S4 T4 q0 h                @.Destination := void;6 S/ I/ F) u6 {2 R' X1 C. F3 O
                if @.occupied then7 S$ q% E/ e8 o& l. b7 M
                        part := @.cont;
. |# ~9 k5 n$ f  Y                        @.transpOrder := void;% p/ V0 [! _# ?, J
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,* {7 X8 O7 J+ `, X# D& y, m4 Z# e
                                @,root.eventcontroller.simTime);6 H$ u- @, Y, N0 N0 F4 [
                        @.HasOrder := false;
0 r+ @* Q: @. U, }3 a                        @.DrivingHome := true;9 g: C$ V1 }$ P1 B
                        rgManager.tryToStartTransOrder;
$ `7 ^9 C: e2 r. K$ i                        if @.Destination = void1 N  z- a& a1 v: _. [" y9 c
                        then -- no transport order for vehicle @
& K0 L* n! W2 ~) A8 X                                @.Destination :=
9 q* t: A5 M, x  O+ y$ o                                rgManager.nearestFreeStation(@,track.~);
5 I( S% Z; a7 Y8 s! h! V4 z                                newDirection(@);   ( C$ y0 h4 o3 o) y9 [5 w# c. Y
                                if @.Destination /= void then
2 Y; B3 t3 \& e5 Z                                        @.Destination.NumReservation :=
! V' m# ]: \7 \" ^                                        @.Destination.NumReservation + 1;
! ?' R( `; d. z, A                                end;
  _5 {! T6 X/ u/ r                                @.CurrIcon := "drivingHome";* a. e1 D1 |; M6 W* \5 a
                                @.DrivingHome := true;7 [+ u' E, @% O- Y! {% {
                        end;
. W8 B3 x* t2 {' ?; e2 c' Q                else -- the vehicle @ is empty, both vehicle and part are in the same dock station; Y# v8 o! |  t- r, P& m; Q
                        part := @.transpOrder;# d" M- v1 d7 X
                        part.move(@);-- load part
: x; w& W; j% s                        @.CurrIcon := "load";9 s/ b# U" V. R6 x6 Y
                        GlobalDistObj := part.globDestination;9 M; W- j) e; o  r- w" h
                        assignLObj := rgmanager.rgAssignL;- ?1 ~% {; e) T: H  C1 R
                        row := assignLObj.getRowNo(GlobalDistObj);! f& c% F& f1 v2 p* G8 Z) w4 i
                        if Row = -1 then -- since 709 |, v# G( t" r, X
                                if lan=1 then2 C3 h# V3 X7 f3 `
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
" N+ A3 s; `$ y# w                                                to_str("in der Andockstation: \"",?.~.name,"\""));
/ h4 N+ J& ^2 T4 ^; i                                else
2 Z+ q# S. g6 z+ R- D+ _                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
/ W. Y) M" v+ d; Z                                                to_str("in docking station: \"",?.~.name,"\""));                               
4 r) i5 o- A& ?                                end;+ Y6 ]% u- [# S+ O* ~, P
                        else
% I& ^1 a; S+ G0 g1 F  s3 c1 Z  d                                @.Destination := assignLObj[1,row];
& W, W; A+ z! O9 G. A                        end;                       
! Z' {9 C1 G/ w+ r% L2 c+ A& U% q                        newDirection(@);( K" [- K% r2 R/ r; C
                        @.HasOrder := true;' _( @  t( V$ F1 |' a
                end;7 |- s% |: E' S  B  v
        end;
" K; s4 R9 S* s& q% `end;        -- of the method
% C8 [* e+ U, n$ `; a6 H
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
* c+ U6 i$ t8 K- y: G1 y3 M+ f; Q& o
5 R' K) {4 v8 j7 m9 m6 y这是AGV_putin中arrive的method。
) Q8 [( M" D! n0 G7 J" j( U: |$ J
4 _& d9 v; [* a/ o4 p8 F1 [当到达物料速度越高时,这个报警更多,- h& m2 j. u" n
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。; u- l) z5 L. s& I" G  J( W3 I
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
' \" E& X/ i+ X; X/ I7 r  r
2 d5 l* ]% Y- ?另外一个小建议,就是move,所有的move都可以这样' w! s  p. ^% T5 Q5 F, s# ~
if not move() then debug end+ A7 L+ Y+ L! ^* i( m
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
) q1 {  x, I0 k/ d1 e7 D/ Nplant simulation中的free libraries有AGV模板,
/ {  A5 O3 c# b9 E0 ^: L7 o里面也有案例。0 @( Q! O3 I3 t0 U5 [0 w+ B
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
6 P( D! O$ k: b# k3 I5 `, d6 ?3 `
! H( ^  ~5 p$ w1 ~我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ! g; z3 n! V5 w1 Z& ]0 M. z# K

, M( I* M0 G7 f, T0 G9 [那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 $ o6 C/ O* y1 _8 c2 M3 G
这是AGV_putin中arrive的method。3 a) r6 Y, l9 |$ K: g& @% A

  E$ U$ d9 }+ W9 [* k" f当到达物料速度越高时,这个报警更多,

) O5 @" W- \6 C+ f- ]另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-13 20:29 , Processed in 0.020476 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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