设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7711|回复: 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', Y) U7 r; N; T
*/
  l1 c0 y& x! A( P9 ais8 R  w2 u2 S. J! f
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
7 b& ~  O$ X: J1 N* Ado
5 X! k3 R0 N/ G% j2 C$ A        Lan := rootfolder.Internal.Tools.AOLlanguage;) h1 j8 t6 i# c
        if current = @.Destination -- else return: m& P  x% a1 o% P/ Z5 d6 `
        then
  Z1 Y. b$ `) A' ~2 N                @.Destination := void;
+ {# D* R3 U$ [- J, B                if @.occupied then* L6 h# L6 d" N
                        part := @.cont;3 A% S4 l: c0 G4 G
                        @.transpOrder := void;8 g  L3 C" h. V/ Z  r# [
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
1 N5 \0 k0 J$ H: T8 U                                @,root.eventcontroller.simTime);* N4 u2 Q  U* u: F; ^
                        @.HasOrder := false;  |5 U" w$ K$ i' q( s
                        @.DrivingHome := true;
2 @; b. S# V+ G- u                        rgManager.tryToStartTransOrder;
1 m8 O3 F: i* X2 T0 `7 @                        if @.Destination = void; z( D2 T. S/ w2 ~' ~
                        then -- no transport order for vehicle @
" e. _# z- a( ?( e( g; h% f                                @.Destination :=
! v- n9 P( |9 b: L6 P( O5 O: \( ?                                rgManager.nearestFreeStation(@,track.~);
9 V  p7 d3 k; Y$ }" ?- X; i2 I                                newDirection(@);   3 p# h1 a* Y' J3 ]
                                if @.Destination /= void then
2 v  R3 L5 G& a& D, N                                        @.Destination.NumReservation :=4 a! b; A, k; Q" C- Z3 a
                                        @.Destination.NumReservation + 1;
- J$ P4 A# @* h3 |( q- R, P0 g                                end;! e8 j( f  T" [( ?' p6 {5 V
                                @.CurrIcon := "drivingHome";4 f) ]2 Z9 {5 j1 ]8 j
                                @.DrivingHome := true;
( l+ s/ m; g7 `& w                        end;
1 j$ O3 N3 z# ~% K                else -- the vehicle @ is empty, both vehicle and part are in the same dock station! w7 n8 G/ G, C& E' X  y
                        part := @.transpOrder;! S% Y4 k2 A1 G( P
                        part.move(@);-- load part
1 _, k& A! C5 Q0 u                        @.CurrIcon := "load";
, \& ~/ d4 O" m9 k0 g4 D0 L; v                        GlobalDistObj := part.globDestination;
8 G- y3 s; f+ ]9 T4 v  V6 K                        assignLObj := rgmanager.rgAssignL;; `$ A# {# C' J" C: R
                        row := assignLObj.getRowNo(GlobalDistObj);+ Y, b! P) W# c" N' I8 O, b. N1 P
                        if Row = -1 then -- since 70
/ K  l: x8 F* s) o                                if lan=1 then
. r/ t! i' ~: ~- }                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),+ J4 U, w, x& k7 b  R( h8 G: ~
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
. H" f5 I5 V: j9 Q+ [! |* T                                else
; \' E- B1 e# p, p- I                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
2 {) \. ]$ D. y$ N& ?/ O                                                to_str("in docking station: \"",?.~.name,"\""));                               
; l6 v& b# Y- t8 V9 B0 R                                end;$ I. E8 j6 W0 B6 L
                        else
$ z! \: g5 a  q9 M+ O                                @.Destination := assignLObj[1,row];" {( U% L3 Y# g9 [5 z3 x
                        end;                       
- H( R5 f1 ^; n& {* ~                        newDirection(@);
4 v8 }9 ?$ q3 G9 g                        @.HasOrder := true;
: O; s; B) o) d/ N, u2 I                end;
: c; J0 r) B; H; S        end;
; `+ ?! g0 |8 i3 a; ]# J( |end;        -- of the method
- d. R, O' B$ V
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 1 h& U6 z  j- R2 y

, ^; R7 @: s7 K- x1 M+ F* B这是AGV_putin中arrive的method。- ?* Y0 Z) m7 K" p5 s

  s4 V$ T; a# L( @7 x3 H3 ~, l8 |当到达物料速度越高时,这个报警更多,
6 U! V1 ]- t( _' X8 F可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。" W* b! W* J6 W' |" R
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
& O; x/ _0 n7 ?
8 i! v. @' _  i4 y6 J) a另外一个小建议,就是move,所有的move都可以这样
7 O* Y( C+ Q" @2 f6 |. f; m; Aif not move() then debug end3 I: l6 Y4 w" m
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。8 ]5 s" Y5 O# [! ]7 O
plant simulation中的free libraries有AGV模板," y9 m) p8 @. n' o
里面也有案例。
( ^6 y9 \* D6 |7 j' i7 Y我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。4 i2 o/ e4 P) e1 j4 K! l

, P( D4 ^: [% Q$ g我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
, |. L8 i: c' p7 \) r* O$ s7 z. H1 s; v
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
% T- z5 }+ b6 A7 S" l) p这是AGV_putin中arrive的method。9 L0 t# M# F/ B! b3 k% M! S
$ X$ \/ p- i4 n. r
当到达物料速度越高时,这个报警更多,
% K3 J2 i* V  H0 c) g+ [+ F2 T, A
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-25 16:35 , Processed in 0.017442 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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