设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7149|回复: 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'; k9 p3 B% Y9 w8 W4 K- Y
*/
: r* F. p" y) ]" {. @5 u" Jis
* _& p# o: h8 p3 U        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
. X# r6 _$ `4 s4 J+ cdo
2 p1 ~4 s5 O! ~        Lan := rootfolder.Internal.Tools.AOLlanguage;
7 ?9 b7 Z' v* E8 V  W        if current = @.Destination -- else return
& m7 V5 D+ w2 b. B        then
$ L6 o6 N: _. N. U                @.Destination := void;
8 [/ ?) l5 @5 T/ \7 J                if @.occupied then
9 f$ x1 j7 ]$ k% E. e1 n1 K                        part := @.cont;0 ?5 T: [. R; X! B
                        @.transpOrder := void;3 V. @4 f6 |, W. [& x4 ]
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,0 ]1 b1 I+ q4 z' W, `1 G5 B) L! \' z/ m* @
                                @,root.eventcontroller.simTime);3 X3 ^, y. L' u: N, b
                        @.HasOrder := false;
& r! U; T8 S8 V' R) w                        @.DrivingHome := true;
- K% C1 i0 a0 R4 E& L                        rgManager.tryToStartTransOrder;
- \$ j% h# H8 o' U9 R3 y                        if @.Destination = void
6 G7 z5 s4 H# x: A8 W# m# D+ U                        then -- no transport order for vehicle @
' ]3 d' e; F4 H/ ]4 j' E                                @.Destination :=' l: @, o2 h* ^- a+ k6 X
                                rgManager.nearestFreeStation(@,track.~);7 F+ m$ m* a; A. O; l
                                newDirection(@);   . G: `5 b1 I# i8 I; v
                                if @.Destination /= void then
  s- y% W; N# \                                        @.Destination.NumReservation :=
% U6 \3 [9 z0 e. J$ {" A  q                                        @.Destination.NumReservation + 1;# m7 H' e6 D0 u  A! e" Q, R
                                end;9 Y3 M* {, B5 M5 x& A9 V
                                @.CurrIcon := "drivingHome";
8 [7 E7 ~6 y9 n                                @.DrivingHome := true;1 h4 v  C5 _* f# I* G; b! E2 g
                        end;" ]$ R. `1 p. y# s: d" x8 A
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
9 M; E, w7 b3 T3 B2 o2 {                        part := @.transpOrder;
1 E% I2 V- `! Q7 B. |                        part.move(@);-- load part3 }" V- a& c* |; b
                        @.CurrIcon := "load";6 O) i4 T/ o+ O" S7 ?
                        GlobalDistObj := part.globDestination;9 H" W( s  o2 a1 l  v5 y6 _
                        assignLObj := rgmanager.rgAssignL;# l8 I  `" y& L% f7 H& b2 s
                        row := assignLObj.getRowNo(GlobalDistObj);# _1 ~8 p! D& [3 h& Z1 {
                        if Row = -1 then -- since 70
3 |7 K9 A( {% p" `5 q" y                                if lan=1 then
9 T7 U6 H% e' s8 N1 V5 a: Z( R                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),4 g' f  c( E6 h) e5 D4 J! `
                                                to_str("in der Andockstation: \"",?.~.name,"\""));. n* S% K5 R9 q$ U& L/ V% L" T
                                else8 i" t# G; k( A5 @1 x! U& G- _9 C
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
9 }6 O( I$ o% @9 M                                                to_str("in docking station: \"",?.~.name,"\""));                                ! B8 p; o0 Y' e' e
                                end;. k8 e) A$ d7 }+ v6 o; |4 O0 m
                        else( d% q+ F# {( X+ b
                                @.Destination := assignLObj[1,row];
) p0 R) s, J# R# J, Q6 b                        end;                       
( i$ C2 Y( D. |2 k/ k                        newDirection(@);  w5 C. T1 b3 w" f
                        @.HasOrder := true;
$ j" a# p$ H; C0 o                end;% l" G/ m0 y( c# ], P' G5 O3 O- |" i
        end;0 m  w7 e! j( e$ D% W, N
end;        -- of the method
- z: e" x! y& s) j7 N) [
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
* ?& x. v2 w" ~" |! V- ~
* N% P! B( [& V1 i( D5 ~2 e. I7 F% x这是AGV_putin中arrive的method。
* W9 o; Z6 e& F' }% Y8 S
: r9 T0 y) w7 a, \" {/ {/ t  F当到达物料速度越高时,这个报警更多,4 m  G* F4 v7 _/ r/ J
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。! I9 ?  w5 }/ K
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?2 D2 L8 S$ \  H0 L
* m1 c; k6 u9 q3 T) C1 l6 Z' k; K
另外一个小建议,就是move,所有的move都可以这样. n, S  ]3 m; S- Y1 ~
if not move() then debug end
0 M+ x# [* Y6 ?% ]4 P* O这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。4 N5 t0 E" \) ]
plant simulation中的free libraries有AGV模板,1 F; z, B- J$ a
里面也有案例。
2 ~# s: \4 I" O. m4 g' B5 p我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。# N) C9 @9 g! F) p: ?

! r, V1 j! F7 L) }' R* o% `我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 6 h6 f( [6 }( s1 G% i- l
4 ~( O0 {, {6 X3 W2 B; v# b  A$ d
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 5 O0 y- V! q5 {' i" \( d  i  J& T
这是AGV_putin中arrive的method。7 @  Y0 S) J& y* \- v9 {8 d
! G! f8 u1 m; i( o) [+ P! Y- M" r9 N
当到达物料速度越高时,这个报警更多,

2 M( N# l- z% s另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-22 05:42 , Processed in 0.021343 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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