设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7897|回复: 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'$ [( }# f3 Z! `
*/! }8 j/ n5 H, E  K! \2 E3 X2 m( _
is
7 G( R7 p% D# F" p        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
4 e! P8 R7 O% ]8 Edo4 N/ B' A! [# @6 _
        Lan := rootfolder.Internal.Tools.AOLlanguage;
2 |" x* _4 S7 @7 o* R$ Z        if current = @.Destination -- else return
' `4 i( H( O. h2 g' M! Z        then
& Y2 A( M  e% V* ~" d                @.Destination := void;, X# P/ Y6 _- e8 |& t
                if @.occupied then. `$ B( V3 C$ Z
                        part := @.cont;; `' F$ H, w+ ?" Y
                        @.transpOrder := void;
$ e& z+ N1 k; g4 @% k5 x                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
; b* g$ q1 {" f                                @,root.eventcontroller.simTime);
1 e! n  e1 ~3 @& E3 A                        @.HasOrder := false;
+ Y5 @1 K1 I# R                        @.DrivingHome := true;; v& q1 X% S; O: ]' B1 m( L
                        rgManager.tryToStartTransOrder;
4 u2 F/ i4 N. F1 m* a# Q1 x5 F' b                        if @.Destination = void3 A$ e. d9 q' m" w8 k
                        then -- no transport order for vehicle @4 Q, T" V& G5 G1 y7 k7 _, D
                                @.Destination :=
- W9 ?2 g1 @0 G/ ^                                rgManager.nearestFreeStation(@,track.~);9 M7 a5 C- h5 M# \
                                newDirection(@);   
1 x8 Q# b0 c  X/ n                                if @.Destination /= void then
: a1 q* j! ^+ z: d; U2 j+ B                                        @.Destination.NumReservation :=
3 ~/ S( ]( [" d; R+ ?1 S% q                                        @.Destination.NumReservation + 1;
8 j) s/ K' V7 W' x                                end;# U$ J; t3 P; o
                                @.CurrIcon := "drivingHome";
! d' L7 S3 _$ d) }( B* ?                                @.DrivingHome := true;
5 M3 @( K  Y$ p; L' u                        end;1 ?* x9 E) Q2 W% K6 y8 J2 \
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
. @. ?; c& V2 X: R4 H                        part := @.transpOrder;
+ q+ t! i4 k9 v( u$ f                        part.move(@);-- load part
; W3 v2 B$ ]3 A" w                        @.CurrIcon := "load";
/ Z% s! r! K: v) F                        GlobalDistObj := part.globDestination;, g5 R  u" c7 n
                        assignLObj := rgmanager.rgAssignL;
4 s3 s  U/ h' T+ C, E                        row := assignLObj.getRowNo(GlobalDistObj);" |7 ~. k$ N' b4 [$ M' d7 t
                        if Row = -1 then -- since 703 |( e: U' x% @* g" {
                                if lan=1 then
4 h+ s: j' C) i8 E8 @, C% A                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
9 }* J2 Q( s% n, `5 B                                                to_str("in der Andockstation: \"",?.~.name,"\""));; U# \+ q* r7 Z3 U# ]
                                else
8 Y0 c# r" W" M0 e; g1 U: ]                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),+ _1 ?9 b$ ~  x: \% p, l' D
                                                to_str("in docking station: \"",?.~.name,"\""));                               
( q9 S, D; a) C+ i' F: {8 Y                                end;
& |) Y5 n+ `  f                        else+ ~0 U3 N' d, J7 H
                                @.Destination := assignLObj[1,row];# U, E: V- R4 q& T4 {- u
                        end;                       
+ A' _/ w4 T% r* ~  D5 J5 {                        newDirection(@);
# M6 B% ^* Q& b9 W- n                        @.HasOrder := true;
) T8 B- g' L+ A8 i+ A2 M                end;2 Q; ^& t: f8 H) [, J
        end;* o% i! F/ U+ o
end;        -- of the method9 d/ h1 j$ D# {. J6 c8 Y
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
% C/ _2 s6 a  W! m3 t
$ I! b3 t. R0 b  c& ?这是AGV_putin中arrive的method。+ e) p" \2 z1 O. Z
3 t' ?) v* v% [, {& z
当到达物料速度越高时,这个报警更多,
" G1 i# A" t( L/ @可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
9 m, g$ l# I0 V5 Q. M6 D2 z程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?5 H+ k5 \/ M. o, K  y. x9 p, i

: C4 K3 R9 L4 k' ?* E; [另外一个小建议,就是move,所有的move都可以这样
$ F6 ]$ l+ h9 L  A8 `+ \. r5 l- e+ Qif not move() then debug end
3 Q$ |% h3 V% B6 g& A这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。! S/ {7 m# o1 K1 m+ n9 R
plant simulation中的free libraries有AGV模板,
  K' O8 u: V3 O( x& k里面也有案例。
' F2 y5 A0 K$ V我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
. w6 {1 ~: p% S, i4 Y) ~5 G9 S. d2 A/ j' t9 ?( U
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 3 H2 q+ Z$ U1 O$ {, v

# t+ e4 O$ {# F. ~: N9 G那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 5 j* n+ l+ x& [
这是AGV_putin中arrive的method。
- n2 U( Q5 C1 V) O+ M8 Z( ?4 ]0 m- F# M) m/ ^
当到达物料速度越高时,这个报警更多,
0 g& ?* g5 m& I% p6 m
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-3 22:43 , Processed in 0.017926 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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