设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8482|回复: 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'0 p- X4 S: u' N2 y- D& w8 P
*/: z: |& D! `# }& d; [
is1 M' l  M; \% i& Q; X
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;6 d7 N5 _: X9 `1 K7 j
do2 Y; Y- h' n5 C
        Lan := rootfolder.Internal.Tools.AOLlanguage;
+ k" W6 _' L9 Y' U        if current = @.Destination -- else return
) x6 ?$ R3 _* C: C        then  Q4 |; ^1 M- `8 k( L+ U8 Z' `
                @.Destination := void;
+ ]* x( [$ o$ F3 o4 n: D5 _: Y6 E1 m                if @.occupied then6 O" z+ Q, X% R
                        part := @.cont;
' |: z( @5 N: m1 ]                        @.transpOrder := void;
6 T0 D0 z: h. r# c* a- \                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
5 [, [. H+ T# }5 F7 w1 ~# _# M' j                                @,root.eventcontroller.simTime);8 i; l, s7 n) a# \6 z, ]6 b
                        @.HasOrder := false;
9 U# |& b8 A+ P- f" V8 i                        @.DrivingHome := true;
, A$ C: ?. w+ M) [                        rgManager.tryToStartTransOrder;
3 o- E* [) _+ V. W! {2 O( [                        if @.Destination = void
! t% L8 I: P! m  p9 @! g" |                        then -- no transport order for vehicle @
! @* B' v- Y: m4 m" i                                @.Destination :=
. ^( m# X$ W6 k. a                                rgManager.nearestFreeStation(@,track.~);
' E: g9 A& @- l" A) }# P                                newDirection(@);   1 a5 R& ~, f7 E" K' l9 [
                                if @.Destination /= void then5 m; A6 U  W3 q5 p
                                        @.Destination.NumReservation :=
# N0 |2 F( K9 Y7 t! k                                        @.Destination.NumReservation + 1;: V: Y, g4 j3 l/ |8 [
                                end;5 N! M( G3 @4 u9 D( N
                                @.CurrIcon := "drivingHome";! ]- ?+ e) N% K$ d3 @! i# _. X
                                @.DrivingHome := true;/ q. R# N8 u: P7 g" ~
                        end;
# {4 S7 {4 K  ~                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
% g) W. `1 q" N' Y, H: s4 D                        part := @.transpOrder;9 U/ Y% h1 S9 `, ~
                        part.move(@);-- load part& t7 e" r5 h. O" t, w) ]) s
                        @.CurrIcon := "load";
0 K7 n- X/ a( T- f4 `' ]& p                        GlobalDistObj := part.globDestination;
% g% `8 q/ Y0 N( p/ n! `9 N                        assignLObj := rgmanager.rgAssignL;
* `/ p# E8 `. T- \% {                        row := assignLObj.getRowNo(GlobalDistObj);# X; G, i& ?8 {/ n4 y* Y0 N( x" L
                        if Row = -1 then -- since 70
7 m# q/ \! B3 |$ c                                if lan=1 then- i: x9 f! V3 F% G
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),# s. z" O. V  |2 S7 X
                                                to_str("in der Andockstation: \"",?.~.name,"\""));- M- `7 b- B! X7 V
                                else% x* \2 t9 j! ?) i6 U
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
8 F; O  f5 \5 {/ {+ h( c% N5 F                                                to_str("in docking station: \"",?.~.name,"\""));                                5 S  w- A" G( E/ C
                                end;4 V) z, T8 U4 F9 W) J
                        else8 W# i1 i$ B0 D2 a4 K- t
                                @.Destination := assignLObj[1,row];
  a/ X9 Y9 L) U8 ?/ q" @' _& y                        end;                       
/ `4 S* J" D: d0 y                        newDirection(@);. s9 J/ y3 s$ Z
                        @.HasOrder := true;1 h: j8 Z. Q# D; H8 E' s
                end;, Q, P! F% t- j$ {
        end;
9 a! A6 y; O2 e/ R# Lend;        -- of the method
3 D( M* D6 B$ D* F5 A- F
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 - p# U4 O9 D. ~2 K9 z# p* y

, W9 h- Q! K! v5 l: r# G) v这是AGV_putin中arrive的method。5 }5 Q3 Q6 |/ E: g4 X

8 e- H/ H3 j, Z5 |5 k当到达物料速度越高时,这个报警更多,
; \% C# D: ?/ s可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
8 E. B. i5 a" n& ~程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?+ @  A9 e- M1 N% G# H. }

- \2 ]) u+ a* q6 G2 q8 Q0 ]8 C另外一个小建议,就是move,所有的move都可以这样4 D# ]* M0 A+ }' B, I& i5 Z9 C" U0 T* m
if not move() then debug end
$ d' W( D  \+ y, U这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。4 R* s, D5 x7 \, W
plant simulation中的free libraries有AGV模板,
0 ~. Q% j+ ?" d/ g里面也有案例。$ l. X: i. n: ^; p. d# S
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。( C) O7 C$ D* L$ ~
/ j! I1 B2 e2 u, r' f3 R  f
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
& Z' ?" U8 F2 T  y- q( W& a8 |! _: d) A( i6 l
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 $ W* V4 S3 c4 u( Y4 z
这是AGV_putin中arrive的method。
9 R1 \) i  l+ @9 m: ^) ]0 M; [& A& Q& t7 {! j0 [5 ?; `0 S2 w
当到达物料速度越高时,这个报警更多,
+ X1 f; F' x; h% {
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-6 15:03 , Processed in 0.015282 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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