设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8636|回复: 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'* [- U. Y5 f8 F4 S" R
*/* e% x9 c7 b. e6 ^; ?  Y" G. P+ @
is
% H- v( H9 S, e2 ?6 q        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
( r  G& r. y1 V; Zdo0 T- Y0 C. {/ N
        Lan := rootfolder.Internal.Tools.AOLlanguage;% a  Y* _% ~. J  `+ s- r$ @; I
        if current = @.Destination -- else return; u, a7 \( ^6 ~. O- g% B
        then
" ?5 s/ O) E( B; R% J5 c5 Y/ ^                @.Destination := void;8 h+ ~! Z! E: H1 j; ~
                if @.occupied then5 t: {+ p0 O" ]0 E7 Z
                        part := @.cont;
$ D# U" T+ l  K- y5 y8 S6 R                        @.transpOrder := void;
7 R; I6 v4 u! [) i) o                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,1 g) k/ Z, {) d0 l1 U1 L
                                @,root.eventcontroller.simTime);4 Y2 B+ |# |1 P! v# o4 Z3 F
                        @.HasOrder := false;* r4 G2 n8 `. S; ]  P& m! f8 i' k
                        @.DrivingHome := true;6 v/ Q# h/ ~: ?4 r& _& ^' B
                        rgManager.tryToStartTransOrder;
+ v5 s2 X1 Q, k( k3 Y  Y$ n                        if @.Destination = void9 e! g5 O0 h- Z8 g4 T& h
                        then -- no transport order for vehicle @+ B+ M" n  Z. u& |, c& t: p
                                @.Destination :=, z+ Y4 x: o0 X5 {
                                rgManager.nearestFreeStation(@,track.~);6 [% `/ W& R. _* A9 p
                                newDirection(@);   1 K. n, @& B8 \$ p/ q. }% v
                                if @.Destination /= void then; h# Z+ k& z/ N' H
                                        @.Destination.NumReservation :=, ?8 w5 q& |9 m5 Q2 k: L
                                        @.Destination.NumReservation + 1;
- j# p- h7 f( C9 l. Y$ U" z                                end;
! R) ?* v$ D) R3 Y4 K3 E                                @.CurrIcon := "drivingHome";; @, S. b/ P  I+ j8 i4 z- r
                                @.DrivingHome := true;
& t" H* {2 y1 W                        end;
9 L1 Q2 i$ R( P- n7 A5 v                else -- the vehicle @ is empty, both vehicle and part are in the same dock station& M6 ~$ [# b5 U4 l" v% @
                        part := @.transpOrder;( n: j8 M5 L0 E9 N, E) o
                        part.move(@);-- load part! M1 y" M$ Z6 {7 ~
                        @.CurrIcon := "load";3 q& L  @3 x6 @4 }
                        GlobalDistObj := part.globDestination;
+ L1 A% v: ~! B$ g9 A3 k6 B; K                        assignLObj := rgmanager.rgAssignL;2 @3 o, d% B0 t2 \/ l5 C
                        row := assignLObj.getRowNo(GlobalDistObj);
2 o  @: ?6 b' z$ D1 W4 W. @1 x                        if Row = -1 then -- since 706 r  X/ @: T/ O
                                if lan=1 then
. t6 p& U# p+ |/ b7 F                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),: X9 d0 Q  c" U' E4 r3 T. O" A! G
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
" o! `: C" x: i! ]! L/ S                                else* k. g. S& p9 u' T, [6 W- c( u  a6 x
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),! g7 G) |7 r# E; ~; B# Y
                                                to_str("in docking station: \"",?.~.name,"\""));                                3 ^/ f( H) _2 c7 N* G) Q
                                end;3 t" }1 r" _7 m. ^: m+ f
                        else# V4 ]9 y/ V: T: y
                                @.Destination := assignLObj[1,row];( D& u, r& N  d# b% V6 Y
                        end;                        % j0 Q8 y" x/ h5 y% p6 K5 g
                        newDirection(@);
- f7 Q, P( k  D+ _2 x# P                        @.HasOrder := true;
# K7 ?. k# _( r                end;3 s# u5 p9 Z# c/ a" n
        end;
' ]2 M0 C, O5 [6 ?9 e7 t% Yend;        -- of the method
- v: n3 ?2 f+ }6 f. m% Y
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 . ]2 W" |. o; [$ H& f. u9 P# D

3 d" [" V1 ~7 i1 w6 H6 R这是AGV_putin中arrive的method。
) T( N- Z0 j7 p. [1 A
; U* l* Y0 D5 \% g- w! }当到达物料速度越高时,这个报警更多,: U6 M! m/ V3 ]9 o# X# p
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。( n& A, `8 p, n
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?) p. Q) M5 V3 h

9 B9 u, L# R% l2 X2 N( p+ V另外一个小建议,就是move,所有的move都可以这样3 u& w3 `, N) f4 o9 M; _
if not move() then debug end: j# N8 z' q4 c( t& \
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
0 k" `. I0 w4 j: a+ @plant simulation中的free libraries有AGV模板,: e$ i/ m4 \% G" e; ~* d: o
里面也有案例。* t- [) Y7 u) K! U9 I
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。7 l3 `8 u0 p3 Q" U

- O! g( K  }- ?6 W8 b. _/ Y% x我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 # [" k; f( }5 l2 v# ]/ V
9 Z9 |$ T( ]! B- |# ^8 @; Y: l
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
5 D' q4 |, S7 z2 |; j2 j) R8 {这是AGV_putin中arrive的method。
* o9 y8 w" F5 ]/ U1 l: Y! C8 S* u$ B
当到达物料速度越高时,这个报警更多,

9 |+ P, U, _' E! e$ I' y另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-17 11:58 , Processed in 0.016265 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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