设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9891|回复: 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'
2 U" U0 b7 }! V% {% t( }# w*/
+ `0 a4 H: z' [is
% a1 p) y' A) M3 r        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
" L! U- y# l9 ?do4 B! G7 X) ?1 v7 {
        Lan := rootfolder.Internal.Tools.AOLlanguage;
# m$ m$ j$ _2 c: b) X1 S* L        if current = @.Destination -- else return
. W  L; d& v3 g$ Z4 Q+ F5 Z        then
1 B6 H# M& {+ T; o- m1 t                @.Destination := void;
, m; G( u. x: t) |. x                if @.occupied then
2 [: x: u1 y9 E                        part := @.cont;
# l$ T9 d- s; f                        @.transpOrder := void;) t3 Z, c9 t6 E7 S; P. Q
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,( Y' q; G! ]% Z, w; B& G) v
                                @,root.eventcontroller.simTime);6 P+ m# N: c2 b0 M
                        @.HasOrder := false;8 `- f1 ?0 q! O8 y" Q
                        @.DrivingHome := true;
. _0 {; ~* Z* k. k                        rgManager.tryToStartTransOrder;$ @( E4 N9 J% F2 G! S) E
                        if @.Destination = void. Z( b+ _8 [- K
                        then -- no transport order for vehicle @
( U, S# k; U5 u' G" N7 J8 ?8 c                                @.Destination :=
, q2 r) {9 s. `8 B  r$ Q: Z                                rgManager.nearestFreeStation(@,track.~);
- G) p+ m/ I( F- D                                newDirection(@);   
  q  t" S& L! i& k                                if @.Destination /= void then( E+ e9 R" C* L+ t: M6 A
                                        @.Destination.NumReservation :=; B: U. }/ B- M3 G+ x
                                        @.Destination.NumReservation + 1;& j& r* C! A) P, T3 w6 t
                                end;
* q! ?% i$ R$ y( H                                @.CurrIcon := "drivingHome";
& H" P. ^8 E# n- A                                @.DrivingHome := true;2 d: M: @  b! K
                        end;
' U4 _0 W/ m! r7 K                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
1 D  J# G* }6 w( l! o% F/ }                        part := @.transpOrder;" }7 A1 H0 E% G4 z) h) s
                        part.move(@);-- load part3 g( t2 u3 ^" U; K9 L
                        @.CurrIcon := "load";
# N% ~+ m( {( y$ m/ \( w  t7 W7 R5 ^! N) E                        GlobalDistObj := part.globDestination;6 A0 b$ T2 |. g6 B
                        assignLObj := rgmanager.rgAssignL;
6 b( j- j1 [9 _% k+ A, Z0 ]                        row := assignLObj.getRowNo(GlobalDistObj);
6 z; c1 k7 S3 u                        if Row = -1 then -- since 700 l# D: A5 Q) n3 b+ E
                                if lan=1 then1 H; }7 w7 _7 }: D
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),. y  E' b# O/ ^9 ~, }! U
                                                to_str("in der Andockstation: \"",?.~.name,"\""));/ z3 V& G+ U& b. U# K" G$ Q1 ~; i; @+ a
                                else
2 i; K7 J! g( Q1 Q. |/ K8 i6 b                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),. l, J8 l. P9 \2 E/ Z: R! G
                                                to_str("in docking station: \"",?.~.name,"\""));                                8 J7 ^# C- g1 t0 [1 z8 ]
                                end;
3 M* f; n& q1 H6 p$ T* r8 y( [: o                        else: n$ I# ?, h9 F& |) G: p
                                @.Destination := assignLObj[1,row];( ~5 h* w7 h0 i  K
                        end;                        + r5 r; O6 n/ ?$ Q$ c0 R4 h
                        newDirection(@);( A+ y* A; u9 I
                        @.HasOrder := true;9 Q( l% ~2 Y/ c; n( d3 k
                end;% ~) a' p1 C5 `$ ~8 P) s$ P
        end;! k5 q1 v2 E- {2 u3 c
end;        -- of the method4 }8 Y1 V( r6 e! Z' h/ x
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 + V4 x, \4 _1 V& C* b3 P/ l
7 i  n2 |8 C0 i- {  o8 E, p4 m
这是AGV_putin中arrive的method。
9 a9 c& g& w  ^2 h( s" F+ a8 }5 _7 {4 a& d5 [; z
当到达物料速度越高时,这个报警更多,/ G* D7 z& j/ S4 g1 [
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
2 E% H1 P* ?2 |$ N1 l程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
8 h" I* Z& R& m: i, ?7 l7 N0 u: P; d: C) Y
另外一个小建议,就是move,所有的move都可以这样
6 b% j* z. r8 D: f- Lif not move() then debug end
; I# U. b) j# r这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
0 J6 T& V, Z+ Q, Lplant simulation中的free libraries有AGV模板," i) B9 S( d/ o
里面也有案例。8 A4 [) T7 Q& u$ s/ }
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
" i' l5 ]' T- U' Y& c. O8 q) v: n: D" y! {) x
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 " l* D( n7 I" q
" J* F) o9 G9 R3 V5 u
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 . o3 @) z9 V( ]$ O& u/ A2 W
这是AGV_putin中arrive的method。
5 D0 v9 j3 a) n' }# c$ q
& M7 z% Q6 f3 W" z当到达物料速度越高时,这个报警更多,

+ U( u  p5 x# Q1 E5 A' i另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-31 21:19 , Processed in 0.017842 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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