设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5992|回复: 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'- Y% }/ `1 ?) _7 T( [
*/
4 Q9 u7 A$ O( j0 U8 ~. g) ~is
1 C5 _/ r( F; r9 O        part, GlobalDistObj, assignLObj:object;row,Lan:integer;6 y/ W' H; Y! [  R) p9 @
do% v- ?5 _+ {/ t+ Q. J6 f
        Lan := rootfolder.Internal.Tools.AOLlanguage;  T: S6 W3 e; W& h
        if current = @.Destination -- else return
! M. Q7 p" ^: G5 m5 f        then
' R- y  R1 l0 D                @.Destination := void;2 @( d+ U) M- P# o) g
                if @.occupied then
) m, S2 Y( M, E' s1 w                        part := @.cont;
, }7 N4 ?& T9 y" ^! }/ C9 T# d4 X                        @.transpOrder := void;
) N, C9 r: y1 T, o9 R( O/ A! T) S                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
0 U. x, }8 [9 o4 A( S: }+ e# ^                                @,root.eventcontroller.simTime);
# ]) \& A4 ^4 v# W& n" W                        @.HasOrder := false;
4 W+ P# R- ^0 g* P                        @.DrivingHome := true;
$ A+ K# W0 E: V- }6 C                        rgManager.tryToStartTransOrder;
: k# M2 B7 ^- o# G; Y. l  y* H1 O                        if @.Destination = void8 @# d: |3 r3 b( o
                        then -- no transport order for vehicle @
3 U) v8 L. @% V* Y8 R                                @.Destination :=% I0 w; a, Y# J  r% y6 T; k
                                rgManager.nearestFreeStation(@,track.~);
, H5 B1 h, o7 c" G# \                                newDirection(@);   6 B0 n+ Z4 k# B# y% f% M% h, J/ r
                                if @.Destination /= void then7 J5 C; h9 E; o  J: o- z
                                        @.Destination.NumReservation :=9 Q# `! V% T% S( {
                                        @.Destination.NumReservation + 1;
! `$ {( s8 e" Y, W2 n, f' I, B' ]                                end;
2 I0 b7 H$ A6 Z; ?. x0 |0 {  Q. j                                @.CurrIcon := "drivingHome";
( F. W1 C* l' K3 m9 d: Y: _                                @.DrivingHome := true;; y) \0 x% t7 ^1 |1 s) C
                        end;9 N& ~* ^5 l$ j/ x- ?
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
5 c( H( K8 f; l                        part := @.transpOrder;2 \7 X9 X( R+ e
                        part.move(@);-- load part. L: W) X% {' S- f# }' }1 l% b
                        @.CurrIcon := "load";, m4 L1 r$ ^! z& f) b# r( _, O
                        GlobalDistObj := part.globDestination;
2 O6 U  S$ m, r: [# p  D                        assignLObj := rgmanager.rgAssignL;
, I: I9 C6 ^0 f. t+ d& `* [/ L                        row := assignLObj.getRowNo(GlobalDistObj);' T9 g/ A# p- Q% ]
                        if Row = -1 then -- since 70
: M  P$ l6 @4 _! ?! B1 m                                if lan=1 then! E9 p- a& W% c$ J( F; ?
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
6 `+ K3 u, P5 Y0 ^6 r1 I' _                                                to_str("in der Andockstation: \"",?.~.name,"\""));
) o0 }- ~! h. N. y' L                                else9 I1 I- E/ a( S" d) \. p
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
/ u. x! W7 P, q  |                                                to_str("in docking station: \"",?.~.name,"\""));                               
' j. y  A4 K0 {4 Y                                end;5 S0 v3 y) D9 |
                        else* ~7 ?4 U9 o' D; j# |
                                @.Destination := assignLObj[1,row];
* [" `. ?3 W) V. q8 ^2 K, \2 i                        end;                       
+ b; `* Y6 D+ V                        newDirection(@);) g  T7 }$ N; }# ^; M! m. k# [
                        @.HasOrder := true;- q! j& g1 j" G0 _# F. m
                end;
: z) ^+ R0 F6 _; D. P6 M: z: F' t/ e        end;% k1 u" P( i: \8 X, B! z" [
end;        -- of the method
& c: Y) d$ R5 p# i" x- ^8 d; L) O
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
: t" x/ F0 O) x4 x: I, J9 v" L" n! ?# w+ S; I
这是AGV_putin中arrive的method。2 s, v6 Z. C4 t+ z
! z" ^( z; j) K8 p- K
当到达物料速度越高时,这个报警更多,
, P4 u: s% U- a" `6 n& x可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。8 a) z: g1 b( t* C
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
% Z8 k! d0 S/ R" U, O: [$ k% {. x) s9 G" W5 @3 y- f
另外一个小建议,就是move,所有的move都可以这样( c2 c; H5 U; e" b
if not move() then debug end
8 k; |( G( X# ?. o. ~" Y/ ^# r6 u这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
9 ^2 M. i7 ^& M: L5 K+ Qplant simulation中的free libraries有AGV模板,
' l# \. O9 Z- e: D( x( z; U+ ~里面也有案例。. c2 X0 L2 D1 s& V* f( w7 B; T. i
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。, d( ]5 m4 ?' @  B/ Q' P
, d6 A& L: _+ G6 u2 @
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
/ z/ _8 y( {2 B7 [* \
/ d7 O1 h$ x4 h* }; h, Z那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 8 b5 k7 D5 M8 }2 N3 P4 O) R0 a) t
这是AGV_putin中arrive的method。
7 q$ N% \' M/ t: \$ a, `# P# h$ h4 }6 `2 b: V% `
当到达物料速度越高时,这个报警更多,
1 E. J# K/ N3 B9 K- d$ Z0 f
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-11 18:53 , Processed in 0.015840 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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