设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10162|回复: 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'
1 G0 F8 i, V7 G0 a. `*/
' u" Q+ p! [$ {is
% J8 Q7 v  X+ e) ^! F" ~        part, GlobalDistObj, assignLObj:object;row,Lan:integer;3 {/ E- R# b4 \0 a$ i4 m- A
do
+ L' n  C( Y5 W. F- [        Lan := rootfolder.Internal.Tools.AOLlanguage;
2 |1 ]. I! {; Y# U4 {$ X        if current = @.Destination -- else return1 u/ V: n3 B8 b0 t9 H9 i
        then% r9 y# |# R# U4 ]7 }5 _& K
                @.Destination := void;! X  ]  ?  E- a" e6 p+ t/ o) l
                if @.occupied then" F& k) B( Y* \' x0 l' s
                        part := @.cont;2 P- N( G" m; `4 t
                        @.transpOrder := void;, c3 C' X% z1 r% T1 r. A
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,' B: ]; ~8 ^4 P  r
                                @,root.eventcontroller.simTime);! a5 ~+ q5 s5 ?! r% {
                        @.HasOrder := false;
8 ~0 M$ y1 _5 ?" y                        @.DrivingHome := true;9 I& F% T9 \; G
                        rgManager.tryToStartTransOrder;+ X/ A3 k7 \; f" o! m
                        if @.Destination = void
& S. b* m6 b0 h# V, c                        then -- no transport order for vehicle @
. v  v* \! E: {4 s                                @.Destination :=1 t9 _) c! G5 V, J5 u5 D1 g
                                rgManager.nearestFreeStation(@,track.~);. P! r) y2 T- j
                                newDirection(@);   ( x7 I) g+ B/ K4 G* R9 x, I
                                if @.Destination /= void then
" j7 s- i9 @% k$ R3 |                                        @.Destination.NumReservation :=
7 M! Z" Z3 u) h% w" D: X                                        @.Destination.NumReservation + 1;
, i: [5 Y" w' H# d+ E9 h! F1 z                                end;
3 n; C0 G# [2 ]5 o( H% G  H! N# z2 d                                @.CurrIcon := "drivingHome";/ f6 y( B* w4 b+ G
                                @.DrivingHome := true;- H) R+ M" @% Q) Y3 x3 A9 X
                        end;
" e" w2 {8 [# J                else -- the vehicle @ is empty, both vehicle and part are in the same dock station+ m6 ^4 B" D# B( {
                        part := @.transpOrder;# R, f& u/ m# C1 S( U1 N
                        part.move(@);-- load part
4 {: l8 T' M7 ^: y# s/ |                        @.CurrIcon := "load";
: r& h  h& M6 ?- w4 G' G% g7 ]                        GlobalDistObj := part.globDestination;& ~& l) F" V9 u4 e2 p7 w1 I
                        assignLObj := rgmanager.rgAssignL;, L" w3 {. b' j
                        row := assignLObj.getRowNo(GlobalDistObj);0 U1 {2 ~% F& `$ }! E
                        if Row = -1 then -- since 70( v1 R* A; {6 s* _; q
                                if lan=1 then+ h& G+ w- g6 X: y+ d/ s; v
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
8 U: D# P" r4 Z/ b8 |+ m                                                to_str("in der Andockstation: \"",?.~.name,"\""));& F; n7 v( s& b
                                else
( i3 C! M9 q8 D. q, L  o* S                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),7 Z7 v+ v0 V- v" r3 y  d
                                                to_str("in docking station: \"",?.~.name,"\""));                                ; m3 K( R2 q# F
                                end;2 w( k9 a/ G: ?6 _2 }
                        else
2 g9 V3 d: }2 p0 _7 |7 @; K                                @.Destination := assignLObj[1,row];
% U3 C0 }. _% {7 h                        end;                       
8 v' N" d# E9 K2 E  n6 r+ g: ^8 b& `9 a                        newDirection(@);
+ A: ]+ q& S; T7 P                        @.HasOrder := true;
$ ]5 b# }- g3 [6 x7 D1 f; j" G                end;/ n/ h! I! p1 F$ T* P0 X7 C
        end;
, ?/ e' d2 @2 v6 C9 x- }end;        -- of the method  Y# J; z& J7 c+ h( h+ c
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 , K$ q) V5 K+ J/ V9 C4 U7 I
) d/ l3 G0 \  D& r3 n  E
这是AGV_putin中arrive的method。) H+ a7 g) o# p$ `
( X; _' E- }" P' R
当到达物料速度越高时,这个报警更多,/ Z  S$ i+ j$ i5 Y
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
% w; z: n" u: b: D7 h程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?; n9 V  `, ^) h5 O6 @% l! S

2 |, Z& t% a+ E, `* N2 h) v& [另外一个小建议,就是move,所有的move都可以这样9 Q9 G5 Z4 `5 K" ~; Y2 K& w9 P
if not move() then debug end
* ]0 d2 D/ o4 I3 q8 g$ R% k6 I这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
5 B: g0 p0 }2 V0 hplant simulation中的free libraries有AGV模板,
" N3 |9 I5 C, K: o里面也有案例。! q! F' R1 Y9 a# ?5 \" U, Z* D# S
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。% @' |5 p$ V; O- B

9 g. W& O/ G- J我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
7 L8 ~7 t1 S4 i( q
7 X% ]  U2 H% R4 r  q! j那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
4 |1 G" _5 Q0 F! x9 R$ z3 O这是AGV_putin中arrive的method。
/ y% o. O% y- j5 |$ [# u6 N0 l, |' f- J3 }$ C) f
当到达物料速度越高时,这个报警更多,

& }4 l' D$ C" E, ]5 y. O另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-17 12:12 , Processed in 0.018317 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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