设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5806|回复: 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'0 L, N0 G. z7 }! t! e: X; F
*/
7 z: \2 @0 |/ R( s, T# ?is' A* @* r  y/ _
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;) \+ \0 L' Q& V) B
do& I; r# j8 O2 ^+ F* ~0 w0 q
        Lan := rootfolder.Internal.Tools.AOLlanguage;  @, r  z( d( Y2 D4 n
        if current = @.Destination -- else return
* g) ~# B+ k1 I9 x- L: N" a, G        then: Q3 K; O, g% A, ?- u
                @.Destination := void;5 c0 b0 `  h1 ^
                if @.occupied then" K: g; ?( u3 C. o. X
                        part := @.cont;
3 t9 l( p( O. \( v* k' M                        @.transpOrder := void;* g, q% g8 A+ g6 O- k( I
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,! I8 m: {2 Y% _6 B0 y- h. ^
                                @,root.eventcontroller.simTime);* |  w- K0 ]3 u+ T& c9 O  ^
                        @.HasOrder := false;
/ u6 d* ~" p" h  E                        @.DrivingHome := true;
. `  g1 c' u6 t" \4 X                        rgManager.tryToStartTransOrder;
: h; _, g& e$ v) s) y0 q                        if @.Destination = void
( Y& e8 q3 @+ O2 a8 G                        then -- no transport order for vehicle @" d. M; h# P% o$ Y! g
                                @.Destination :=
, w' I! }7 l: {! r  ^                                rgManager.nearestFreeStation(@,track.~);% G* z+ S% J# L8 e8 K& J+ u* b5 n
                                newDirection(@);   ( g' A# u3 [6 ?1 V! E, V+ [/ @
                                if @.Destination /= void then  ]3 @; s3 H) q6 B; X( _5 Z
                                        @.Destination.NumReservation :=' u) U2 Y! q* z
                                        @.Destination.NumReservation + 1;
& h+ U# S6 j9 n. n5 p2 j% k2 o! A                                end;6 j5 a( h" ^8 X, Q4 F
                                @.CurrIcon := "drivingHome";. D5 X7 ]) U  E6 O3 L
                                @.DrivingHome := true;
( ^  w$ I2 ~3 H: _+ _                        end;
( b+ V- A2 U8 B; f* G/ w& a                else -- the vehicle @ is empty, both vehicle and part are in the same dock station% j7 B2 a( P. Q8 N6 s- V
                        part := @.transpOrder;
4 U3 V7 L6 j# s8 D/ B: o$ p) s( t                        part.move(@);-- load part
& `7 L; U0 t% z; w  ~* c: z                        @.CurrIcon := "load";
" D- y+ `5 @1 r' G- B- O% c& ]; }                        GlobalDistObj := part.globDestination;
' \" e. N/ j; v, D                        assignLObj := rgmanager.rgAssignL;3 Y0 z& a& }  I2 ?+ W& |% o
                        row := assignLObj.getRowNo(GlobalDistObj);7 P; B5 e- P% @9 l
                        if Row = -1 then -- since 70
" I$ r$ G2 U' G+ W                                if lan=1 then: U  d3 [* N4 P
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),4 G+ z: H* v1 F7 J+ |6 P% ?
                                                to_str("in der Andockstation: \"",?.~.name,"\""));1 ]7 G$ Q0 V  O- F  |9 w/ V
                                else# w+ M2 T$ U& ~$ t+ {' k
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
. y( z1 T# |2 F% t! `: o/ L                                                to_str("in docking station: \"",?.~.name,"\""));                               
3 Q' R& L/ N  G! V9 i5 y+ \9 K' f                                end;
: @! F) G' i0 N* h: a, A; {0 Q                        else
. N4 y- F8 x( J$ K! Y                                @.Destination := assignLObj[1,row];
( H+ |! b* I: l/ v1 p                        end;                        $ P" R/ N3 `/ m9 I9 c
                        newDirection(@);
1 k# S4 y! a6 n! L9 W+ f! |                        @.HasOrder := true;
5 C& M; R1 w" B- ^! P: w6 `                end;' ]8 H# Z! s: r, g1 y% @
        end;7 d7 Y  j& X/ _# s
end;        -- of the method
( \% p% q* a" e1 O2 N2 V; q
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 % p9 F& M, a1 k; ~$ |- d' ]8 M! w

0 `# c9 E2 l. K( r' p这是AGV_putin中arrive的method。& S! W) Y1 G6 {& T8 ^$ c2 w: x

) h) X2 ~# W" l* q) W: k当到达物料速度越高时,这个报警更多,! Z5 H( p( y* x5 w8 t( c# ?
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
! A- v: R" z8 V0 a  ]+ a3 Y" B程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
  ?& [+ F/ R" x5 M. U8 @* e/ m) r
另外一个小建议,就是move,所有的move都可以这样. O" j9 [0 c$ A8 w2 u! \
if not move() then debug end
/ n1 X; \2 e# {) N* p. V这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
" D9 N5 d. r& Q3 M9 {" `0 Splant simulation中的free libraries有AGV模板,# l; p5 p) a7 \0 X2 ~3 n
里面也有案例。$ p& j  y2 p- Q' f3 ~
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。( ^) m( R" W; D  F1 k+ j

/ D' f8 ^% q1 g9 h我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
+ Z- o& J8 U! m3 g) G8 X# {$ P/ W* r6 x9 ?, e. l7 _3 M
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ; J  H1 B) Y. P. ^) V0 h
这是AGV_putin中arrive的method。
. H( U/ w: Z) b+ N! L# q1 g2 S0 q* W5 s1 L+ l% X
当到达物料速度越高时,这个报警更多,

8 |& z5 `6 ~9 H1 F: |* @另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-12-22 05:54 , Processed in 0.019993 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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