设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8233|回复: 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'4 A: s; @1 J3 E) i6 d
*/
% ^7 j# o" _! Sis
1 T2 P& ~/ F4 V/ h+ U        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
$ A0 U$ A( K3 c1 K9 h- K2 Y( |do1 g6 e# w: H) l8 ^3 g- h7 B$ U3 x7 G
        Lan := rootfolder.Internal.Tools.AOLlanguage;0 ?$ q' U4 r: l6 m0 G! I2 s$ y% Q' K
        if current = @.Destination -- else return
' a; h, \+ P# A; O: G, A6 Q1 _3 ~        then3 m1 [2 O4 _4 b) v4 W/ E, B
                @.Destination := void;7 ]5 k9 L# y; x! p
                if @.occupied then! ]" P9 I* Z% K; O, A
                        part := @.cont;
4 @) ?8 J( C) b3 T3 A/ n                        @.transpOrder := void;
4 A6 n" q. P1 s( o; e  p  X) C5 w                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
+ y8 z' D; v6 ~                                @,root.eventcontroller.simTime);) g! }- n/ U- y+ F; P# {
                        @.HasOrder := false;
8 C5 [! Z9 E& z) S                        @.DrivingHome := true;6 a/ u# U3 F& l# z3 \3 N
                        rgManager.tryToStartTransOrder;4 j1 i1 W) _7 \" G
                        if @.Destination = void/ [, y* v) X8 T
                        then -- no transport order for vehicle @
7 O' U4 C& E/ P2 U                                @.Destination :=
, Z2 ^! l2 h( e0 z+ @: K                                rgManager.nearestFreeStation(@,track.~);2 H+ T- E' v" C6 R4 @# F
                                newDirection(@);   ) w; Z9 i9 W% @2 A, p3 _( n
                                if @.Destination /= void then
$ I: {. O8 k& t9 H) J* A) [5 R# Y8 R# P                                        @.Destination.NumReservation :=
# R' I8 M4 n3 b                                        @.Destination.NumReservation + 1;
$ A, t$ ~$ Z' d8 E8 Y. B/ g. }" E                                end;
% h0 I  Z3 U& }! w6 F: k                                @.CurrIcon := "drivingHome";+ y" ^+ U1 F4 E6 K. o5 ?
                                @.DrivingHome := true;
$ J8 H7 W: @# j( s) ?9 {( ]0 a  c                        end;
) [+ P' D: z* m7 C# C9 y6 _                else -- the vehicle @ is empty, both vehicle and part are in the same dock station, I( f- R" k* N) S/ j: u' e% s
                        part := @.transpOrder;
8 g% s( U. C8 S# W                        part.move(@);-- load part8 I$ a' b& r2 k$ f2 \% ~
                        @.CurrIcon := "load";4 f% s0 J2 T2 ]" G4 X6 b3 D
                        GlobalDistObj := part.globDestination;" H- F' F, W7 ~- J4 T
                        assignLObj := rgmanager.rgAssignL;
$ L* z; `- ?: v9 I4 F& ?9 G                        row := assignLObj.getRowNo(GlobalDistObj);
7 R, X- m1 e; z( [" I9 ^7 a1 y                        if Row = -1 then -- since 70
6 D% Y( l8 w- h& y8 `( E- o                                if lan=1 then
  f' c  k! y+ ]- O0 U+ q                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
7 G' n7 Q/ D2 }0 O                                                to_str("in der Andockstation: \"",?.~.name,"\""));
* r, t* G  W9 e                                else
7 ^* [& c7 B: R( ~8 \3 N2 }                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
. z: ?* R, W5 p                                                to_str("in docking station: \"",?.~.name,"\""));                                4 l$ s0 ]/ M4 c9 H& [! L
                                end;6 s7 S; `, e+ e
                        else% K. L7 R: ?  c! [1 D
                                @.Destination := assignLObj[1,row];6 M+ [" C! ?7 S: L( n. y5 V" b
                        end;                        7 a4 a4 ]5 D- a
                        newDirection(@);
; A& X' t6 J8 j  D                        @.HasOrder := true;! ^# [! A, d4 A, u& o7 W
                end;5 p& F, ?( D2 J
        end;& n& ^$ {; g8 A+ X! S3 C* r" C% _
end;        -- of the method
9 F2 E4 [# J/ x/ ?9 x! r
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
; @3 c& E( Z  l- ~% L
9 D) f' w5 O7 b& ]5 ~- q# i1 t( K这是AGV_putin中arrive的method。! [1 L/ A* @, f7 e( I1 u

* p3 p, ]6 O6 ]* L# q当到达物料速度越高时,这个报警更多,, W1 E! p7 f6 A9 n# a- ~) E
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
1 M$ W1 [$ ]" A3 ]# R程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
, ^, i( A7 ]# W& _3 K/ X7 o$ r6 g* w  n7 e. h& Y" q8 v3 G
另外一个小建议,就是move,所有的move都可以这样- R0 ~+ j8 s6 K9 V1 ^
if not move() then debug end
6 l1 K  h- R7 l# I8 V$ y这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
/ ?, L* b6 q. E5 xplant simulation中的free libraries有AGV模板,
% f+ b* O" p# F. L$ A里面也有案例。3 Z5 s' n: r  L, ^- d. y
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。0 q3 E% A! N) T5 J7 `
+ h+ V; I' u6 M% T/ M0 ~* c% d/ F, E& s
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ' j' Z+ ?0 d% i* \  X3 a

  u! v" U! L) I( ?+ d& i1 W那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 % f% [2 C5 r2 J
这是AGV_putin中arrive的method。
, U* r$ Z7 t( U; }" A7 h9 @8 z8 J$ S1 b( n1 H1 d
当到达物料速度越高时,这个报警更多,

3 N7 L" s* u4 k) c5 l8 O, H另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-22 11:59 , Processed in 0.018073 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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