设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8859|回复: 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'5 U; V2 v+ ~' U8 N9 Q4 f
*/, i, b( X& ]! a8 k/ W" j3 a! X* E# T& E
is6 ~8 c9 k6 Z/ |- b: _% `
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;- S9 ~. A& C$ `5 q# f6 Y
do
( D9 \6 q, g1 x        Lan := rootfolder.Internal.Tools.AOLlanguage;
- \5 N, C9 c$ O5 R2 W7 p1 M        if current = @.Destination -- else return; ]8 z1 F% j0 Z# B2 }3 F
        then
4 g& ?) P1 `5 Q9 u( B5 Y                @.Destination := void;) h8 C# i0 K3 f& d
                if @.occupied then; Y, S. y: i/ }$ x% \( s, k4 t1 I1 N
                        part := @.cont;
3 i. w2 U. ^9 b: I                        @.transpOrder := void;
* x# Z; _1 q/ f) |  r5 E                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
* V/ b: _5 c0 ?. {: D0 i$ u1 x                                @,root.eventcontroller.simTime);
; h3 x$ }5 j5 o                        @.HasOrder := false;
7 A6 f- Y0 W8 z; {                        @.DrivingHome := true;( x1 K' {3 [  }* |" ]- Z
                        rgManager.tryToStartTransOrder;& W0 \+ H5 S1 r. G) a& e
                        if @.Destination = void  F( x& ^* n& g8 K/ a8 f" D9 x
                        then -- no transport order for vehicle @( i; A5 J8 u6 z5 t, ?7 p. F) g
                                @.Destination :=4 i6 d# J& c. ~# q) t" ^$ n
                                rgManager.nearestFreeStation(@,track.~);
4 p" X5 c: p) k9 S4 x- G                                newDirection(@);   / i* q+ [7 Q( Z: R$ Y# f
                                if @.Destination /= void then; W' i/ A# g4 G/ m# i6 y) Y
                                        @.Destination.NumReservation :=. D2 U. H9 N$ J% t# C) K' `
                                        @.Destination.NumReservation + 1;; t( @$ R/ l" Y& y0 H
                                end;
2 Q1 P6 _: Q* ]/ |  ^7 M' P                                @.CurrIcon := "drivingHome";4 e; K3 J3 o, M% S! S9 y5 `+ W
                                @.DrivingHome := true;5 ~2 D- t% {0 b
                        end;; R% X7 d7 s" ~& ]8 y4 g! X) }5 v
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station& w' v% M2 @, b* V; F3 k
                        part := @.transpOrder;* k3 V& {$ V  M
                        part.move(@);-- load part+ y. R" ~4 D- ~/ k7 V% i
                        @.CurrIcon := "load";
! m0 |( S4 K" z                        GlobalDistObj := part.globDestination;# B; [6 p; p0 Z6 n! S4 w
                        assignLObj := rgmanager.rgAssignL;0 k1 N+ x5 Z" {+ E7 D
                        row := assignLObj.getRowNo(GlobalDistObj);
; c$ }; m( ?5 {$ Q                        if Row = -1 then -- since 706 C; s5 p4 f) a9 i
                                if lan=1 then. y1 u. p, [& w8 l, n  G. o( Y
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
7 z( p  g* J+ w7 m                                                to_str("in der Andockstation: \"",?.~.name,"\""));
, K* c7 l9 _# u3 \8 U                                else; i% Z4 b5 m4 x9 r& o
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),4 p/ o1 W" _4 J8 W; J: k8 C6 B
                                                to_str("in docking station: \"",?.~.name,"\""));                               
) d% C! p3 ]+ n6 z  y. Q                                end;! N# [. ^* i* M. s$ t1 R3 T
                        else
) o/ ~, O/ |- G  J3 K+ B                                @.Destination := assignLObj[1,row];" x% q% k* c) {* ^7 @
                        end;                       
5 r" }$ {- X+ V* }                        newDirection(@);) f1 w8 \( W7 b( y+ `; L/ D
                        @.HasOrder := true;- W0 D5 J% {( _! E
                end;
0 M- E- {7 }! F; Z* n        end;
! p0 l8 J- N/ R5 V. D- {7 i: d3 ~end;        -- of the method
, X* ?" s9 h+ @6 y9 l  n2 V! r; T
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 8 C# S1 V) K* y5 b1 [
8 |  t2 H6 i# z$ M* ?$ N* t
这是AGV_putin中arrive的method。; \) G  l/ ]1 ^: F

" Y3 C) I( v6 a, X当到达物料速度越高时,这个报警更多,
( {" R6 I- N, ?# @; o# g$ w可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。! m# ?: X7 W# }6 X# P
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
* _& x6 X; _9 F5 ?1 K2 i$ J
2 o5 b' P/ t3 O4 h& |. K; D  x另外一个小建议,就是move,所有的move都可以这样
0 Z4 b3 Q6 o# T# M# r1 ~7 |if not move() then debug end3 \% x0 W0 L- I3 F# o8 ^) G; {+ H
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。5 _! ]# a) J& \" d. [
plant simulation中的free libraries有AGV模板,
8 D/ q2 \" `) y* Y4 q5 H7 v里面也有案例。1 h2 R' m$ B) b
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。/ ]5 a8 G8 B! X) C% `8 e

2 ^+ |0 h  z" b, ?我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 - g: b. M% v6 _& Q! k- u% T

0 t/ P) [( L/ {, w/ i. }2 |那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 . Y! u2 S: f: H9 L( z. ^! w7 j
这是AGV_putin中arrive的method。" |. i* q' k  h/ r, M0 K& H+ f

. Q' u! _2 A8 b, q0 F当到达物料速度越高时,这个报警更多,

' z0 u+ M& U4 W$ R5 k9 y/ n6 }9 W另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-30 17:05 , Processed in 0.015685 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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