设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6929|回复: 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': m9 Y5 r9 _( [2 h
*/1 `/ K3 ^, G, m$ d& r# a. Q6 }! ]
is3 y$ D# E! w# w
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;0 [: u( A$ d0 R8 w
do0 ^9 |; a& x$ Q( }3 S
        Lan := rootfolder.Internal.Tools.AOLlanguage;
6 z  R& G( |% F% }; T        if current = @.Destination -- else return
: j% C. O; X$ {7 O        then7 R2 E7 t) b0 \2 U; W
                @.Destination := void;
& O1 Z; t3 z, C) B4 R) v& b' _                if @.occupied then
7 h2 h# ?5 v" {2 l; [1 ?# K% j                        part := @.cont;; y  O" q7 f/ P( X. u
                        @.transpOrder := void;8 S" G$ n5 M% ^) B# n. ^% q
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,/ W3 I) _2 v& H, t; p
                                @,root.eventcontroller.simTime);) Y! W; N5 z6 T6 u  v- @
                        @.HasOrder := false;
7 ^) b3 y0 g2 m! l; Y                        @.DrivingHome := true;
# G8 |! a  |) u- h# b2 c                        rgManager.tryToStartTransOrder;
4 V; B1 U  f# S: X: F% `; @                        if @.Destination = void
( D3 O  i5 c. u3 ^) z                        then -- no transport order for vehicle @
* B  ]5 ~- G9 I. X1 l                                @.Destination :=$ F  N8 }' K9 p( l3 ]3 F
                                rgManager.nearestFreeStation(@,track.~);
1 o  V2 {2 `- h6 G; }( c; Q6 Z                                newDirection(@);   ( m4 N( `0 N8 @8 h: o
                                if @.Destination /= void then
. Q2 \$ b- r$ C1 l( E7 v9 d; K( X0 U! t                                        @.Destination.NumReservation :=# `$ l+ `6 w& o0 v+ K, Q
                                        @.Destination.NumReservation + 1;7 [7 B- J. {- N0 n( s
                                end;
" B" X* |* {+ X  d; R                                @.CurrIcon := "drivingHome";; u6 W- H& M; x6 y* d
                                @.DrivingHome := true;
9 H) f9 A% z( r3 t# e6 d! T& X                        end;+ N* g3 k5 _# j" I
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station; o+ f8 @1 z% d* I9 U" Q$ ~1 P: E
                        part := @.transpOrder;: ]# i8 l8 i) Q4 ^
                        part.move(@);-- load part/ f1 D* |5 @5 N/ U5 r
                        @.CurrIcon := "load";$ S% l0 w8 ~7 ~  s( x! r
                        GlobalDistObj := part.globDestination;
; [4 C2 b6 w1 @' U# ?                        assignLObj := rgmanager.rgAssignL;& M: {9 _+ A& {1 i
                        row := assignLObj.getRowNo(GlobalDistObj);
( i: v* y( Q( M* y# l" X6 n                        if Row = -1 then -- since 70
5 S; ?4 l1 r" t9 {* A                                if lan=1 then( _# W) Q9 J, m6 K7 W
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
9 ^4 h6 o$ z. _( g6 o                                                to_str("in der Andockstation: \"",?.~.name,"\""));
$ W, ~6 @8 p+ U                                else. ^+ _9 t9 u2 Z/ _' o  C
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
' r+ p$ ~7 j& d5 P$ ~                                                to_str("in docking station: \"",?.~.name,"\""));                               
; C0 J4 H$ U4 k3 ~6 ]                                end;
% P2 i+ g: E0 \% Y                        else0 ]& H: t5 G$ a$ y% L# G: v
                                @.Destination := assignLObj[1,row];
6 D& u% Z- i; T5 v6 A* w& j                        end;                       
3 h8 V  T+ v9 E' Y% ~# O4 l: l7 M' J9 G8 [                        newDirection(@);: T! U1 w5 U0 }9 z! {- J
                        @.HasOrder := true;
% U0 Y# m! N% h; ~: H( B, r                end;
1 X) R. N! R4 p  i, J" n/ ~4 [        end;
6 `+ k, z9 v5 G7 F; Mend;        -- of the method/ E% |7 ~5 X+ v! n: E; U4 V* B; W
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑   B, ~" c- V3 U% l0 |
, A2 ]' }6 t$ ?$ `
这是AGV_putin中arrive的method。" Z) f' Z* w4 ^6 f
* x- o. ]: s- ]3 y- a7 ^# ]
当到达物料速度越高时,这个报警更多,
5 d* b# V) W: |2 ?! K9 \; V可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
8 `' {, \; `: Z程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
  I1 G/ W# N) F' `% g3 N' ~/ l' H, \! O9 @
另外一个小建议,就是move,所有的move都可以这样
' Q; y" r: s* W. G9 m: [2 dif not move() then debug end
8 m: v4 r3 w; f' E1 S- K/ m4 e这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。1 M( |! M0 i7 p# e9 u
plant simulation中的free libraries有AGV模板,
& Z# y9 g6 |# Q1 E1 o里面也有案例。
6 _+ Z9 O6 P1 H/ Q. ^我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。9 A& C0 d( y  ^

0 N4 h! `! a: z3 }( s; U  T我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ! v0 i7 U" [8 H7 ~6 B
% d4 e5 v  C+ a7 T- t1 V+ l1 e
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
+ @" d! G! l; k' A9 H0 R这是AGV_putin中arrive的method。" |8 ?5 [; ~' Y3 W/ M. c
% g# D- o1 q2 \  r  u8 k5 L
当到达物料速度越高时,这个报警更多,

1 H/ |( |$ Z" h2 ~( G另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-7 04:01 , Processed in 0.028805 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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