设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9502|回复: 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'. {; t6 L7 D: Q% l' Z/ S) S
*/
' e% ^4 P7 K5 P! O, L( t5 Nis, n' s6 S# q0 a7 h+ n
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;6 [  L, s" D) ?2 f( F3 x& v# S
do6 ?1 `8 g- u; M' @) ^2 [2 a! d
        Lan := rootfolder.Internal.Tools.AOLlanguage;
+ m6 P8 ]$ `. [5 x; T        if current = @.Destination -- else return1 H: `6 i: P5 o# d4 S
        then
2 r; n  B9 k. _7 e) X2 `                @.Destination := void;: e& `$ t1 W8 j; e% @
                if @.occupied then
% }1 U/ W" \& L                        part := @.cont;
1 v6 I1 Z" q: P                        @.transpOrder := void;
, Y2 o. K/ B7 B% y                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,. J. N2 i) l" I6 u
                                @,root.eventcontroller.simTime);# G, @. g3 ?* u
                        @.HasOrder := false;4 q; r4 K# D; }" M+ D* c3 t: \1 G
                        @.DrivingHome := true;
, e/ j0 [+ r1 X  Z. L2 y                        rgManager.tryToStartTransOrder;
. r, W. k1 w1 c6 Y- T) Q, U+ e                        if @.Destination = void) E. O* H" d, j# R
                        then -- no transport order for vehicle @8 h8 Z( g+ U1 d9 r- I
                                @.Destination :=* w: [( f- ]5 r# {, @
                                rgManager.nearestFreeStation(@,track.~);$ T* L$ W7 E8 t0 r
                                newDirection(@);   + g4 |$ l/ c# W) H% h  l2 T
                                if @.Destination /= void then
8 Y/ B0 U& `5 \+ f                                        @.Destination.NumReservation :=1 K2 v8 x# ]4 e0 B4 G7 H6 l" a& t
                                        @.Destination.NumReservation + 1;
- n$ @/ g5 Y/ P$ i" n  a                                end;7 _, }8 J7 \+ J  N$ I' J
                                @.CurrIcon := "drivingHome";
& Z3 g& `0 J9 T$ ]- Z                                @.DrivingHome := true;0 R$ X' q9 |% m  z
                        end;& M0 D7 z7 y3 c8 ^4 n& `7 k
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station& P4 @( I) T5 i- }# i3 e" @' ]
                        part := @.transpOrder;& c* m2 G- I1 w0 Q- |7 m7 k$ ^
                        part.move(@);-- load part" N- e% @0 P' o1 u
                        @.CurrIcon := "load";; {3 u: @' V$ v8 f. E
                        GlobalDistObj := part.globDestination;
2 M" k) B7 T" Y+ L                        assignLObj := rgmanager.rgAssignL;
  _5 }6 a1 U2 V& u& V/ Z                        row := assignLObj.getRowNo(GlobalDistObj);9 a9 U+ s/ m0 l/ Y: L8 j
                        if Row = -1 then -- since 70) ?& e9 k7 w% A& I9 @6 C
                                if lan=1 then/ B- E) `! j* ~) _! z  ~
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),8 r7 \8 P% j7 Q, q
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
3 Z( P! O' O4 F8 v                                else9 k! G5 P! y! o1 q/ h3 @& m
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
( Q& `1 H5 c: F. A+ `8 W                                                to_str("in docking station: \"",?.~.name,"\""));                               
& Q7 x9 E/ L* u7 ]* z                                end;
  A& `7 R. o, e3 y) Z                        else7 N6 P9 I/ b4 N# `; j$ e
                                @.Destination := assignLObj[1,row];
, O3 N5 c  p8 [# Q                        end;                       
) _" y$ m0 L& K" N* X! v$ n; N                        newDirection(@);
/ j5 A4 ^5 H  u8 K; h                        @.HasOrder := true;( o% m/ r' g" y  f; ]. f
                end;; k1 D( G) c4 c$ a0 S
        end;
9 Q5 G- z" P/ q8 Nend;        -- of the method
* S6 ?: r( N0 O1 c" N1 C4 u
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ' w$ d+ W7 V' O% l! E5 `# e" t

) @0 t5 ^) g8 @这是AGV_putin中arrive的method。
4 N% P2 d4 ]; L4 h2 H5 u$ }
# L# w; m+ F1 [/ ^- c9 w9 c当到达物料速度越高时,这个报警更多,7 p% \6 T. b8 P  `
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。3 A- V4 F( }2 e, J9 E* z& c
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?! Y. L* ?; o' x( {$ V5 F% W
( Z5 c+ a# o* L% d5 r
另外一个小建议,就是move,所有的move都可以这样
: J8 s+ A2 X$ k: r$ ~9 ~( O" Xif not move() then debug end1 j" W: P. u2 M2 w# P- S
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。# K' C$ p$ ~+ [9 y2 T) x8 a2 W6 I) j. R
plant simulation中的free libraries有AGV模板,
% Y" G+ @0 l( z6 ]. |里面也有案例。
* v! ]# E2 z1 t我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
9 z( C6 i0 ]8 D8 g1 b/ q) ]8 c& V7 A2 {4 V/ Q9 m* E
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
1 B- O- X1 |5 R2 e  q+ u/ U1 k" L) q/ P6 z
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 6 i! V2 Z0 h- R( e1 K" |8 v
这是AGV_putin中arrive的method。
- A7 k! p5 b: B4 s4 _/ X0 B+ \$ ^: n) N
当到达物料速度越高时,这个报警更多,
0 y. L; O* ?& i' H
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-4 19:56 , Processed in 0.018311 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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