设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6141|回复: 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'8 u9 ]: C+ x- J' ?  K
*/
' L$ S- a! {" ]is, m6 u. d) O# V: _! R$ d' s- I) [
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
" c) u3 ]! x9 o/ C" ^0 hdo3 n4 d1 l3 M$ o/ X
        Lan := rootfolder.Internal.Tools.AOLlanguage;8 S) m( `3 V+ C$ ?6 u
        if current = @.Destination -- else return) Y9 d, C" V; d4 Z" h
        then3 d$ F6 y1 h: S. o2 ?7 I
                @.Destination := void;
1 z' _& G/ A; n# T* a7 y/ Z) H$ X                if @.occupied then4 i& G$ E( P& g6 o
                        part := @.cont;
3 J7 r! {7 e; F& h! l/ V                        @.transpOrder := void;
' q* O; N2 j. i) ^7 x                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
( ]9 P& f5 \% h4 M3 t8 M& s" Z0 g! H  z                                @,root.eventcontroller.simTime);$ r5 i. k% P' o2 K
                        @.HasOrder := false;+ d6 I" h0 s+ E2 c& }$ k( Y
                        @.DrivingHome := true;+ h( I! y! B+ ]/ X9 v* p6 [3 O
                        rgManager.tryToStartTransOrder;
+ T: F% n, y$ n                        if @.Destination = void9 s; O9 g/ ]! _9 r2 G
                        then -- no transport order for vehicle @/ T' B3 f0 d) C. v: }
                                @.Destination :=9 J: m; x& n4 \" N' Q9 p
                                rgManager.nearestFreeStation(@,track.~);
* j/ n* d: ^; Z4 A                                newDirection(@);   ! l( y) R8 p$ U9 n- T+ a& n) J
                                if @.Destination /= void then
+ E: X$ w' N# i$ q                                        @.Destination.NumReservation :=& [; V$ Z  E  l5 k
                                        @.Destination.NumReservation + 1;
: ?6 H$ j! i) L                                end;; M' n/ e; K2 c
                                @.CurrIcon := "drivingHome";5 R1 {, T6 Q0 k$ I! ^+ P" Z
                                @.DrivingHome := true;
5 S( W2 L7 }0 J6 p& R# P- W$ O# E                        end;
( ?  g$ @6 ?" n                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
5 q! n) }, [/ ~5 P                        part := @.transpOrder;& y& d9 X+ ~/ k7 C, d" s
                        part.move(@);-- load part
. @! {! k( @3 \$ ?1 j' U0 O# E3 O3 p' F: P                        @.CurrIcon := "load";. I* E5 T: s* u& Q
                        GlobalDistObj := part.globDestination;8 a" u" Z- O$ n% t+ P  c0 r
                        assignLObj := rgmanager.rgAssignL;
* U& I9 j* X: h- L7 ~                        row := assignLObj.getRowNo(GlobalDistObj);
: O, t4 m  a9 N5 L4 V' d                        if Row = -1 then -- since 70
9 s$ r. @, U: |# C                                if lan=1 then( O& V5 C: @: F' F; `
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
# b* G% }4 j/ \+ @2 I5 s' I                                                to_str("in der Andockstation: \"",?.~.name,"\""));- ?) m" U" H5 r5 P
                                else7 {+ ^+ t( `: x$ K0 }
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),! Q1 Z) y8 s& g
                                                to_str("in docking station: \"",?.~.name,"\""));                                3 t! Y. P! M* l2 o5 k# T% i% N2 i& \
                                end;" E: E9 w) ]% {' K
                        else$ A$ X, _+ B9 ?$ g! ^) R
                                @.Destination := assignLObj[1,row];* V2 k  ?# M: X! N
                        end;                        + C0 p  h. Z4 r2 n! x! x3 u5 U
                        newDirection(@);
( ~& T" e1 W. {3 I% L6 K                        @.HasOrder := true;8 u" r4 t# X( y7 ~
                end;
  ^( g3 f8 u; Q. q        end;. `( `& w: w$ Q5 E" G- d' V
end;        -- of the method
; C8 M* {6 U8 Q$ h
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
# G) k  `+ p2 \
0 r9 G' s& L! m1 o6 C; y% I0 q9 n# e这是AGV_putin中arrive的method。+ v# B5 H' ?! _) }* `+ u
& `9 u& z* e0 ^3 r6 |" B7 m
当到达物料速度越高时,这个报警更多,
0 x5 W" p/ Q6 Y" J; P  c" W  R可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。  a" P  i% r7 C& q! t( W
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?0 H- v9 j4 I# a% q' c' i( w

7 \: S" s$ E6 ^7 G2 G另外一个小建议,就是move,所有的move都可以这样
) {+ W9 a( b5 d1 M" x( Iif not move() then debug end; H% H) q+ S6 l& U2 a, t5 ^0 {! o* N
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。" ]- ~; W& G: l% [% q
plant simulation中的free libraries有AGV模板,
! _7 m' H2 o+ i. H9 d' _7 a' v里面也有案例。
  [1 M$ W; B9 N# A我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。: A; _' Q$ A) J4 k0 `: D

6 d. X; K3 F7 @$ f4 P8 j我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 , J) K! T% R1 t
# ~6 q* t# s7 n! Y1 T$ e
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 & O9 F( L, t: ^: F9 S  _4 n
这是AGV_putin中arrive的method。
3 P4 G& {2 K2 e8 ~9 j7 O+ [! ~" _7 {1 e( o5 x& I
当到达物料速度越高时,这个报警更多,
/ t$ w" l# F9 L5 R1 t  }
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-21 03:44 , Processed in 0.025256 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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