设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8133|回复: 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'
. @9 h9 w7 g" H*/
& r: J# n. k  }& z' F% ]is: ]! @  R" d+ W- e4 @# R) Z
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
2 A8 P% i! h+ N0 wdo
9 f) W; q- w0 E% z; \, l        Lan := rootfolder.Internal.Tools.AOLlanguage;
4 r1 h! J3 F/ \& n        if current = @.Destination -- else return! V/ [  W" n; J' M0 h# _
        then+ T8 y$ X$ _' `" o" E. O; v' y8 ?
                @.Destination := void;
. o/ \7 k% G5 V                if @.occupied then# Z8 a5 z* k6 }1 I; ?
                        part := @.cont;
9 E5 |0 G7 W3 L                        @.transpOrder := void;
1 e# B' k4 u" S  v+ P1 W9 F                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
, @& A2 d3 I8 C8 ]( y' G4 @/ }1 f3 W                                @,root.eventcontroller.simTime);
: B5 ?# `& w  l) S: L5 C6 j2 U                        @.HasOrder := false;
1 V4 ?" q0 B* U; H# ]9 U                        @.DrivingHome := true;
+ o3 {' r0 p1 G$ J% D                        rgManager.tryToStartTransOrder;
9 u3 z8 |- N8 A4 }1 N3 a                        if @.Destination = void0 L; k7 F1 A$ }" B* E, |9 v3 M' I
                        then -- no transport order for vehicle @, Z  `9 }3 G# h" e5 u$ y5 }
                                @.Destination :=0 z. }, a* ^) B. a
                                rgManager.nearestFreeStation(@,track.~);1 [" N/ g5 E$ |: W. R4 E* C# g
                                newDirection(@);   
) q5 g0 ~) A: T5 y  A% _                                if @.Destination /= void then
9 O0 I0 ]# R1 ]                                        @.Destination.NumReservation :=( f% I% Q3 j7 ~" q3 N9 s
                                        @.Destination.NumReservation + 1;
) [' `, U5 k2 G% W4 @! B! {                                end;
( @! v9 E& b4 u4 q, I# R+ D3 [                                @.CurrIcon := "drivingHome";4 m: x  [4 x; c0 }! d
                                @.DrivingHome := true;/ x: A4 X) w, J8 H+ H% p2 y& s  Y
                        end;2 T8 R& e! `  h; U7 N& L
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station; {, \: ^. U5 ?* w$ p9 [; `
                        part := @.transpOrder;
  _! ~8 I: i3 m$ d* W& Z                        part.move(@);-- load part" f1 |; ?* o0 A, p7 s% W* G
                        @.CurrIcon := "load";4 U3 p) z( n$ x, R/ q2 k7 K# R
                        GlobalDistObj := part.globDestination;
  Q9 Z/ O6 E' L- d! W. U8 e                        assignLObj := rgmanager.rgAssignL;
; \3 [* W) V/ i  g                        row := assignLObj.getRowNo(GlobalDistObj);
. e. g( `; n) Y                        if Row = -1 then -- since 70& d# w+ L- ?, ~+ K+ _
                                if lan=1 then
( L1 {% h5 u1 f  I; u, y                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),, j* A7 y' x( g' g( _8 N( M3 K
                                                to_str("in der Andockstation: \"",?.~.name,"\""));  N6 p7 }* u+ ]( @
                                else' v& U& f& W( o% R7 \
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
7 }- s# X& n* ]                                                to_str("in docking station: \"",?.~.name,"\""));                                $ e0 V+ j% J' ]: \
                                end;
+ Q5 s/ {+ R$ k4 _$ q( S! n5 ~                        else" X7 H& {) _1 A. b4 c
                                @.Destination := assignLObj[1,row];
/ l5 t. z; y# @+ \* L                        end;                       
6 ^" g: @' t* V  r                        newDirection(@);
7 u) G7 |: @2 f/ j3 O                        @.HasOrder := true;
$ U/ i3 g" J) o4 \' C                end;
; E0 b* [9 J1 Z0 ]+ B7 Y  X        end;
, r7 t' V: \+ W& J' X% n  Y' @6 oend;        -- of the method3 l: [# N. z3 [% K& _
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 & h" G3 ?: w. q- @9 c- o) w) V
! a! ~* Y& _6 g/ E- S( q$ m
这是AGV_putin中arrive的method。6 G8 m& v4 O6 E: H
, P2 S! k# H( _4 i5 e5 ~8 V( Q
当到达物料速度越高时,这个报警更多,9 S  Q4 B( d8 G, z7 c" s
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
; m( H$ p. v; c) {程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?. f$ Y1 c1 i; s/ y, ~3 s

* t! E9 C  ^5 |另外一个小建议,就是move,所有的move都可以这样
3 y' Z* J' g. H/ S4 H* k5 Mif not move() then debug end! o  c% L0 e3 E% G
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。2 N. S( X: `9 s& d, Y$ |4 X$ b
plant simulation中的free libraries有AGV模板,% {/ K6 X4 W5 t7 z' z
里面也有案例。
- `. ^5 X$ ~0 k  A7 N我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。0 O$ ^$ `/ O/ n/ x* M( O

2 u! Z; A! z8 O! _  f" J我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 . J. T* ~( m' B/ p. R$ ~0 m+ b

! R* j3 Y# H, A4 E+ A5 A) b那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
) M6 ~+ H* N' @7 w7 g这是AGV_putin中arrive的method。
! z3 n) c. P9 C2 @8 ]% h* ?! l- R$ ^# A% \; X3 h- \: \& Y
当到达物料速度越高时,这个报警更多,

' N8 W  u/ j% W' P+ }; p3 O  a6 o% g另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-16 13:44 , Processed in 0.019090 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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