设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6534|回复: 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': d1 X5 d" p$ Q
*/; u: \$ J# G  P; W9 G7 B: W6 ]& @
is
/ j7 w) x& i+ a/ M        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
: p8 u, ?" o  h% Y& s) |6 Xdo# o9 \, L" B! L
        Lan := rootfolder.Internal.Tools.AOLlanguage;& M5 B. i1 \& s! f6 ]
        if current = @.Destination -- else return$ O5 b9 d! O6 p' _. G
        then- E$ B. b( X: D, e( W3 U- o4 i( H. a% b
                @.Destination := void;- m- a0 E& r7 o2 w" w& R$ ?
                if @.occupied then  q9 ~1 y9 i4 N$ `
                        part := @.cont;
9 ?3 K: b/ j! b6 f                        @.transpOrder := void;
& d: y8 _4 i$ y* p                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
2 v9 V5 i( r0 S' x; ]' o$ V                                @,root.eventcontroller.simTime);
/ @' `/ G, @; P$ {8 _                        @.HasOrder := false;5 X/ N( s$ m4 q5 M$ E
                        @.DrivingHome := true;8 s" @( a% S  q( p' o9 q0 ~. I
                        rgManager.tryToStartTransOrder;
  g$ x* ^5 Q8 f4 e0 z" ?( s( m                        if @.Destination = void/ o, v7 ~1 |4 E1 j5 h# v
                        then -- no transport order for vehicle @
3 @( U1 ^; q; H+ }                                @.Destination :=% ~4 k1 d; x8 F: C! c# _( X* W
                                rgManager.nearestFreeStation(@,track.~);1 N* ~( m5 H+ A2 L" j
                                newDirection(@);   / F2 f# `" O+ I3 S# b+ ?! z( ]1 |
                                if @.Destination /= void then
+ f, E3 g* g3 X- X# m# h3 p' m4 O& L) P                                        @.Destination.NumReservation :=, m) F3 `6 {8 [0 Q, X
                                        @.Destination.NumReservation + 1;9 i4 t! j) j- ?: X) J
                                end;
& |8 u* B4 v1 _  V# e0 `                                @.CurrIcon := "drivingHome";
, e9 F( L2 V4 N. z                                @.DrivingHome := true;  [& [' D3 A9 Z3 ]- H6 c0 K0 U3 |
                        end;
# Q5 m; H# e8 D, Z) N# J0 L( u5 ?                else -- the vehicle @ is empty, both vehicle and part are in the same dock station- I# t; ~5 @4 i+ D8 D. f
                        part := @.transpOrder;
9 W4 I$ ]# ?! R6 S6 {                        part.move(@);-- load part
  M/ L, q0 Z, [$ ^! l$ [                        @.CurrIcon := "load";8 _, |: |7 ^/ S1 M
                        GlobalDistObj := part.globDestination;5 N4 ?$ }$ O+ j4 H- a, @4 f% N+ D
                        assignLObj := rgmanager.rgAssignL;
: w5 l" V2 X& N' J" Q1 R                        row := assignLObj.getRowNo(GlobalDistObj);2 f. Y+ G' g& n* @( c: B
                        if Row = -1 then -- since 70
6 H4 p8 a4 a' O- E                                if lan=1 then! Y+ y2 q0 E+ E3 S, C. O6 P5 ^9 h$ V
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
1 J/ y5 G. q$ |. V" X                                                to_str("in der Andockstation: \"",?.~.name,"\""));
7 V: k' o& H1 H6 B3 y                                else
/ U6 D% X  n9 S* S                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),' K" k2 A/ X6 P) }
                                                to_str("in docking station: \"",?.~.name,"\""));                               
+ H; Z& m% N  a# Y0 N                                end;
7 ^9 c6 H" m; g                        else- G( Y7 C6 a* v- i+ h% C  [$ Z
                                @.Destination := assignLObj[1,row];
4 |% _2 X" D( E& O4 J- C% A; t& ?                        end;                       
0 R' |4 g) J9 g0 Y6 X                        newDirection(@);
/ n. ^/ h3 G# L: H                        @.HasOrder := true;
* I6 Q9 V# Z# ?- I  U$ V3 P: L                end;
2 O' J; i+ B( [; w8 r. l, x6 Q        end;
' K5 [, d+ P- ]end;        -- of the method/ R* J) G$ [& F' ~
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
! Q1 S7 ^& L- N: w, |$ I
2 n! H0 k5 I* `6 n: E这是AGV_putin中arrive的method。
8 M; |% ^! R* @" N8 Y$ q+ g* ]5 P( D: h  d4 \8 b
当到达物料速度越高时,这个报警更多,
5 L- x1 O) i" z9 w6 s% \* p9 k可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
9 L* U/ L( Q0 ?% W$ O" o; M; w  ~程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
- F* V2 y, s/ u0 m
% {- F* a* ^9 t: A; z! Z+ v另外一个小建议,就是move,所有的move都可以这样' h1 J! O. Z7 K& O! ^& a1 F
if not move() then debug end, D/ K7 c" j- F7 a# Z$ s
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。9 D( q' F# T0 v
plant simulation中的free libraries有AGV模板,0 m1 y3 @: w4 X' y* m9 V0 }" ^
里面也有案例。5 Y  B. @- l9 l
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。3 z9 L9 Y0 g9 _( |& q, p' _
2 x) J9 `, ~4 C2 m  N& V1 S9 \
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑   ?7 D. X3 Y9 F7 o8 {# u

+ ?# H9 R5 R* D5 u. A" ]那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
' i5 h$ a% X% |9 ~3 M" m3 E7 [: c这是AGV_putin中arrive的method。; Z+ s) [) w: g) m- V" p

6 w& V) V7 M  |4 k: x5 }- m当到达物料速度越高时,这个报警更多,
" _$ h' P$ y1 `3 J( a6 f. T
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-11 10:09 , Processed in 0.020221 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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