设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8767|回复: 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'
0 Z. P1 @$ v9 q' Q*/
7 U' e$ m# w  X& ~. B6 R; Bis( A6 p; V) P% T
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
3 w. r+ u" d( b: A4 Bdo
+ s3 q% I! W: X! P7 `) m        Lan := rootfolder.Internal.Tools.AOLlanguage;7 Z1 o: [, D$ O( a
        if current = @.Destination -- else return
1 d. y4 r$ k- C        then) O  A( F0 Q' c; K
                @.Destination := void;
- Q0 C. }( q; E& `! n6 U0 l0 z                if @.occupied then
% h& z0 |. }' A  L# z6 Y                        part := @.cont;( A& T1 b# K8 ]1 r  B6 Y
                        @.transpOrder := void;4 C1 ~) Z* y: z  v+ g! z" j
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
7 }! |! t- Q) `' `& d* ?                                @,root.eventcontroller.simTime);
' P. ]/ Y# ?; j& O7 L# H                        @.HasOrder := false;
8 U2 k! |7 ?: n/ z8 y                        @.DrivingHome := true;
! _3 l# k. H$ N% D% L( q                        rgManager.tryToStartTransOrder;
9 @  b! i) k3 \; f9 Z6 G                        if @.Destination = void
" G8 J+ R) b3 A! Y                        then -- no transport order for vehicle @
  ^6 U: d  e$ ^3 Z                                @.Destination :=# e8 v4 ^) ^4 ^3 n# T
                                rgManager.nearestFreeStation(@,track.~);
4 T9 J! G- q$ d' M                                newDirection(@);   $ C  S/ \  M4 J
                                if @.Destination /= void then/ T4 ]5 n8 h9 \, g8 S, D
                                        @.Destination.NumReservation :=
3 K. H4 z- [; N8 i: ^                                        @.Destination.NumReservation + 1;8 d! }1 ~" ^4 ~8 c
                                end;
- d6 ]. x( i" g1 t3 \: w8 Q0 h                                @.CurrIcon := "drivingHome";
% N# E! `# Y" v6 N4 l$ u                                @.DrivingHome := true;
: X5 }$ G7 x( Q0 H9 g  g% ?8 P                        end;
8 w9 v9 z9 T5 a7 c; I9 B                else -- the vehicle @ is empty, both vehicle and part are in the same dock station7 O7 U) G8 \6 k% y  n
                        part := @.transpOrder;
$ h4 \& k3 h; W                        part.move(@);-- load part- o" }& T" G- |* o5 W  x* D2 d
                        @.CurrIcon := "load";/ [' X( K& @+ u, ~
                        GlobalDistObj := part.globDestination;
3 N( M( a  w3 m  S* E4 y& X3 Z4 g3 i+ G                        assignLObj := rgmanager.rgAssignL;
  b5 `8 c# D5 d/ [4 O" d                        row := assignLObj.getRowNo(GlobalDistObj);
5 W& j' g& ^/ ]6 {                        if Row = -1 then -- since 70" A4 z# N- ~6 F" {  @# [: ~" N5 P
                                if lan=1 then" ~$ z' G- X& I# i  l6 M
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
' `+ W' h* ?5 |9 S5 J3 H$ W                                                to_str("in der Andockstation: \"",?.~.name,"\""));- _% h0 V- s6 W2 a3 z
                                else
) n& A$ I3 }$ d2 n                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
3 ?! n5 B' L4 S1 ?* A+ ^7 b                                                to_str("in docking station: \"",?.~.name,"\""));                               
+ i, y% f2 B, q                                end;. \9 n3 P* S  n
                        else) P. U9 E3 I$ l, i
                                @.Destination := assignLObj[1,row];
& f. Z+ h0 R, {' F( A: I& P                        end;                       
* z3 O1 H, n: ~                        newDirection(@);" I# g# w3 B6 T1 ?7 f; G5 a7 D- y
                        @.HasOrder := true;
; P: G  O+ W. d4 A/ G/ o) U                end;
( R) F+ r7 R' S* U        end;9 O( J. k8 d! Q) S" O9 ]+ R' \
end;        -- of the method
4 b& f6 |! O* r3 n9 T
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
4 C+ J4 z$ T" S* l9 |! e* ?) ^2 A0 Z
这是AGV_putin中arrive的method。: L2 r7 _- M9 T' W- H/ L
* C7 ~/ n# Q  d$ w" t$ L& J
当到达物料速度越高时,这个报警更多,
6 a4 E% o0 M- \! F# H可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。* o4 E+ O4 C8 r7 ?0 n
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
6 o% @* Q* i8 J' j3 [9 F
1 p& S9 V7 p* M& D% q另外一个小建议,就是move,所有的move都可以这样: M' q* a* I" u6 W4 _$ Z
if not move() then debug end
7 [% w& o% P' ~4 R' P1 r  j这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。9 X) L6 I+ `' B
plant simulation中的free libraries有AGV模板,
4 a0 u: w, x5 S1 e1 u1 H" W5 R/ S里面也有案例。
' J# A3 z9 r0 M, U9 }我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
+ R2 I/ d& T- F* \4 M7 U0 f% f  J+ P; g
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ( D8 s# Q) \6 d2 O2 q; E0 k

1 |' p4 x( H1 b; L: ~9 K那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 / h1 m+ X* C) x- S
这是AGV_putin中arrive的method。
% n# R6 {! }$ ?
, b3 Y7 _- x5 u* A5 `8 r当到达物料速度越高时,这个报警更多,
' ?. @6 ?6 O' C  |7 n5 {7 H9 x* d
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-25 07:47 , Processed in 0.017302 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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