设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6180|回复: 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'! D; J! \1 F  j$ Q' {. v6 k. M
*/
( \( J! [9 h( u5 N, His4 n1 j0 n, g, b& j& K
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
' g# t6 x) P& z" Qdo
* V7 r$ A2 R5 }3 }! U& ^        Lan := rootfolder.Internal.Tools.AOLlanguage;
3 H9 h8 T6 t5 `& H5 ]/ }        if current = @.Destination -- else return
, `3 n1 a' T+ D. A& n        then! E! ]1 P% }' e1 c! c
                @.Destination := void;2 L7 m# y7 u( W" ^
                if @.occupied then( F; }6 [+ J3 Q& W
                        part := @.cont;! `7 ^3 {! _; _2 m& u8 c, u! g! h# ]
                        @.transpOrder := void;
* Y6 G4 H% q# v4 Q                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
6 _8 n/ _, I7 R" ]+ N7 N                                @,root.eventcontroller.simTime);
3 U' y. n$ l3 y& F' ]+ g# L                        @.HasOrder := false;
% `) r8 e% I$ C/ m, m/ z                        @.DrivingHome := true;
. X! X7 s# R# d  ^  U                        rgManager.tryToStartTransOrder;
+ G/ c- h; Q( R( j# O4 Q                        if @.Destination = void
1 M: D1 o" h+ O/ ~6 d5 @0 s1 w5 f                        then -- no transport order for vehicle @
0 `8 D/ O. ?3 b/ B5 |                                @.Destination :=
7 ^# A+ R5 p! h( B                                rgManager.nearestFreeStation(@,track.~);
# [$ a  L, o. Z" C" W                                newDirection(@);   
* y  M' Q7 i- S% c8 B4 q6 L                                if @.Destination /= void then
+ x  D# a' t' v                                        @.Destination.NumReservation :=* |* i( D0 D+ \7 Y
                                        @.Destination.NumReservation + 1;! q3 M1 D5 W1 n- [
                                end;
! X% e3 \7 `0 X6 S% H. c                                @.CurrIcon := "drivingHome";" `0 }! r* V0 z
                                @.DrivingHome := true;
" C/ a. f% G* [$ Q' G. j0 w                        end;7 B; X& {, g) B8 @. l- [
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
! @7 A, Q: e& ~  H1 J* Y5 x' e                        part := @.transpOrder;
) o7 @, {3 T: p6 r, K4 `                        part.move(@);-- load part
4 I+ H+ b# H3 I# y                        @.CurrIcon := "load";" M0 Q9 J/ ^$ @! X8 A( h
                        GlobalDistObj := part.globDestination;5 e* k1 ^2 p# k
                        assignLObj := rgmanager.rgAssignL;3 a. u7 X: @  C; Q  q/ R3 v
                        row := assignLObj.getRowNo(GlobalDistObj);7 l  C: n/ n* @& ]9 l2 K1 ]
                        if Row = -1 then -- since 70
# u6 ?! V: g& r6 N8 f; o                                if lan=1 then; @! v1 n% o' s3 n% i
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
/ G( z" s( H, f                                                to_str("in der Andockstation: \"",?.~.name,"\""));- V4 ^7 g; n& v7 J
                                else
* I) E( Q' p$ g* y) L                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
* c* O  Z4 B5 i2 D/ x2 |% M; \                                                to_str("in docking station: \"",?.~.name,"\""));                                + D+ l" C1 z# f4 m) D- J8 u
                                end;% {6 k$ x: X/ k* D) i* l
                        else0 D% A2 ]$ h0 @& x4 `
                                @.Destination := assignLObj[1,row];
7 M0 ]) e' ~# q                        end;                        7 M6 k# }" X# J7 b( i5 [* S
                        newDirection(@);) X7 r' k; y3 G& ?
                        @.HasOrder := true;
6 j1 z5 Q* G$ O3 s% m                end;7 w- z. Y6 o5 ?5 C8 W
        end;9 k( V/ ^" c+ i7 h( m
end;        -- of the method& T$ e4 f! j+ [+ l. H+ x' n
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 4 g' _" x4 p. Z5 Q
( Q1 _! Q9 V: q3 T" }
这是AGV_putin中arrive的method。, n8 z; k$ R8 S, B1 W* ^

$ s6 \1 Z; d1 P; x, _5 r$ I0 ]当到达物料速度越高时,这个报警更多,) B7 m) r: N  I; P' d+ T+ N! q; p
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。: |" t! |9 Y, V6 @4 i: V/ t
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
9 K: V/ z2 x0 ]& I8 N2 L5 s# W0 o7 Q6 |* h9 r
另外一个小建议,就是move,所有的move都可以这样
' D7 g- ]9 M1 T1 Jif not move() then debug end
! P1 s, D1 Y; p6 z1 j: I这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
* W( j$ P4 r. D6 Hplant simulation中的free libraries有AGV模板,
; `# ~8 l1 {4 S# z( K- N里面也有案例。7 S/ p& M' E/ Y) D  _3 p
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
- d( @2 c; G0 {5 l! |7 Q4 ~
8 x1 j5 p6 e2 c. m; U/ B我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
8 u9 L$ P6 g+ }" ^) x
# K( ~# ]; U; f9 `. }8 i2 `那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
# w, R/ t% J* u8 r, V, l- v这是AGV_putin中arrive的method。$ \: A3 ~1 K( O# b  x5 j

- H& \7 j! ?( Y6 y# `6 e4 n( C7 x当到达物料速度越高时,这个报警更多,

8 h0 a0 P/ G0 x, f# z, Z另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-23 05:16 , Processed in 0.017505 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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