设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9161|回复: 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 R) I7 K9 j- k) C7 a
*/
; k! h" E# S- O5 g2 gis
% ?. g$ m8 T' b" H! m        part, GlobalDistObj, assignLObj:object;row,Lan:integer;1 L' c% @; c/ s6 J; f5 R1 p
do
- J9 J4 |* m+ }& W) C1 c% T& g' I        Lan := rootfolder.Internal.Tools.AOLlanguage;& n, i. d. G5 L9 c
        if current = @.Destination -- else return
6 ]5 Y' g  ^% v, h( J$ j        then
+ v4 u4 Q' A- k0 p9 n1 `' A                @.Destination := void;
; o  W% `5 ~$ }+ m7 s' U: ?                if @.occupied then! y9 e" o2 j& w; D9 }4 K
                        part := @.cont;
% Q9 l# c# Y% r% T1 x( j9 c2 ~, f                        @.transpOrder := void;
- v1 A. q) V( @8 T. Q                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,5 o4 l% K: h+ A1 m/ w
                                @,root.eventcontroller.simTime);
. R: D1 w) `& E% F' {+ l                        @.HasOrder := false;
# r; _# Z: y* T( l1 K+ U: q                        @.DrivingHome := true;
  p5 w* h6 B8 |6 t$ M                        rgManager.tryToStartTransOrder;
4 K8 l+ N' u& w1 U                        if @.Destination = void
, P* J7 g% w9 U$ p" H+ I                        then -- no transport order for vehicle @
( G, [) M2 s$ ^3 g, D                                @.Destination :=
; }# a/ d0 y2 F& m                                rgManager.nearestFreeStation(@,track.~);2 P* N) ~+ E: b5 Y$ ^' ^1 [$ e0 ?5 l
                                newDirection(@);   # f$ ]$ I, Q: y/ @
                                if @.Destination /= void then" o( A/ @) E# m  v7 d
                                        @.Destination.NumReservation :=  X3 r) x; R+ M/ `& @4 d* ~$ j
                                        @.Destination.NumReservation + 1;- C7 s) }& ^$ @7 u0 Z" d; W7 t$ S6 g$ b# Z
                                end;
. X) b. r! o) G+ r, ]- t                                @.CurrIcon := "drivingHome";
) y* @& a3 n+ Q% r- T# S9 B                                @.DrivingHome := true;
1 b6 N" B# G: q" L3 K7 j9 i3 C                        end;* w. B& D- Y/ S. u
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station; x2 R+ c& @9 ]/ J! F
                        part := @.transpOrder;# R3 G9 E3 L4 R; N* ]
                        part.move(@);-- load part4 L4 H* E0 h. _  w/ B
                        @.CurrIcon := "load";
* b7 e/ b: |! p8 N+ ]                        GlobalDistObj := part.globDestination;7 p; T1 y" M9 w! L/ h8 n
                        assignLObj := rgmanager.rgAssignL;
/ b' q% u& B5 i3 g( P4 s* ]                        row := assignLObj.getRowNo(GlobalDistObj);
; U, z; J: ]# J8 t* f                        if Row = -1 then -- since 70( j9 v  S* T8 U+ ~4 R
                                if lan=1 then9 f. B  P% }# j8 U8 r( ]
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),- L* g9 q. l  A  q, ]+ C% l
                                                to_str("in der Andockstation: \"",?.~.name,"\""));4 l" x1 @* z6 l5 I, t$ y0 P7 R
                                else& i& ]- }' M3 M4 U, z) `6 Z# e
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
, C" i* ?, ?# d. ^( N! y& c                                                to_str("in docking station: \"",?.~.name,"\""));                                1 A6 M2 m1 o/ V+ p3 X0 N
                                end;) {% x" S9 c- Y2 j
                        else
7 M. a3 p! Q8 e4 a' F& S# Q' d                                @.Destination := assignLObj[1,row];
& b% w: K4 j  O2 k+ b0 _                        end;                        3 Z% e, Z+ _% f9 G0 f
                        newDirection(@);! b2 e- R8 G0 M/ R) F1 T
                        @.HasOrder := true;
# H8 L: Q, d+ c) |! ], }7 l                end;
2 d# }$ r" k' S( M        end;
4 S4 v& D, v- Y1 W3 @- h3 Eend;        -- of the method' |* O2 I) E, i. j% r+ q! W% [
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 9 \3 x8 b8 ?" y
, }3 w# O; {" F+ ]: O5 j; H1 m
这是AGV_putin中arrive的method。
$ M% x6 [" y; N1 Y2 N, f$ q. Q2 a/ ^" o$ g/ k- n; F5 A8 U$ `1 }+ L. Y
当到达物料速度越高时,这个报警更多,) i+ h+ O. a' B7 e2 {
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。6 C7 P. A: [7 ?& ^' D; t7 {- }  m
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
9 u) {* s+ o3 A( I. {, h+ m1 Z4 H% z" h  ~
另外一个小建议,就是move,所有的move都可以这样& _) p  i. ^6 H! P
if not move() then debug end
" s& n  x" W4 I* j) z这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
* X0 z0 {1 {( F. a/ N+ g2 vplant simulation中的free libraries有AGV模板,7 \1 q. \9 S0 W
里面也有案例。8 N, X4 |4 y+ A7 e
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。) T' U6 ^& {% e) @
. f6 N, n+ k& p9 J$ S* m9 n
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 2 l  w9 z0 E3 b3 U1 O( i% u
" V: X  c5 C! P( u1 ^
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 1 z9 t8 n# c1 W# g0 d: o
这是AGV_putin中arrive的method。
6 f6 k; E4 g  K$ C( ~% O
8 ^# f' ~% U6 ]$ H  {# K7 o当到达物料速度越高时,这个报警更多,
& z, f) F0 p/ M4 y
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-17 07:21 , Processed in 0.015811 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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