设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5443|回复: 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'
0 k4 O2 _& H6 B# X*/
) e: K, G% [. V9 s! V: y7 Mis% s* ?" i  v& l3 f7 H
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;0 [9 N8 h" l0 K9 \0 S
do
- \1 s9 g% E: J6 X3 d        Lan := rootfolder.Internal.Tools.AOLlanguage;
9 H$ C2 M2 g" V' S# {2 x/ F* T( T6 R        if current = @.Destination -- else return
2 z2 Z" L5 u# @) ]        then1 W" A/ y; D* e( q/ {# e
                @.Destination := void;/ b  @. n+ U( S) g( I
                if @.occupied then/ \( }8 B, ]6 D6 ?) o0 s; P
                        part := @.cont;3 J# \& S  p5 d6 G1 h
                        @.transpOrder := void;9 |; M; f- K% K* ]
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
# A4 L: @  m& \$ X9 {- c                                @,root.eventcontroller.simTime);
9 K; ^9 {9 F% N0 d0 O                        @.HasOrder := false;
: a  c% K! ~" B5 \) W                        @.DrivingHome := true;, a4 p8 j3 t3 G9 Q- I& T3 d$ ?
                        rgManager.tryToStartTransOrder;
! s3 `* m* {: v                        if @.Destination = void
9 L& s' c! T% ^7 Z% P                        then -- no transport order for vehicle @2 z. E" U' _) ^" ]/ p/ F: q  G
                                @.Destination :=
" r5 b. r; R: B$ a6 J( I                                rgManager.nearestFreeStation(@,track.~);
! j% F" G/ l* W( V6 x8 Z                                newDirection(@);   5 ]: M% N/ R: k  c3 W, f6 @
                                if @.Destination /= void then+ d( K! |& y1 w/ v1 f9 f+ {# @
                                        @.Destination.NumReservation :=
; K/ T- _, N: T; l                                        @.Destination.NumReservation + 1;& ^' ]# t( c2 H& E% O
                                end;" K% N3 X& \- V+ L  l1 U1 |, g
                                @.CurrIcon := "drivingHome";
( c/ K. e9 d; z                                @.DrivingHome := true;
. u7 j+ f! t4 p+ u! K( Z% \# v! o                        end;
) l. T, P$ u  Y2 u' V                else -- the vehicle @ is empty, both vehicle and part are in the same dock station$ J- H! ^3 n3 w8 ^& E' f$ u5 H
                        part := @.transpOrder;/ H9 G% ~2 N: B$ R1 a* [$ I
                        part.move(@);-- load part
' S; n1 L+ X9 H                        @.CurrIcon := "load";7 i$ \# ~0 s5 |! T9 D: P
                        GlobalDistObj := part.globDestination;
# l; F+ C. m4 B: n                        assignLObj := rgmanager.rgAssignL;! S# b7 R" O) k* |1 ?
                        row := assignLObj.getRowNo(GlobalDistObj);) i% B9 B6 D0 F
                        if Row = -1 then -- since 700 ]9 p! b) c' p! A/ V
                                if lan=1 then$ O7 v/ [6 Z( c$ R+ A& f' @
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
4 Q1 R% Y. {5 i. @9 z* v                                                to_str("in der Andockstation: \"",?.~.name,"\""));
/ r6 p" ~6 I/ ]! p/ w$ z' i                                else
3 J- [: H: p5 V                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),/ G7 y% E8 k2 \: ~7 e0 C
                                                to_str("in docking station: \"",?.~.name,"\""));                                3 g: s5 U) L4 \
                                end;
' t- V# H0 b5 i( a                        else
( c& `2 y( y1 S- t$ [                                @.Destination := assignLObj[1,row];
; `, o8 |+ t# b1 Z9 W$ u1 m3 t% @                        end;                       
" D, M; q) c. W/ q5 r" p                        newDirection(@);
8 v7 K: P% m+ Z2 o0 r% |2 y                        @.HasOrder := true;9 V7 X' Y+ I; j- {- ?
                end;4 O! ]( O2 y, L4 [7 c9 {
        end;
5 x, i- u2 \3 J2 _, m0 {- b+ Iend;        -- of the method& h6 }' q0 w% D: C7 U9 I
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
' s- }3 @0 N6 p4 ?5 s" [* B: ]$ P9 `# u: E- l
这是AGV_putin中arrive的method。% `" \5 c% |" I# w- P

* ?! Y! Q( Q# t" c  p当到达物料速度越高时,这个报警更多,+ B7 ]% d- f" M1 e/ M2 R
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
$ {  [. J8 F( n0 Q  g程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
. [+ d; R* x$ N  t0 M
$ Y% H2 L% r. v3 N% P1 \- \另外一个小建议,就是move,所有的move都可以这样* M5 P4 e2 O% }; y
if not move() then debug end
* Q, i: {; }- G  i* P# N8 R4 o+ K这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
4 v! G8 Y! D2 U1 _% a! _5 j* j2 o5 V4 hplant simulation中的free libraries有AGV模板,' J, F8 k8 h7 `/ R5 Q0 M7 t
里面也有案例。
* `& J2 V$ n" ]1 J7 e% w% V我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。+ y: y* d) r0 ~! C' Q* x

$ ]7 ~) D/ _% G1 k' i' j我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 - S% @5 p3 O6 d2 F# l) g3 ]
2 `& p% k# c7 X$ q' @
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 2 x5 g: V4 U  e3 a$ `; h$ ~; y! C
这是AGV_putin中arrive的method。
) G6 I) h; f$ q4 Y/ I8 T8 c3 I1 a+ h( q0 s( b
当到达物料速度越高时,这个报警更多,

0 K) R: B+ I* {* g: }另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-11-24 09:17 , Processed in 0.016756 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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