设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5479|回复: 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'; p6 l5 C3 a% {7 U2 k. H  M2 k
*/; U4 W# B: s0 Z
is
' S5 }1 ?/ t) k$ o; `        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
9 N! q4 [1 f3 s; V& b6 ?do
1 S+ R+ ?, ?* \        Lan := rootfolder.Internal.Tools.AOLlanguage;! W7 ?  ^: ~1 O$ ]& z6 z
        if current = @.Destination -- else return
0 P5 s; Z3 {$ f1 _# r        then
. ^/ @' [9 H* X4 {/ c  X- @. u/ I                @.Destination := void;
4 F" ^" y5 U. k. t2 U/ H# Z                if @.occupied then
' Q# ?0 `1 i! p: c  ?6 f! q                        part := @.cont;
% }& h8 q7 @0 V! V' g! V; W                        @.transpOrder := void;3 ]& h- R. u: b8 [: O: w
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
  U# i3 V9 h) l3 S! R' D" A                                @,root.eventcontroller.simTime);
; A" j, s  E: e4 Z                        @.HasOrder := false;6 F* f' o" m0 t; ^" Z* {
                        @.DrivingHome := true;
& D" ^% X" b9 k7 }& u                        rgManager.tryToStartTransOrder;
5 ^5 y1 K; n* N                        if @.Destination = void; g/ |3 L. U6 U/ [% s+ u( ]
                        then -- no transport order for vehicle @
- @, h+ B( t4 h) A4 k                                @.Destination :=( i% f# C+ p8 b: w9 s' X3 ^0 w
                                rgManager.nearestFreeStation(@,track.~);
9 s+ Y" @' V$ h& _& n" b& c                                newDirection(@);   0 R. G) ?/ J8 `0 P
                                if @.Destination /= void then
# n, a1 j6 c5 K1 J$ {- s. R                                        @.Destination.NumReservation :=( e2 p0 c, N/ I
                                        @.Destination.NumReservation + 1;
/ C5 C9 N( A& T) I7 P) I                                end;# y5 q: Q5 U, F& A6 T. k
                                @.CurrIcon := "drivingHome";* f4 o( k2 C( T7 \
                                @.DrivingHome := true;- V+ J$ T5 W7 y" y' y- D  j! A
                        end;
$ o( t7 }- Q1 Q( Q4 x& R2 p                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
  ~0 u3 N  ?6 }7 l# x* k. M& T. v% M                        part := @.transpOrder;
% b+ ]8 {) P/ w3 q/ A                        part.move(@);-- load part
4 d' _8 `* q( G2 d* X                        @.CurrIcon := "load";. }0 U! z. f4 a+ X; _2 f
                        GlobalDistObj := part.globDestination;* s# U+ t$ h* c2 w; W! F
                        assignLObj := rgmanager.rgAssignL;
/ n1 t6 `- y. p! M                        row := assignLObj.getRowNo(GlobalDistObj);
0 [3 }8 ?! H$ e1 A& M                        if Row = -1 then -- since 70( ~/ o# H& u) u3 w
                                if lan=1 then
% F( V* D  `. s1 c                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
- ~) L# W* w) |, W1 A. q4 ?' \* [                                                to_str("in der Andockstation: \"",?.~.name,"\""));9 p; z& D' O! B8 T% J8 G
                                else* V) v" U2 r# k% }! V
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),3 u. M4 X9 `/ C  W) F
                                                to_str("in docking station: \"",?.~.name,"\""));                               
) C6 [$ A6 p! c                                end;! g# f& J' H% k3 v! V' X; y7 q
                        else1 w! t; l% Z( M$ p* Q+ G# L+ ?
                                @.Destination := assignLObj[1,row];
! D0 _/ M# c! h5 @4 n                        end;                       
" t0 S$ K* f# T5 r3 O                        newDirection(@);2 r# p+ L# u* c" q; M3 K
                        @.HasOrder := true;, M: O* D+ B) p1 A/ y7 t- ]
                end;4 r* [2 u4 k, G1 m; R2 h
        end;  a  P* x7 q4 ]1 f
end;        -- of the method
$ `3 v' w. [. R2 |9 h4 D' E0 p
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
+ h, L) m! |6 }5 e. M: j7 J3 F$ j, K0 d7 r( {7 \; K
这是AGV_putin中arrive的method。
0 @6 O. n: [0 h' n4 Z
% _, B' p9 V2 Y+ Y  I当到达物料速度越高时,这个报警更多,- |* l7 G4 `4 f0 P
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
, H! D2 i, L% q6 u' Y程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
+ [) F* e) r4 P  p4 I9 x# Y6 m0 I& I2 n6 ^9 m
另外一个小建议,就是move,所有的move都可以这样: f/ J( V( K7 J) L
if not move() then debug end5 H+ C9 _9 n& x
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。! s! k2 U7 q& F% s
plant simulation中的free libraries有AGV模板,6 t; ?# _2 E5 w+ e% L" ]
里面也有案例。; a0 W3 h$ K5 o" F1 t* r- Q, |
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
6 f& S5 Y; x/ `# b4 e, H4 n) J5 S& ?( G/ T7 v# K, v: W& i1 s2 [4 r
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 . q8 d9 [4 F# a+ _$ }. P' `9 |

1 G7 K5 c6 h5 l* S( ]那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
5 F# B/ k; r# _. G6 E$ z' g这是AGV_putin中arrive的method。
/ U2 L) V$ Y7 W/ H, P/ q: y$ G9 _; O% c$ L  J
当到达物料速度越高时,这个报警更多,

8 R& q4 O$ h$ g' X. t另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-11-26 15:20 , Processed in 0.025336 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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