设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10231|回复: 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'
6 |- o1 M9 V% N+ g; E% x2 G*/, g2 q& ]. J5 S
is- a1 ~+ h7 Z6 Q+ H
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
5 f- C$ q, Q0 Wdo' [! D, _% w6 ~8 x; [, J9 X# }: d! ^
        Lan := rootfolder.Internal.Tools.AOLlanguage;" H% c2 r8 K0 n8 h+ }2 P  P6 F8 b
        if current = @.Destination -- else return0 F& E/ ~2 e: _0 p" S$ g
        then# G3 T7 b7 A. k! d- @
                @.Destination := void;( y) M6 e7 ~7 ~1 Z) q! ]
                if @.occupied then
/ v1 I: m) Z! B# I                        part := @.cont;  o: c# f  L# }
                        @.transpOrder := void;
. `, d, T, ?7 W! Y/ X7 Q( J2 o) o                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
8 h' o; c  A3 X                                @,root.eventcontroller.simTime);
& O/ ^6 L# n# y. Z- Z4 P                        @.HasOrder := false;3 q9 U$ r: O/ n9 B0 ]8 I
                        @.DrivingHome := true;! B2 |; ^  h4 O4 H9 {  V
                        rgManager.tryToStartTransOrder;0 N! G& W$ v6 Q
                        if @.Destination = void
& w8 E- ^& i! k. f. A/ e2 A                        then -- no transport order for vehicle @
/ C; M) f, m" i% b                                @.Destination :=4 A; B$ c8 x- [' z" z4 E& H% h
                                rgManager.nearestFreeStation(@,track.~);/ j+ {4 B% C0 n5 G* `4 u# H- F" U
                                newDirection(@);   
6 ?+ N- {$ G) T* S% Q                                if @.Destination /= void then4 e  j) U% h* {5 y- i) b
                                        @.Destination.NumReservation :=
- H3 y4 J  ?" q) k  @" r                                        @.Destination.NumReservation + 1;
' S0 X  P; t. |$ Z3 H8 j( A/ Q                                end;6 ~/ o0 p8 d3 G! C4 m' r& p
                                @.CurrIcon := "drivingHome";1 M% ~+ U6 d# O1 I7 f+ A) U
                                @.DrivingHome := true;1 R- R, `% @9 B; a* @9 l" f
                        end;& i5 x/ N1 i) a
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station% c# x, f$ Y- |# R2 a
                        part := @.transpOrder;3 m) Q/ h& `) Z( e( W
                        part.move(@);-- load part) }: p8 N. M% d/ j) b5 f
                        @.CurrIcon := "load";
: F, T+ J1 p9 V3 ?5 p$ `2 ^                        GlobalDistObj := part.globDestination;# {$ D4 E+ N9 F% O5 b
                        assignLObj := rgmanager.rgAssignL;
6 g5 M) d) Q" {/ Z$ y, O; ?- \/ \" D                        row := assignLObj.getRowNo(GlobalDistObj);) H1 C& e# s+ u8 E
                        if Row = -1 then -- since 706 a! f) B( ^; G( p/ \
                                if lan=1 then
% r* B" U' z4 j- t. x                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),: s; G2 h& C* m7 w3 I" ?
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
$ c3 Z" S; u& [% H4 o5 E3 @; O                                else
# K0 a9 ~! s8 S$ E                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
) h) l2 [/ u: @4 R                                                to_str("in docking station: \"",?.~.name,"\""));                                # l% N7 X0 A( N: G) N- F/ _$ e
                                end;
5 K+ O% s0 o/ P3 f) G% z6 [) P' w                        else2 X% K3 o  f  C1 C3 f
                                @.Destination := assignLObj[1,row];
+ h- Y- Y* p- A& }                        end;                        ' H5 U8 e; F# M/ _$ z" c2 R
                        newDirection(@);
/ J+ Y" I6 \0 v- V% h& g8 C                        @.HasOrder := true;
, A4 c' B3 ^5 }% _  P8 ]' S                end;9 @; E, ?" S1 S2 |3 G8 b# U# H) E
        end;  c- l/ p) G/ {% x! X" ]
end;        -- of the method
3 t  I5 {3 f; c& U" J7 ~
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 - q7 o- O: S1 k$ |2 R; T

$ e3 \, m  ~  M. c  k" C8 c' J这是AGV_putin中arrive的method。
: F0 C* B, J7 g3 {" \: J" F; c% T  V! E+ I) o, G
当到达物料速度越高时,这个报警更多,: I# Z8 H3 B8 `: R( Q
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。9 ~- u4 j/ d* M" V6 w- C: v" E7 s: ~
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?) D+ G. v% Q1 q1 W% \" _4 L
5 K: |6 B  K% ^1 _) }. s& Z: i  _
另外一个小建议,就是move,所有的move都可以这样
8 ?9 Y6 y/ G! C. @if not move() then debug end/ b+ ]4 U- f+ \/ T$ V
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
- m: z# S: X5 j' t4 _6 splant simulation中的free libraries有AGV模板,0 r+ Z) _8 W4 F1 l
里面也有案例。
+ W& M9 f+ G/ d我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
6 C3 E# T$ s$ _6 h/ u9 @3 c4 B( p/ i  U! g* M5 K! l
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
( P0 T& F8 O! c5 `0 l# H: a* \
2 I% |! P' k# Z2 i  U那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 0 K5 v6 \/ a5 {/ `9 b* b
这是AGV_putin中arrive的method。0 E; c4 B. I1 @3 ~5 }* j

/ Z! w% b- }+ W0 S' k当到达物料速度越高时,这个报警更多,

- w2 f$ |( |( }& l9 [另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-21 12:50 , Processed in 0.017193 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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