设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6877|回复: 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'
; F6 L  `' q9 t*/, m4 m5 Y3 J/ `4 N- j0 S
is" _4 v& p: |' T
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
" X; W; p) k9 tdo
1 \  F/ }5 S& p5 A; C$ `; v9 r        Lan := rootfolder.Internal.Tools.AOLlanguage;( Q; v- K% m' i& a$ I0 A  \8 m4 U! W
        if current = @.Destination -- else return
; O  ?: }" Z3 m* a        then
) \. n$ x# x  f                @.Destination := void;
* d& q- x( N% P. u                if @.occupied then; w# q# A3 U2 k2 l1 C' j9 b
                        part := @.cont;
: z) E/ S9 q- t                        @.transpOrder := void;
) o0 L* w- @( S  H  e                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,- |( M/ I. ?- q! n& z( b( G8 d; y
                                @,root.eventcontroller.simTime);
, h6 @" \4 F3 K- A% M8 t                        @.HasOrder := false;7 q. m/ E: @% ~, N- `. p
                        @.DrivingHome := true;
( B( _+ e. b9 q0 M                        rgManager.tryToStartTransOrder;
- s2 i# t" [" U" H# a                        if @.Destination = void( g3 _$ a" ]: j6 F0 W  j& f
                        then -- no transport order for vehicle @! H# X; I& ?# i0 p. e
                                @.Destination :=3 W! `+ q( p# g& b) u
                                rgManager.nearestFreeStation(@,track.~);
( a  T$ A' v2 j; r                                newDirection(@);   4 o8 K/ V/ e2 ~) ~9 t" e1 X& L7 ^
                                if @.Destination /= void then3 o3 h! M) @4 J+ U8 x; w( i5 g
                                        @.Destination.NumReservation :=
$ a/ ]+ Q$ q7 {7 Z6 ^7 R! W                                        @.Destination.NumReservation + 1;3 c4 l& z  U( [# C$ _
                                end;8 R. o7 F. E9 g5 X. `5 G, V+ I
                                @.CurrIcon := "drivingHome";
. J7 |$ W3 s5 n3 r) I& F4 C                                @.DrivingHome := true;  n9 o9 f" L- D/ B
                        end;
% }6 H9 }1 r# f                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
5 {( X# \$ c0 z% \* b- b% c" z                        part := @.transpOrder;
1 g2 j& t  ?* A) q                        part.move(@);-- load part
) y6 U# j) j$ m- ?4 E% v, v                        @.CurrIcon := "load";, y) I2 a4 ]' i8 l
                        GlobalDistObj := part.globDestination;+ {: k; l, t% f, h
                        assignLObj := rgmanager.rgAssignL;
  \8 L+ Z/ L1 s% P4 n3 x                        row := assignLObj.getRowNo(GlobalDistObj);
' @: A4 H( p2 Q# D                        if Row = -1 then -- since 70
! J7 q, l# L- r$ _4 y; ?                                if lan=1 then  {  W9 v, y8 ~9 C
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),8 K- m1 o- s8 g# G
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
8 J! }: ^( \$ K2 e" m                                else/ B% `, r2 s; E* f) Y
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
# \6 b3 C! J( T# R                                                to_str("in docking station: \"",?.~.name,"\""));                                * g% w4 X' n/ G5 j- v$ Z: d8 Z
                                end;
' e- i! _7 K4 \2 _8 P8 W3 R' I. j                        else( [4 u& Y$ ]0 w
                                @.Destination := assignLObj[1,row];5 l- j- f8 j( F& e( Y/ A: l
                        end;                       
: p! J0 r1 ~% S- |5 v                        newDirection(@);, `: E+ v; j8 J% [, x
                        @.HasOrder := true;  l1 b$ E4 f8 N. E8 Q- G9 Z
                end;( e- x8 G- E( [! F$ m  U
        end;" d% ~: @$ c/ V
end;        -- of the method8 U6 a2 ^. i7 r4 }5 `
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
' A/ ~! s5 a) h
) V: T; G  d- S% q: a! n7 _7 f  w3 @这是AGV_putin中arrive的method。$ `( j( J& h$ f# N2 {0 ~

! p0 W$ ?* `( m, K当到达物料速度越高时,这个报警更多,% @" G, |3 D0 y6 H5 j& D
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
8 }% k: a' L7 d- |  L程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
$ \$ j# o" o( q5 R/ J. s/ f! Q' `, A5 K8 m8 Y$ ~& P0 w
另外一个小建议,就是move,所有的move都可以这样
; E8 U# e% p3 \) m% Pif not move() then debug end
' ~9 [8 o6 Z  K) \3 D这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
! G  X5 U/ m3 @8 @( ?# T% @plant simulation中的free libraries有AGV模板,  v6 h& ?9 \. w' T
里面也有案例。
+ A" b/ G1 W% c4 w9 Y; a我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
0 g5 X7 H4 z( r/ R% Y0 P2 O
& o' P5 Q3 i0 A5 l" u, R; P+ F我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 . D; x) o# b( H/ y" k+ s7 j/ \" q
& @3 ^; f- s; b- N/ }" A% D
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 / n: [9 _3 M% L9 N# D
这是AGV_putin中arrive的method。& y! x4 \' Z3 z, L' ^4 a
1 ?' ]! w) [% W; R
当到达物料速度越高时,这个报警更多,

! U; M% x8 y" E* i6 x: Z0 N另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-4 05:06 , Processed in 0.023557 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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