设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9809|回复: 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'
: Z8 u+ W# m) }6 x" J( |*/3 o% N/ q; P& z
is
/ F  N, I- h* O4 a        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
0 }# X! L6 N4 \$ f! z: ]/ P! edo
2 z4 F' O4 A: H" a# e4 i4 W        Lan := rootfolder.Internal.Tools.AOLlanguage;
7 f  ?+ W! x: A+ k        if current = @.Destination -- else return' V4 T0 ?5 ?3 [  y: j  g3 R- _
        then
& `9 E, C, \2 m! p/ T8 l. m! M                @.Destination := void;% w% {$ `+ U- R
                if @.occupied then
* z* y- N, p% y5 j. D                        part := @.cont;
$ ^  r: r3 ]6 F                        @.transpOrder := void;) N3 F# [7 U8 H
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,. ]& v% n5 {; A6 i+ g" I% C6 Z
                                @,root.eventcontroller.simTime);
. t) l. c1 G8 q) q9 Y0 I                        @.HasOrder := false;
1 `/ ^5 u3 g) x. M                        @.DrivingHome := true;# E. g. {* j4 E; Z8 m" o
                        rgManager.tryToStartTransOrder;
/ k) e2 h7 |  d. X4 l! v) ?7 m                        if @.Destination = void
4 C: @# N( X# N* a                        then -- no transport order for vehicle @! j/ w3 ~! z/ ~
                                @.Destination :=
7 H( C4 g7 E: r! |8 k4 z                                rgManager.nearestFreeStation(@,track.~);
. Y" a& Y  G" h, D' \1 }                                newDirection(@);   ; _0 C+ g" Z" \1 c
                                if @.Destination /= void then
4 F6 p6 f- j% E. M* K                                        @.Destination.NumReservation :=
- g2 m9 i1 g& U! ^                                        @.Destination.NumReservation + 1;. H( j3 M! e2 M1 ~8 l
                                end;5 g& w5 S3 T" y+ n
                                @.CurrIcon := "drivingHome";7 K5 r4 ~5 K4 O+ O. B' _/ q
                                @.DrivingHome := true;( B$ ^# ^8 a3 g6 f
                        end;" n. u$ g+ }( @( M3 V4 F
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
! Y" ^1 {2 V* J$ M+ @3 D6 r4 Q                        part := @.transpOrder;
% w3 [& B, a' ]* C# L+ M                        part.move(@);-- load part) i: ^0 i6 ]6 E7 d& i
                        @.CurrIcon := "load";
9 `0 ~9 g) s% y, f* `$ o                        GlobalDistObj := part.globDestination;7 N9 s" Q: [& Y
                        assignLObj := rgmanager.rgAssignL;4 O* R2 z6 C7 P+ S
                        row := assignLObj.getRowNo(GlobalDistObj);
4 i+ ^; a4 S8 V* H1 K8 e  Z! D                        if Row = -1 then -- since 70
/ c1 U. J9 t: c                                if lan=1 then* ]! p; T/ @1 F; |/ V
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
7 J, V- q7 g4 l. N/ l                                                to_str("in der Andockstation: \"",?.~.name,"\""));
" k! S) R% U- A8 F9 r  c                                else
  U3 |6 s8 k% y8 L# z+ j  `: S                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),7 E6 S( n& a. ^: s2 x3 W4 [
                                                to_str("in docking station: \"",?.~.name,"\""));                               
2 ~- ?3 A% o) J+ j2 t. b4 Q                                end;8 h3 S$ H$ _6 |$ j4 u
                        else7 l7 q8 x& o% o/ l  J+ J2 f
                                @.Destination := assignLObj[1,row];
) o) n* f4 M6 j- |0 m; u4 I  k4 T                        end;                        ! Z4 i( ?) n, O. J* I
                        newDirection(@);6 B1 e/ i$ u9 F, k6 @
                        @.HasOrder := true;
% r. `( D1 v6 _5 @/ w; q                end;" D3 q7 h* t) q. ~6 T; `/ k, q3 u
        end;
/ N* n' o7 @3 N3 Q8 o, [end;        -- of the method
) r& p) t4 I. i: p* J- b# E; x
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 7 D( x, p9 T& t/ Z

% ~2 {- i: Q& _- l3 `) {这是AGV_putin中arrive的method。
( J" L' i; S+ e  Y8 O8 U' f) z6 d9 c( t: M2 y
当到达物料速度越高时,这个报警更多,- Y" f7 J+ b+ |2 F7 E
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。$ i' i5 ?+ w6 [% p* d" Y/ a
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?9 y; Y- }" b# g- m
/ U0 `" \1 P+ U% d. _/ i
另外一个小建议,就是move,所有的move都可以这样$ ]2 Q# R9 A" u
if not move() then debug end
1 B  z1 U+ }' f! R- ~. F5 {这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。( P9 d/ `5 v* |& O% b
plant simulation中的free libraries有AGV模板,
. y9 X( }' b: C6 m% n9 R1 [里面也有案例。
) ], Z  E, w; e# |. A/ ?! |我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
3 q; h/ F6 m0 |( X4 h5 x1 a3 r" m  H" {: o. b7 ~
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
" ~6 L" P0 p1 i$ u1 ^4 d8 _
$ w, |) \; v9 o那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 / N5 f2 F0 t2 j* n$ Q& S
这是AGV_putin中arrive的method。
3 P7 `. k( T+ y/ k" A- w9 C3 l! \
  f1 r/ P! p% d6 \当到达物料速度越高时,这个报警更多,

0 U. M+ X% R7 p8 s% G. f另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-26 16:00 , Processed in 0.023494 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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