设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9310|回复: 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'1 S7 z8 t- A& w* x" z1 _
*/* v$ e4 `# C: s0 `) _$ z
is6 P& w  V) S; @
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;, E! r) B% }2 z) Z
do
# [0 O$ a$ V/ e. m: x8 J        Lan := rootfolder.Internal.Tools.AOLlanguage;
+ X& I3 t* u+ X  o/ v3 A        if current = @.Destination -- else return' x$ N7 ?* {* O& A" ?
        then
# [1 k: |& v1 \                @.Destination := void;
% |8 x4 Y! |9 S) ^2 N! \! i5 i1 Q                if @.occupied then
6 d. a  h, W* s- ^                        part := @.cont;
5 u4 V5 ]) Y9 `7 E' }$ r  c                        @.transpOrder := void;
! ~, P# |  V: w; `4 R                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,2 |9 s  D9 g- F& V
                                @,root.eventcontroller.simTime);4 m, K' A8 E- b4 x
                        @.HasOrder := false;
. Q8 a' `/ ^8 ~# s4 f& A9 D& x5 z$ _                        @.DrivingHome := true;! x. ]$ u0 r$ n/ Q1 `* b/ J. p# l
                        rgManager.tryToStartTransOrder;/ d' a0 F( k6 D" ~
                        if @.Destination = void# J, I; }# m2 {+ }4 ?
                        then -- no transport order for vehicle @
* l% T8 @, f5 K' l$ P                                @.Destination :=
" r) G) D7 f* Q% M0 m" C                                rgManager.nearestFreeStation(@,track.~);
, p& Y5 V2 d5 `0 E7 i/ c                                newDirection(@);   ! y# R! _( p1 f  Y
                                if @.Destination /= void then
7 a  A5 m9 y' g5 i- _/ M6 f                                        @.Destination.NumReservation :=
$ q0 T5 x( U4 c                                        @.Destination.NumReservation + 1;. D) p# \+ d1 O
                                end;5 f, ~9 F0 ^, D7 m# @
                                @.CurrIcon := "drivingHome";8 p6 \4 Q& x$ |6 I& z$ O! a
                                @.DrivingHome := true;3 V3 \' K6 O( ?9 e% d8 l+ K7 Q/ q
                        end;2 ?/ S: x* W- j$ J  K+ M' F2 }
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station! ?5 }3 M; t4 r0 W
                        part := @.transpOrder;& u$ t( ^4 |* [0 f
                        part.move(@);-- load part# D6 \7 m) c- b% ^' e
                        @.CurrIcon := "load";
- J# V( t0 S' a* A                        GlobalDistObj := part.globDestination;" \4 X" |! Q# `4 D, Q. F
                        assignLObj := rgmanager.rgAssignL;
, l% D+ W. ^* v                        row := assignLObj.getRowNo(GlobalDistObj);
8 U! b6 S) R2 z+ [) z6 y: N                        if Row = -1 then -- since 705 V, B" _7 e) t
                                if lan=1 then7 K% ]) g) z: L5 D$ \
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
" F! F2 h# {7 d! d) V" a+ A5 j                                                to_str("in der Andockstation: \"",?.~.name,"\""));
) X" M* j) }. c                                else
$ b+ e5 k' d* s) d9 q9 O                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),1 @7 z5 T. F; x, i9 m
                                                to_str("in docking station: \"",?.~.name,"\""));                               
9 r3 U8 u% j7 a1 t                                end;
( J3 ~/ r! G7 C% u9 i! \                        else
' Q- d9 f- G" c& V9 {/ b                                @.Destination := assignLObj[1,row];/ C( J& ^- f: u; L7 [0 L: p# D: A8 ^
                        end;                       
1 ]7 h" h1 x$ N) q+ X- ?( N& v3 X5 M                        newDirection(@);
1 j: t/ w8 c& M* V+ f5 P+ h; y                        @.HasOrder := true;- g3 a# \' ^* G4 S  Z
                end;/ \: v$ u: I+ I
        end;
$ o6 L- n- T  T8 w$ x. \end;        -- of the method. P7 n0 r! U! ~( c0 }* y
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 4 [, P2 H* _- q

, M" \% Q2 s; {, l; x# U这是AGV_putin中arrive的method。
4 A8 S6 [2 W, G2 i" L; v
$ x( Q3 i( a& s, B" ]当到达物料速度越高时,这个报警更多,/ I5 u- a( B; Y4 L7 C8 O
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
) [1 s; \% E9 @- g+ U' [程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
0 J1 J' Q$ T# Y7 ]2 f
2 L$ V- C4 p9 K" S另外一个小建议,就是move,所有的move都可以这样
3 s- |8 V  x. Hif not move() then debug end
, Q+ T  \1 P7 V% @! V1 Z1 x9 e这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
. e# f1 T4 h$ W- l6 kplant simulation中的free libraries有AGV模板,
5 ]/ t  ?3 ?- y5 F. d: S* P里面也有案例。
. C6 }5 j2 X- F; Q# u1 b我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
+ }( [3 _5 T" \" i4 u6 ^* @& |( o* y7 O) o: p# q
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
3 l# p9 O% ]; I9 n9 z- `8 _7 I$ Z7 a4 m+ q# l0 Z
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 0 B% a9 D  @) Z4 I4 Z+ g' e4 L
这是AGV_putin中arrive的method。. d2 H8 L' }8 Y1 v/ D

4 |1 q0 ?. p  v1 N" J当到达物料速度越高时,这个报警更多,

1 B: V4 N9 p) D2 w& {3 t# q! r另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-24 16:59 , Processed in 0.016460 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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