设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9275|回复: 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'' i- Q0 m& N% v  i5 V- f, ?
*/5 c4 H3 X3 O+ B: A
is) x( ~+ X7 \! t( R: i% _; N" B
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
: P$ p3 M, |( X' ^4 Ado
2 I  `5 F! {- c5 _! ^7 C/ }+ `2 W: l. D        Lan := rootfolder.Internal.Tools.AOLlanguage;
$ {; p* Y) P  ?; |8 M7 F( P        if current = @.Destination -- else return. m& N# O6 t) H
        then
" q* O+ _0 W1 o( F9 m$ c  ]                @.Destination := void;& R1 r7 U0 l* M# C
                if @.occupied then3 T$ U  S5 E+ k) ~. E) [6 f
                        part := @.cont;
6 `' ]1 O, w1 @+ r/ `+ i% e& {                        @.transpOrder := void;2 X! Z" Z0 x; a3 [, d( T! Y
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,1 L- Y* E/ U/ O  u4 g5 |
                                @,root.eventcontroller.simTime);0 {( ~; g& Z" m3 ^9 e
                        @.HasOrder := false;+ Q# R3 Z' ?7 v& {. D! K) ^7 v- F
                        @.DrivingHome := true;+ s9 t: M, S. h, X
                        rgManager.tryToStartTransOrder;
6 G! R9 R$ p4 E! l                        if @.Destination = void
8 }+ _. c; t: O, a3 r                        then -- no transport order for vehicle @
0 ?4 ]5 x9 a8 ~8 r                                @.Destination :=- Y$ n/ W- e( \# I7 V( F
                                rgManager.nearestFreeStation(@,track.~);" A! i4 a0 a1 |7 R  ]$ {
                                newDirection(@);   1 v" m3 D- p6 T  O, a& e/ E
                                if @.Destination /= void then* }' M" r7 `2 B0 S- c. [) `
                                        @.Destination.NumReservation :=% [( _0 F' I2 W: c2 h
                                        @.Destination.NumReservation + 1;
& l. n  M! b4 J; ?  t                                end;
! c% m( [, Y1 h8 e4 P8 O. ~                                @.CurrIcon := "drivingHome";
' Q+ J4 A3 E/ e                                @.DrivingHome := true;
' M( I  {0 c, I( S                        end;3 L% y) O# X. z/ v9 s4 L5 @
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station) [' j0 X+ ?" _: R# d0 R9 C
                        part := @.transpOrder;) |& P& p9 A8 S/ M$ N1 q
                        part.move(@);-- load part$ W/ i- c3 M! A% o; T' V% |
                        @.CurrIcon := "load";
" a3 O# a4 k9 S                        GlobalDistObj := part.globDestination;+ r8 k' p/ A0 x$ M* N* g( e
                        assignLObj := rgmanager.rgAssignL;2 E" b* ?$ G4 x) F1 h+ s6 v8 |
                        row := assignLObj.getRowNo(GlobalDistObj);0 l+ w! n5 _% y9 `4 T
                        if Row = -1 then -- since 70/ s7 V- M6 ]# [  m4 ~1 r( y
                                if lan=1 then
( S7 ?" O! M5 g. u                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),! c0 w% b* c2 _" F2 x* D
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
% Y+ T$ U' d7 C) r8 `) {4 S                                else
0 y' n# r, h7 R- f" L3 H                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
6 P9 \9 e& a9 i: F, l8 R                                                to_str("in docking station: \"",?.~.name,"\""));                                : i2 }% h' k" N3 X
                                end;" M5 s  Z8 D3 y5 u( X! d; E
                        else# w- X& @6 k8 Y( \7 ]1 ]$ C  p- Q
                                @.Destination := assignLObj[1,row];
( [- r1 k2 n/ L                        end;                        ! ^9 h2 X; z4 o6 _' P  e: o" Z
                        newDirection(@);
/ L7 i, l1 {! P: o, X% O                        @.HasOrder := true;7 [  N7 F" @% y% f) u9 k
                end;
8 z) g2 }/ C9 ^) x  S6 B9 z        end;1 I8 V. p& P, @( |* y
end;        -- of the method
/ s" b$ r0 O; Z
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 0 U% `; c; O" j
+ I8 ?) r5 ~, ^8 z
这是AGV_putin中arrive的method。; @  j+ X+ k5 M& U) ?

! T/ m" G8 e2 u6 ^1 s当到达物料速度越高时,这个报警更多,
. g' A" @: y' x! e0 E可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。( M* r# i8 L4 h9 f1 K
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?, q2 ]1 P) W( P4 @6 a5 K/ q

! R7 o4 G3 U6 Z5 @2 U1 _0 \另外一个小建议,就是move,所有的move都可以这样
8 i; _+ Q- _% Rif not move() then debug end
. v( K6 u8 d/ k: H/ {这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
# r2 ^3 k5 p8 ^- Dplant simulation中的free libraries有AGV模板,+ I7 y$ P; n' d2 C# s  i
里面也有案例。' P" j" Z% U0 k6 S
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。0 T0 _3 a! Y* ^  A5 k- t

8 A/ o) i, l0 o; c+ q我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 & i& i+ C' S, h% b  W

8 y5 X8 R, B: ?6 p5 i# |那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
/ T* _1 b" f4 R+ F& @6 O这是AGV_putin中arrive的method。$ A. m8 c$ @( y! |
% l/ f, N+ l; c2 \5 y8 P
当到达物料速度越高时,这个报警更多,
. ]2 s" Y) k. e8 g" D& i$ T4 A
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-22 10:13 , Processed in 0.016558 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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