设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6721|回复: 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'
, X) L6 X/ Z0 r- J% K. Z*/' g2 M8 l6 ~9 L4 b- a7 R7 L
is
6 p- C7 w" O4 ^9 [" f        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
, ^; k  R$ ^0 Rdo! p; h3 K( s+ ?0 E
        Lan := rootfolder.Internal.Tools.AOLlanguage;4 ^+ U. I/ t0 C. Q% [0 ]! j
        if current = @.Destination -- else return
4 A7 d% M. T: m& W4 a7 A9 X        then/ a3 U7 F0 x1 M  ~) z  O# u
                @.Destination := void;3 H! j5 H- M( b  r5 x8 z: n0 v
                if @.occupied then# s. m' A8 q' t- A7 _5 q
                        part := @.cont;+ k& G4 Q: G( y; P. L9 O
                        @.transpOrder := void;
( A" p5 q' f/ b# w: X                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,$ P: z/ A) M  S, f7 b. ?9 g
                                @,root.eventcontroller.simTime);$ Z1 j  W( X* Z  D  m% f
                        @.HasOrder := false;/ ]$ Q# H& \3 C: L1 E+ @' y
                        @.DrivingHome := true;. n- U7 _% Y) P# P
                        rgManager.tryToStartTransOrder;
4 s/ s6 n- H( q8 _0 V  y                        if @.Destination = void
2 X+ y7 D7 G6 C% m  ?. b+ u& t                        then -- no transport order for vehicle @/ w$ I1 s# w; p9 c- P
                                @.Destination :=
  t% a. o, y+ H7 V                                rgManager.nearestFreeStation(@,track.~);
( `% [, d) O& Z# y: K( P( T                                newDirection(@);   , p# d4 B8 U% L; l+ k7 O
                                if @.Destination /= void then
( O! T& Y2 p5 K6 r/ B2 d                                        @.Destination.NumReservation :=& q3 R! S2 T8 ~  W# ~
                                        @.Destination.NumReservation + 1;
1 j; T( c! A, \8 b) i; S                                end;& p2 G  a! j1 E9 F7 G" W* V
                                @.CurrIcon := "drivingHome";
- B5 @/ I/ I8 P- l3 S$ {- Y                                @.DrivingHome := true;
! f9 H- |7 S6 ^' t) r                        end;/ s! l  K, Y! E, |3 b0 Q
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
5 R5 v) i8 C- S% P- g# Z( c                        part := @.transpOrder;
- u3 r1 Z# }* @! J  y  T                        part.move(@);-- load part1 |! K* {' N/ J: j+ T3 T  K
                        @.CurrIcon := "load";5 u2 q7 m1 i6 n
                        GlobalDistObj := part.globDestination;
! g9 q5 Y" x" K2 w                        assignLObj := rgmanager.rgAssignL;
7 g, R' E, R# T5 i+ n( W$ ^$ M                        row := assignLObj.getRowNo(GlobalDistObj);
% u' R4 E4 C8 w6 V6 d  c* z8 `                        if Row = -1 then -- since 70  O* l3 p7 ~( \( g; a, W8 O
                                if lan=1 then; A& r8 h0 z8 A( _( U
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
3 s. R0 y0 L2 x& ?( r                                                to_str("in der Andockstation: \"",?.~.name,"\""));
3 }% J' s9 z$ L5 c  o                                else6 u, g# B: d+ I# O. f- f6 }
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
; y! Y; h5 j: I# G                                                to_str("in docking station: \"",?.~.name,"\""));                               
# e3 l7 L! v1 c2 G                                end;, T( ]- s: A& [2 t- i7 N' `
                        else
! p$ I$ U& ~$ c2 H7 k) w4 ?6 m                                @.Destination := assignLObj[1,row];
( @: T; H9 \6 [/ V6 Z9 Q                        end;                       
8 F5 U, Q5 w  s) b) L9 n  n                        newDirection(@);* N/ I# @+ t9 J( k7 X
                        @.HasOrder := true;
8 v' O" C; y+ B8 k0 Y                end;
8 ?2 F2 r" X) A        end;
, Y; H/ G! w6 m4 K+ N- n5 _% ]end;        -- of the method1 y5 L! k4 J2 |
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
. p1 I' X6 C6 C6 o% [2 P+ k, A0 w  n. V8 _# T
这是AGV_putin中arrive的method。
  F' S- Z$ s, O; M1 l$ D3 C$ ]/ Z/ i. ?  Q3 a, e. I  @' f
当到达物料速度越高时,这个报警更多,
/ Q4 z: }) X9 [+ {5 O4 k可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
, ~$ O7 E7 y% K5 X2 z2 L4 K程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?2 C. x6 @( A7 ?5 T
  r" ]4 M0 O* f$ p- {) K2 L
另外一个小建议,就是move,所有的move都可以这样
4 g! l3 |' Q; j' P/ N5 xif not move() then debug end. J2 F6 f9 F$ A; y  K
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。% ~6 K9 ]! P5 \) ^9 Q% {; p. L
plant simulation中的free libraries有AGV模板,
0 W6 s& o/ j$ v$ q" T4 y; |1 G9 ~里面也有案例。
3 A' [& n' g9 \% a" f! R# C我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。  ~0 _3 t4 k$ s
9 m9 W; Q; L+ I7 Q
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 5 o  c6 L& V& F2 i" M+ N

0 X$ G4 Z+ U; g6 v- p5 F# a4 }) ]那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ; M7 |. U6 ?) W
这是AGV_putin中arrive的method。9 \( ^0 F: M# ]% ?$ q3 z" W

& P/ t( i' t, ~5 L当到达物料速度越高时,这个报警更多,
  _9 o) N& f- ?3 N3 P7 \/ J7 F
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-22 19:14 , Processed in 0.016787 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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