设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5789|回复: 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'
3 V5 t8 @; e( {*/
! b" @; _2 z( p9 x. |" O! P& |is
$ i( z" p. C1 s1 o8 R" H% Q/ R' Y        part, GlobalDistObj, assignLObj:object;row,Lan:integer;$ r7 R# I. \& }4 m% b. q% u
do3 _' L2 C! l  g0 M
        Lan := rootfolder.Internal.Tools.AOLlanguage;
1 u! I9 y6 c7 n2 ~" q" N. k- G        if current = @.Destination -- else return
. n8 F# Q# {' l  b* \; [* s        then0 |& l4 X! V, i6 _+ s$ u, u# H- K
                @.Destination := void;8 w4 d5 {& h$ ^3 V6 q  v
                if @.occupied then5 I5 x5 t2 `$ O1 o' s! O" q
                        part := @.cont;6 l9 C: D' h  q8 \) u2 ?* @9 x
                        @.transpOrder := void;
2 ^3 r3 w1 U3 G8 ~                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,1 o3 [4 r( J" d3 ]5 s; `
                                @,root.eventcontroller.simTime);
3 f# X- Z% ?' Z5 I3 H4 U                        @.HasOrder := false;
. x4 G# l" B3 O. u8 N& m                        @.DrivingHome := true;" @, P1 @8 K$ C) ?" n' g( }
                        rgManager.tryToStartTransOrder;
0 r. D2 H. b  E' @+ Q4 \                        if @.Destination = void! t9 {: v# r+ P
                        then -- no transport order for vehicle @: [1 H4 o* z$ B6 ~$ y7 M" _7 d
                                @.Destination :=# B2 X+ n) G6 v7 C4 Z
                                rgManager.nearestFreeStation(@,track.~);
: X; q0 Z! v$ o/ C                                newDirection(@);   
* b4 T' _3 W) q7 g1 Z8 o2 T# T% x                                if @.Destination /= void then
1 @' o. I, b- N7 t9 X                                        @.Destination.NumReservation :=
, }9 \0 q* i2 F7 y                                        @.Destination.NumReservation + 1;: R. a3 S& n7 S! D" o' O* F
                                end;
& {$ b8 U5 E5 W9 L, z, z! b2 X                                @.CurrIcon := "drivingHome";
! W' A* G* S2 e                                @.DrivingHome := true;6 d) Y- b! P) f
                        end;
$ M% o6 E) g( u                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
- N, T* b# D# k) `, ^. ~% X                        part := @.transpOrder;
6 y+ X  A6 l$ C                        part.move(@);-- load part
) r+ d4 ]& Q& H" m+ i                        @.CurrIcon := "load";
* Z5 @( r- `+ i" m1 R9 _! n& C, M                        GlobalDistObj := part.globDestination;
6 B  `- P4 h, O3 E                        assignLObj := rgmanager.rgAssignL;$ L2 T6 t4 u) f1 \( p2 u. w
                        row := assignLObj.getRowNo(GlobalDistObj);* R0 `9 I! E, K$ P$ U0 V/ q6 q
                        if Row = -1 then -- since 70
; r6 j8 Y/ H, f                                if lan=1 then
, [' s  \5 `( d& w. Y                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
7 I% n4 j; y9 y% }  L% j0 `7 W                                                to_str("in der Andockstation: \"",?.~.name,"\""));
1 K! H4 o( h, L) q* j7 \& F$ ?) @                                else
, u( n( X& c4 a                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),$ ]! ?$ y7 [( e$ A: ^. l
                                                to_str("in docking station: \"",?.~.name,"\""));                               
* O6 o) ~' Z4 f$ ~  b7 c5 V                                end;
$ u7 h7 E( V5 j, |! `                        else# y/ O* f0 c) t$ H) S. A3 g
                                @.Destination := assignLObj[1,row];
8 l. r. w1 i! i6 C% g8 B0 b0 q                        end;                       
* u( `' n: D0 C( @                        newDirection(@);  P/ `( R# z- v+ s* H
                        @.HasOrder := true;# ?( H' ~9 N3 }3 @. x
                end;* G* C) o5 s& I4 \2 G9 U7 P
        end;# [; R3 Q# ^+ a: [
end;        -- of the method
3 M5 W" X. w' N. y, w
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
6 {. u. X5 F+ W  A
3 z+ d% j/ V9 c+ E4 I7 k* O; G5 R这是AGV_putin中arrive的method。
8 J3 ~3 ~5 M6 t" `) k, g8 _" S1 T0 d; ?5 v) g
当到达物料速度越高时,这个报警更多," G  x% U/ B8 l6 f( i% @0 l- s  B
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
, g" q2 r) P+ k/ f/ I程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
4 g; A, A6 h1 U$ i* m+ j* O# H; G8 s$ M3 N. v: M& N
另外一个小建议,就是move,所有的move都可以这样. q0 M+ [# G0 d- B
if not move() then debug end
- _* p3 u, n, Q0 G这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
# U8 P! P5 {7 z0 J5 Q$ c- k% u4 iplant simulation中的free libraries有AGV模板,
8 ?( O( N( r$ j4 ]* A" c% [里面也有案例。
$ S5 N2 ~$ D' z* Y; Q我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。6 b, Z- v: |7 b6 C- C7 l
% S' A. g( O) q
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 : ~/ `' ^! U8 c. R; p

/ \" }% R$ b9 j* g: F那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 3 D6 ]. ^% Z, t$ n1 L, w
这是AGV_putin中arrive的method。
/ a0 k. o2 i1 C. h8 D* M; f' e. L
当到达物料速度越高时,这个报警更多,

; g/ q% Z9 K" q# L另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-12-21 01:47 , Processed in 0.017890 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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