设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7359|回复: 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'
! B( ?  m/ [4 {% p9 h' E*/. w3 N% b+ p& F( h+ ^
is
) J& N$ ^% _- T" I& c" J8 Q        part, GlobalDistObj, assignLObj:object;row,Lan:integer;5 j3 j) h* R. J
do% i2 @! s, P- f- M5 A2 G
        Lan := rootfolder.Internal.Tools.AOLlanguage;
1 ^" S. Z6 ?$ o6 J* A1 D6 U        if current = @.Destination -- else return
5 u# w3 f, R7 |0 T- `- ?        then
+ X5 E% Z( Z0 O$ g* M                @.Destination := void;; H, L( u  [8 a: E! V4 l
                if @.occupied then
9 m3 L3 I. a5 U/ G7 Y/ E# D3 i                        part := @.cont;
# H) E2 l- Z8 }+ t; W                        @.transpOrder := void;  r) z  P9 Y; P' @
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,6 Y" e- b: W8 z6 X& Z- J! Q
                                @,root.eventcontroller.simTime);
' v5 F$ n4 w3 ^/ h# V                        @.HasOrder := false;% n# A2 K5 P9 y/ T
                        @.DrivingHome := true;
8 l& [5 C' Y$ i- [                        rgManager.tryToStartTransOrder;
! Y- T3 T6 ?3 U2 {0 T9 d0 P9 g0 N- V                        if @.Destination = void2 h) {9 p+ y$ F4 J- |
                        then -- no transport order for vehicle @
* W! i2 t; d+ \. m$ f  C2 w                                @.Destination :=
; R) B5 c$ E% K( x; S$ ^' Y( y                                rgManager.nearestFreeStation(@,track.~);4 K4 R- K" t9 a5 g$ \- l
                                newDirection(@);   2 `% d/ X5 r6 v
                                if @.Destination /= void then& f1 Q, F& o: y5 u: [) W9 A
                                        @.Destination.NumReservation :=% e. N0 j* }# x( f" g
                                        @.Destination.NumReservation + 1;- ]2 R' [, O( i
                                end;: q6 r1 M& P$ k
                                @.CurrIcon := "drivingHome";8 P$ X. l8 x( i, p1 V
                                @.DrivingHome := true;
7 {9 m0 j6 Z6 q4 n; ]* H( A                        end;
8 R2 w% J+ K. b. X. L7 n$ _' g                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
/ P" A/ S4 A, L  N9 t8 ~                        part := @.transpOrder;
7 q6 X) K! B8 P7 [# A                        part.move(@);-- load part* t% H2 Q+ P; L* h3 q
                        @.CurrIcon := "load";# r& n. ], h8 g0 a6 F$ U) ~( [  v7 W
                        GlobalDistObj := part.globDestination;$ E" e. y* }0 Z/ X
                        assignLObj := rgmanager.rgAssignL;
* e6 f1 v( N" Z8 m% d3 _                        row := assignLObj.getRowNo(GlobalDistObj);/ z: A; F. {9 Z
                        if Row = -1 then -- since 70
4 x0 @" o9 n3 E7 A4 r  C                                if lan=1 then
' `, \6 {  e# N3 E: C& g                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),1 ]  V$ u. c" X1 Q: m
                                                to_str("in der Andockstation: \"",?.~.name,"\""));: _" Y$ ~) C+ E( w" a6 k5 n8 v' N$ J
                                else
: K3 p8 b) t9 Z; W) s( b6 K% s/ Q                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
: H3 R& h& a, l; O+ P7 B                                                to_str("in docking station: \"",?.~.name,"\""));                                0 B4 x% a; b7 C$ r9 j$ `# q( X
                                end;
$ {. X2 H$ n3 F+ c' a  H, e                        else
" @  _; a0 l6 |7 @2 e7 ~/ h                                @.Destination := assignLObj[1,row];
9 v7 X5 p2 Z; L( m. |2 \, D                        end;                       
* U: \  V1 j% Q% c4 f% r                        newDirection(@);% W6 `/ V, v0 l2 v
                        @.HasOrder := true;
! \) F$ G6 E9 K/ ^* G- ?2 }3 C                end;! s2 j/ ~* Q! Q/ j8 k3 G
        end;
5 h  c! E3 L5 rend;        -- of the method
" L# ^$ @) |- {' |1 ~' a) B
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
4 `3 {4 T4 r/ B2 H8 V
1 T0 @" @& H' Y5 C这是AGV_putin中arrive的method。5 ^/ |0 t- ~, W$ v5 D1 g6 p# d) M

) ]* y+ N$ h$ }6 v4 x4 w当到达物料速度越高时,这个报警更多,1 u0 P( g! p2 g$ T- j" m
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。  y. h" s" B  H, z
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
1 o5 x2 M' K( J' I' e
9 j" a5 d) r  J另外一个小建议,就是move,所有的move都可以这样- X. N# a0 h( D5 Q
if not move() then debug end
6 j0 o  [  }7 _( M3 q这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。8 E' U/ R6 k6 T  E- g
plant simulation中的free libraries有AGV模板,3 T6 l. V8 _. ^6 h
里面也有案例。- ?$ G: p* M* a
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。- `" o1 g6 C  w2 I

" f2 O1 W7 ~/ m我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 7 C5 X. g. }" a3 `

, U6 Y4 I4 g) ~# f$ q+ A那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 & R( @' b( D0 j5 T( w0 j( t
这是AGV_putin中arrive的method。' b6 N# A3 f& {+ o3 P
3 O* X3 b+ k- q  p" {
当到达物料速度越高时,这个报警更多,

; [; K/ X8 }2 M$ v% G另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-6 19:25 , Processed in 0.019615 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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