设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6057|回复: 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'
! s8 G2 U/ {4 j0 Z) A, l# @*/
2 k- E. g1 ?8 W* k: A3 ~7 Wis
* l6 @' [" [! _2 Y) P        part, GlobalDistObj, assignLObj:object;row,Lan:integer;% o  \8 e% p. p1 C1 y; ^- \& V  m
do
0 W1 |; t6 a5 F2 L2 w        Lan := rootfolder.Internal.Tools.AOLlanguage;
! t" i3 o! N" j3 i9 T7 F% t        if current = @.Destination -- else return
  g  I- x- b9 v6 o4 B5 N; t! u# ~        then2 D' h! P/ T% O4 d5 G
                @.Destination := void;
' L4 e, `, L, ^                if @.occupied then
/ Y: @) j: K5 m! E1 e2 {                        part := @.cont;: _+ v( R& [+ ]( E
                        @.transpOrder := void;
9 h8 Z& ]& E, a$ n' M( `                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,% F# f7 C, {! b$ B/ Y
                                @,root.eventcontroller.simTime);
* G) E  i+ E( K* f: @  h  J, T                        @.HasOrder := false;
, s- ~; H( O; F" z, J                        @.DrivingHome := true;
) X: T; I. \8 K* H0 n- z                        rgManager.tryToStartTransOrder;
4 \: ?! K3 f' G/ ?: e                        if @.Destination = void
. g6 c3 p; y1 @5 S( {- Q                        then -- no transport order for vehicle @: v) |1 l+ i5 d' ^3 A7 ]
                                @.Destination :=
7 ?' l0 U) g  P( V; k0 c; Z                                rgManager.nearestFreeStation(@,track.~);& ^4 H$ ^) i% r) z- c
                                newDirection(@);   
  N. h, \5 w/ }, R                                if @.Destination /= void then3 N! t* J0 G+ c7 ~" O
                                        @.Destination.NumReservation :=
4 Y1 \5 q& A8 c, A8 G1 B                                        @.Destination.NumReservation + 1;
$ F0 V/ R  k6 C                                end;
+ a9 s4 W7 j- S. `- \: W$ m* g7 B                                @.CurrIcon := "drivingHome";
# S# `& C0 X& Q! k* L- @; ~. e                                @.DrivingHome := true;
5 ]( c( _8 F- I  `/ `) P! @                        end;" \. ?' U$ m: d& T1 s# i
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station1 Z9 m* Y5 I# M% W7 N8 K
                        part := @.transpOrder;
& ?+ ?' E* ?5 D                        part.move(@);-- load part
% ~, \  Y! o5 t                        @.CurrIcon := "load";1 X+ Z+ R# x. {3 z1 F
                        GlobalDistObj := part.globDestination;
2 J. b2 ~* L( r" M* N  Q& k, D. @                        assignLObj := rgmanager.rgAssignL;% V4 U( o  f. G. S4 J& k
                        row := assignLObj.getRowNo(GlobalDistObj);4 C/ a4 r8 ]3 g5 g; x) a! Y6 |  P
                        if Row = -1 then -- since 70
$ t: W' ]; \" |8 ~. t3 Z9 j                                if lan=1 then/ W% Q+ D4 k% X! e) z" ]9 Y2 a
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
$ j5 d) P- K( D                                                to_str("in der Andockstation: \"",?.~.name,"\""));
4 u, @5 C0 k& p9 x  A                                else
# U5 {. ^7 y  o$ `9 q: w6 `                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),- T6 N* G  N0 E+ `0 `
                                                to_str("in docking station: \"",?.~.name,"\""));                               
& t. z  I4 }- n$ i; j1 t4 u2 v                                end;7 I1 b# u9 _9 z: u" t; g
                        else
! t4 c9 ^- @$ x8 y7 @) \                                @.Destination := assignLObj[1,row];& W9 E0 S: L+ ^+ o8 [) ^8 G
                        end;                       
8 j: L  g' k1 I, T( Z& ~  r( F' t                        newDirection(@);& D. S7 u3 P  ^: y; q
                        @.HasOrder := true;
* h" m: N# U8 M# {2 Q                end;
9 ~5 h4 H! T, T7 q# ~' u        end;/ P2 p. W. Z/ E- H8 G8 B0 R
end;        -- of the method
0 d) o3 q# t" [9 m
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ) |, ^4 _- q: }5 u, D4 ]) q' w
$ f6 U- L' ~% Q2 r5 C
这是AGV_putin中arrive的method。1 A9 R+ @1 C5 @
- ~# S7 \6 b. E# R7 k4 k: |- X
当到达物料速度越高时,这个报警更多,
9 x3 R3 F6 L  j7 Y# c5 g# h可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。3 n. U/ O: A( e
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
8 S( K1 K4 J1 U0 D; L8 B
8 s, K! a! e& n& Q; f9 E1 h另外一个小建议,就是move,所有的move都可以这样* [7 e2 Q% H/ j3 \4 t& U% i+ E
if not move() then debug end/ e* Y9 ~8 C5 |2 g5 H; ?
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
+ H: ], y) p9 `  s) nplant simulation中的free libraries有AGV模板,$ `1 j% F/ d# ?  r- t/ [/ \5 F
里面也有案例。
* W8 Y6 p6 ~$ t/ c* t7 N+ A. ~我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。( [7 G5 A4 b3 P9 ~0 o% [5 w, x
2 z) `( ~) g$ n3 T
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 1 l" [, M- _$ H+ G: A

# C! A& N+ l2 \5 {1 g' ]5 ]9 j那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
9 e2 [# B: m3 P2 T# k6 d) M这是AGV_putin中arrive的method。4 y" r# q- I2 E2 S

3 i, p& h8 j1 J7 c6 I+ n5 l! N当到达物料速度越高时,这个报警更多,

& S+ E2 o0 H7 |: K另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-15 02:27 , Processed in 0.019148 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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