设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10300|回复: 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'
. h4 S+ ?/ u% b% K& q* s*/
. z$ t1 \4 X! q, x) a) c# Ois. e( i/ y# ~2 `6 L' l' H" u
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
8 O$ a# C6 i4 U: z& ^$ ^# pdo
( ~, @! P/ k& h        Lan := rootfolder.Internal.Tools.AOLlanguage;5 x* |4 I$ [6 K8 [) n, G- o* f; ^5 M
        if current = @.Destination -- else return
$ c+ {% @3 e: k: o        then" L# X: X8 b# S) K9 m1 [+ u
                @.Destination := void;. I( i: w) E# v3 c, ]) A' R
                if @.occupied then
' F2 x0 t$ @1 M2 \, n) {                        part := @.cont;9 b, Z# e: s4 w+ Y2 H
                        @.transpOrder := void;6 @0 ]9 U% I* [! M
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
0 h, `+ @! g$ l                                @,root.eventcontroller.simTime);
+ h/ s& s, a$ I+ K% F                        @.HasOrder := false;
, q: [  w% H3 \3 w+ \$ b; b, E                        @.DrivingHome := true;
$ a* i& F) p! e1 Q' N                        rgManager.tryToStartTransOrder;
# m' W$ j5 w2 t4 S2 |9 ]                        if @.Destination = void  R! _. F8 Q5 K# T2 Y: f
                        then -- no transport order for vehicle @0 n3 C, u) l# J
                                @.Destination :=6 U$ A# C5 l7 \0 L8 y7 j  p
                                rgManager.nearestFreeStation(@,track.~);5 n+ ?! ~: C- W: F6 A
                                newDirection(@);   
2 b# Y2 [9 f8 n7 o. ~                                if @.Destination /= void then6 W% q3 S6 f, Y
                                        @.Destination.NumReservation :=
/ S9 r) a$ S0 A: K8 v! r1 `                                        @.Destination.NumReservation + 1;
3 ?1 p# j+ V! e                                end;
3 p- |1 g' m6 x  e& ]4 N                                @.CurrIcon := "drivingHome";
& Q; j( B  m- {9 Y3 L8 _0 e                                @.DrivingHome := true;' D1 F% |2 X8 r& y8 w
                        end;- z/ k0 Q+ t0 s/ F+ n% }
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
) A( j1 f: d& H) z: O                        part := @.transpOrder;
) u" Y( o1 ]( U% {2 J" U                        part.move(@);-- load part/ Z$ `1 s) T1 l8 h
                        @.CurrIcon := "load";
# |) Y( n, {7 g' T                        GlobalDistObj := part.globDestination;6 K5 x* x0 c" E, x
                        assignLObj := rgmanager.rgAssignL;
+ S" d4 @/ n( x& X) `3 V5 T                        row := assignLObj.getRowNo(GlobalDistObj);
) r& t; O# q% a                        if Row = -1 then -- since 70+ c5 L2 D3 G0 h* k. W& M1 v
                                if lan=1 then
- X/ b& f& Y9 m- k3 I6 q- D                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),4 o: @" l' q6 o% e1 t  }4 g' J5 L
                                                to_str("in der Andockstation: \"",?.~.name,"\""));5 P% `! t2 Y$ i& ]
                                else
' W  d4 n6 \: T. {2 y# [                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),; E. B' \! w, l8 M, z8 s
                                                to_str("in docking station: \"",?.~.name,"\""));                                % S' e# ^% d1 n  w3 {8 [1 x
                                end;: _! D# c! j" o( {
                        else
7 Y  b' o# x0 g8 `' R5 h, L                                @.Destination := assignLObj[1,row];3 c& g$ Q* b) y" q
                        end;                       
- Q- e  }  l" D! I; q; |: ]                        newDirection(@);/ P7 _2 b6 Y8 O- `$ x, c
                        @.HasOrder := true;
# L( h. o- z" J: S- E- K                end;$ s7 X9 O& F% g* \; }
        end;& G: z" R8 J/ F7 h* U2 H3 e% d2 D
end;        -- of the method$ D9 ~2 a/ U: ?, q& m3 e& P
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 8 U! r( i$ T4 o. I; o) B
; }( |3 e5 c( u7 |9 l6 y2 M
这是AGV_putin中arrive的method。
4 G" q9 c9 ?$ q6 g
: H7 @# x5 y2 M* `( [1 ~+ N9 {当到达物料速度越高时,这个报警更多,
# t9 A1 a- o. z可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
' B/ d* |; r1 \程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?  A% M* v: [- r

' ~) ^' C8 }5 [1 o0 y  F! W另外一个小建议,就是move,所有的move都可以这样
5 H9 P, y2 m: G) {4 b, [if not move() then debug end- [; ^8 \* D- |( s, }0 p( D, r; A2 q# I
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
3 K' w/ Q- C% W: Q. P! dplant simulation中的free libraries有AGV模板,
* _5 ?" c+ \! J! j  T9 p& F里面也有案例。. G. O, _% u# l1 M# y3 c' ]  X! h  P
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
2 d& }* O" W+ D6 q  J" l
# k4 g3 i+ H/ c1 B9 O我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
. P+ b1 s' J5 A6 D8 O" J0 T7 W6 r  C: ]# K
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 * d, r6 q8 f3 P6 I+ ]
这是AGV_putin中arrive的method。
8 i. ]2 O1 }* L: c; r  D! t3 z& A. I" a8 m: r
当到达物料速度越高时,这个报警更多,
2 \6 B( `/ G# h$ |3 T! g  y0 F- b
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-25 17:21 , Processed in 0.028857 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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