设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8259|回复: 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'; l, i: W2 _1 m- @; s
*// w, f: @4 x: C( f9 S1 o, _
is
9 p, r- C, |, K! k, F" |  ^        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
/ X! |8 Q( Y; x; r  S) udo
6 T0 h6 n  |' Z        Lan := rootfolder.Internal.Tools.AOLlanguage;
' e1 I/ ?* q* S% ~# v- i2 C        if current = @.Destination -- else return
! t  v: F( z% i! x7 O        then
  j0 V/ x4 j; ]# b- K3 q( @                @.Destination := void;
, |0 V  z! k: b: a! Q                if @.occupied then) A2 c+ t& Q, o6 }
                        part := @.cont;5 ?0 |) f( b" b3 S; a# d* d2 g
                        @.transpOrder := void;
# [+ J$ }  p! j- b( i$ S0 m! l                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
. y# ?3 W$ p& O5 `0 |2 k                                @,root.eventcontroller.simTime);
9 n7 o% z, Y$ f                        @.HasOrder := false;
$ H/ I: _4 E4 y' ?( R2 `8 r                        @.DrivingHome := true;
& `7 f$ g7 k/ `# @                        rgManager.tryToStartTransOrder;; t: h: ?* |$ [$ D. g  r6 O
                        if @.Destination = void) t. x, Q- s: q% u7 T0 I& _/ R
                        then -- no transport order for vehicle @
* x0 G* p+ k% M) c8 a* I' F* h                                @.Destination :=- n2 n7 _4 r7 n2 w
                                rgManager.nearestFreeStation(@,track.~);
3 G! z; _$ `+ X$ \* H; l5 R2 n                                newDirection(@);   
# C9 p- q! h  r( e8 ?                                if @.Destination /= void then
$ S8 [+ v9 h' ^$ Z8 Q6 w) R                                        @.Destination.NumReservation :=9 z" U5 p9 D/ D: ]  a1 N
                                        @.Destination.NumReservation + 1;
8 z% g# E  Z2 K; ~' f                                end;
' Y; C: {8 T! C( {' D                                @.CurrIcon := "drivingHome";9 K; |: ]3 w: \' T) t
                                @.DrivingHome := true;- \# B2 \3 m4 u' n$ o; k- d
                        end;
6 {' ?% c2 E' e% b# S. l                else -- the vehicle @ is empty, both vehicle and part are in the same dock station9 r8 m8 G! I( D2 ^. m3 R/ H
                        part := @.transpOrder;& X/ G+ f# Q: L; U1 ?2 K0 k
                        part.move(@);-- load part
! j: }0 I2 u1 G0 Y$ }* @1 [                        @.CurrIcon := "load";
1 m- ^& F* Z) C7 v4 V2 y/ q                        GlobalDistObj := part.globDestination;
5 r; q6 \7 u$ g7 ~                        assignLObj := rgmanager.rgAssignL;
/ c9 t: J$ R3 A. `! t                        row := assignLObj.getRowNo(GlobalDistObj);- O6 I/ [) m/ o  w: e+ b& A
                        if Row = -1 then -- since 70/ C: G" x) ^2 A- T% S
                                if lan=1 then
( O6 {, {+ n& k0 N                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),  [. \2 @$ b, ~" o
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
% v2 ~0 o7 N: X- i                                else
* c, c& Q3 [; |3 V0 d$ C6 i% e                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
  A) B* ~7 P$ W                                                to_str("in docking station: \"",?.~.name,"\""));                                4 ~- |# s" d5 }( S% X
                                end;
  v* p( ?* Y% P9 m% k7 N" A, A) H                        else( Q9 S0 u' F0 Z4 ]. ~2 }" O
                                @.Destination := assignLObj[1,row];
8 t7 n) z2 [$ t8 {( K! M: e                        end;                       
' B( [& m8 g- I                        newDirection(@);
2 a% o2 d. J4 z5 ^- W0 V                        @.HasOrder := true;
# ~( |! D2 z( G) [                end;
, m0 r1 z9 T% K" |; O; `        end;% u: n7 J1 n3 ~/ i3 }8 L
end;        -- of the method
& p6 f) K6 L% U6 D
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 3 g# Q) M; e) q3 {" D

# F, b9 ^9 e/ V8 J( K- m; M. J: F( K这是AGV_putin中arrive的method。1 q; y# z# D' L
- c* `/ R9 w0 a/ \; Y5 z9 S+ l% F
当到达物料速度越高时,这个报警更多,
+ E, ]8 E( g' p6 l: A& R可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
/ f/ |, ?: Z! ?) G程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?# G1 C* c9 }% [

+ q  t0 a" m$ c) r- y0 d另外一个小建议,就是move,所有的move都可以这样) X7 K4 t8 C3 F' L; m) C# F
if not move() then debug end+ j8 l8 ~  w# P
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。5 h# b. ?# R: D. ?# b& T4 m, i
plant simulation中的free libraries有AGV模板,
# N/ U$ k" A4 |* b1 f8 G0 U里面也有案例。
$ g% F7 a9 b1 u/ S9 E; O我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。, D. ]; }8 U" Q0 }$ D7 ]3 i
/ F. l- A% C( H; N
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
; O% F& a# t" Y1 _2 m$ g1 f" ?/ b% ?7 j: J# ~
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
# N. H) \0 H0 B# L9 a- }这是AGV_putin中arrive的method。* Q. W7 J* B% M1 s% k
/ _2 C( l+ ~4 y! J
当到达物料速度越高时,这个报警更多,

1 j2 ~8 y/ U% ~. N% F1 O另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-23 19:00 , Processed in 0.022360 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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