设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8883|回复: 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': v6 Y' z& o, I' I* S
*/
$ q# q7 A- h1 N1 o& i2 Dis
# y$ O" z6 v" p1 B6 a  M        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
: \. u$ R. k' U3 M4 @' E5 @do
% ~& ?6 t" f* @5 Z" x" y% m( M1 ?: _        Lan := rootfolder.Internal.Tools.AOLlanguage;1 b$ ~/ `) i. Y5 v3 t, [
        if current = @.Destination -- else return
- ~9 g& e* T3 z        then, ~) k5 V& j" k$ Y4 u; G
                @.Destination := void;
; ]- P8 g7 ]- B                if @.occupied then
# g+ r$ |7 s2 K0 C- \, W                        part := @.cont;
% I5 W+ z6 M( {6 e' r% Q% e2 J                        @.transpOrder := void;  m' [1 k4 p" U0 K9 u% U
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,. Z% k2 p3 {: v3 Z
                                @,root.eventcontroller.simTime);
( B( S2 D- m6 x5 A8 I" L                        @.HasOrder := false;6 q8 T! ?/ x: R, V& v6 B% L" _( R
                        @.DrivingHome := true;
6 q* \* g1 @" U5 u2 s4 K                        rgManager.tryToStartTransOrder;% t) G7 Y0 f0 s! O0 c+ @4 x$ q% b5 x
                        if @.Destination = void; U! V$ X% q( n- o
                        then -- no transport order for vehicle @9 v" T! @& Y- A# n4 P" B
                                @.Destination :=' x0 p2 E8 m0 R1 ^
                                rgManager.nearestFreeStation(@,track.~);. J8 U! E% S& i$ G7 a7 T
                                newDirection(@);   
" k0 a  J- ?# C" V3 H9 e                                if @.Destination /= void then$ x$ S8 p/ ^' k/ B5 v
                                        @.Destination.NumReservation :=& k/ S1 M: q  e2 R
                                        @.Destination.NumReservation + 1;& d1 [- o! [0 X8 Y! `
                                end;
& e( o" [# J! Q" g+ ~                                @.CurrIcon := "drivingHome";, {+ q& o$ k: Y& R. O
                                @.DrivingHome := true;1 b2 Y" O% a. M6 @3 i4 |& H. t
                        end;
* u) |  b# y8 u% U! A. A* F                else -- the vehicle @ is empty, both vehicle and part are in the same dock station. e! f! t' m' l7 Z4 n
                        part := @.transpOrder;+ {1 |% r0 l2 `" r* W
                        part.move(@);-- load part
9 T) \# c# K5 R0 }2 D                        @.CurrIcon := "load";
( i3 I2 V% ~  O2 n                        GlobalDistObj := part.globDestination;3 b" f1 k, @) J. w
                        assignLObj := rgmanager.rgAssignL;
0 f( }6 ~. [8 a/ \0 S  ^. z) v                        row := assignLObj.getRowNo(GlobalDistObj);
1 ?( M" o5 j3 x# ^( R; `                        if Row = -1 then -- since 70
, V4 _4 z& a0 j4 p                                if lan=1 then
3 u& F8 j$ {/ }/ `; O% }                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
2 d  h, M& p8 t$ |4 d/ G3 H) C6 A                                                to_str("in der Andockstation: \"",?.~.name,"\""));
, \, B0 w  ?7 a$ b, I# n6 j                                else
, V8 t) O; p6 H9 V4 T* P                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),8 D$ R+ \) R! K; ?( B% s
                                                to_str("in docking station: \"",?.~.name,"\""));                               
( f& a7 W# b9 ]% V: r0 ^# V                                end;
2 }( Z" L, N8 ^* B" w" h- r3 }                        else
7 t  m& m: n# v' S. c) v, |                                @.Destination := assignLObj[1,row];4 P; N  W+ ~( O# z
                        end;                        . j% j  s: B/ N) ~
                        newDirection(@);
; ?8 Y. S6 s9 x" t. \                        @.HasOrder := true;
! _. E/ R, x( p2 Q; R                end;' B% _, S: L2 h! s
        end;
8 X8 @3 M5 b* A# b. t. \4 Nend;        -- of the method
0 q" I+ |7 R3 {  F
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
, h, f6 R* K; U4 O  p5 n! @; Y! _, B2 X! [5 o
这是AGV_putin中arrive的method。
4 v! R4 N" u9 t" U, r3 {1 T% B! y6 F4 W9 _; d4 E
当到达物料速度越高时,这个报警更多,3 t  p$ v: J1 r  Y
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
. V4 E5 l3 X( H程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
& D6 K, J2 s% `- m" u/ R6 ], Y; v  Z2 [
另外一个小建议,就是move,所有的move都可以这样  H3 Q! m+ t% G( ?+ [8 i0 K$ g* K
if not move() then debug end
  H2 t& {, D% z这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
8 Y7 ]% l+ ]* z% O; g7 \5 {2 m2 K  H3 Dplant simulation中的free libraries有AGV模板,
& U) e8 @; v6 P' R' Q9 I, p( U4 o里面也有案例。% f. N* Z' u5 a/ d9 V9 g
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。& v& ~: k7 a+ T" p

  V5 S  m4 t! n, N# A我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
# ~; `2 i7 Q7 H8 o* h+ o/ c
# @5 ^/ c- N6 U3 x4 o# J0 f那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 / [) w+ t7 g; F  }0 C: `
这是AGV_putin中arrive的method。
* n% v4 g0 Z3 G: T2 h- v* a
( ^5 G9 E( A2 Y: g+ K6 q8 c当到达物料速度越高时,这个报警更多,
: j4 m8 z. Y& d4 J6 \( c
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-2 07:54 , Processed in 0.017284 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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