设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9077|回复: 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'9 p. N% Z8 v) n" ~9 Q4 G- z7 _* `- f' A
*/+ [0 r) V5 M0 {4 [
is+ Z1 ^, H  `! P3 I
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
) I% N  @( z8 M. c4 ido
) f9 ^% Z+ ~) @: s2 k        Lan := rootfolder.Internal.Tools.AOLlanguage;1 d* F5 J$ j2 M; T4 O
        if current = @.Destination -- else return5 r# j/ |) j. i8 {
        then
( a3 ^5 s( Q  q$ p                @.Destination := void;9 x# j- u% w  h
                if @.occupied then9 f9 [: ~+ a( z" S$ T
                        part := @.cont;3 k1 X, o* L8 w: M0 o
                        @.transpOrder := void;2 o1 W0 u2 U4 T( j4 @. f% Y
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,& J) L1 C! j) `0 W! x
                                @,root.eventcontroller.simTime);
0 ~' k( V- A  D6 c  Y8 D" F/ u3 d                        @.HasOrder := false;
3 o4 w9 _+ m8 \$ L                        @.DrivingHome := true;
# z: D- r- Z2 t+ Z                        rgManager.tryToStartTransOrder;  u- }+ q) H5 w/ K
                        if @.Destination = void8 W& B' M8 W# q4 b' z5 }/ J* C
                        then -- no transport order for vehicle @; A8 ?: k9 ^8 i- e& P( p" P
                                @.Destination :=. o4 j+ t/ X% o
                                rgManager.nearestFreeStation(@,track.~);+ J9 m, b7 X2 N$ c& b6 D3 a2 _
                                newDirection(@);   6 T. X$ n9 r- C& b3 y, n) V
                                if @.Destination /= void then
+ Z" R& @) D9 J/ A2 [8 L' Y                                        @.Destination.NumReservation :=
% g( T- I% \" R8 i2 l                                        @.Destination.NumReservation + 1;
) E6 b+ R$ r7 g/ L7 G& k                                end;$ F6 m( G( R3 O0 {1 g4 C2 k
                                @.CurrIcon := "drivingHome";2 o6 c4 O5 z$ ~
                                @.DrivingHome := true;  C! J$ V. y* k5 k& s( W: d+ |
                        end;# }( P( M! K8 M
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
- k8 o5 s0 G- `: W/ c, X                        part := @.transpOrder;9 W9 E8 _4 A$ S( M; d% ^; y# ?7 t
                        part.move(@);-- load part
% g' g& l; f! ^3 P0 J                        @.CurrIcon := "load";% i4 N8 v( [% g( u( I
                        GlobalDistObj := part.globDestination;. |. v0 I4 r( y% i. Y* l5 r( A
                        assignLObj := rgmanager.rgAssignL;* {  w9 n1 X& x! N6 `- Y9 h
                        row := assignLObj.getRowNo(GlobalDistObj);
# v, u- n) E4 q5 l! A                        if Row = -1 then -- since 70, n' @/ N( F0 |% F5 S* y+ @$ C
                                if lan=1 then  C' |4 C" J% i5 s# D6 `
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),, t) f( d3 G& c3 x, e
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
/ t& e- s8 w* f' u2 y$ F- c# I' a                                else
+ q+ N3 [; C! |+ t                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
. {$ q" [0 I0 q: g! B                                                to_str("in docking station: \"",?.~.name,"\""));                                6 b; K- d" Q6 X7 ?
                                end;% E8 _; d  W, U# F
                        else5 i! T6 {9 I/ Y' o; D4 g! h# R
                                @.Destination := assignLObj[1,row];- K+ G7 y2 x( l4 W* i
                        end;                       
) x, k4 k/ v( q0 v5 n                        newDirection(@);
2 B& a1 {. x1 O6 E                        @.HasOrder := true;
) E- c+ r, g+ M" G5 Y                end;
9 B0 v+ h2 }/ R: U5 k        end;/ C/ c. S9 e* U  m7 V! J2 A
end;        -- of the method7 h# _, x+ k, X; \
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 . O8 K! u6 d2 q# w: L

% y, D" J5 U9 d; i/ c这是AGV_putin中arrive的method。
; O6 K$ C7 V2 ?
/ t7 o' F* J1 I# Z3 H+ z当到达物料速度越高时,这个报警更多,* l" _! W; b5 k" k! ?  N
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
8 C" K0 j; J% @+ m4 z程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?2 K* ^) q6 t8 g( E
. A) ~  V. L  {; Q' h
另外一个小建议,就是move,所有的move都可以这样
5 p2 Z( t* t6 R. G7 X& ?+ nif not move() then debug end  v* S/ m- S' V6 u
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。' w" {% a, f& f- T" I
plant simulation中的free libraries有AGV模板,- {. T4 [' q' B
里面也有案例。$ Y- r  |2 g9 v/ p; c3 D  r
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。; y( ?$ R3 I# _9 @
' x. l. H& H; b5 `1 i+ V1 H9 ]
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 5 `& H, T: K% b2 F3 ~0 U/ c9 B
# ?6 D, ?2 h) j0 N8 T/ K* x9 g
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 , X# m" W( s* u! s/ l4 e
这是AGV_putin中arrive的method。: a5 L/ h+ s/ a7 H, U4 {+ h
* S6 G1 v; s9 U( J( X% I
当到达物料速度越高时,这个报警更多,

0 e) B  Z- t# Y7 C/ ?3 I5 D另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-12 02:38 , Processed in 0.014033 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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