设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8488|回复: 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'+ T4 j1 ]1 P5 z* T
*/- n6 l' Q. Z* i6 U7 n" O1 |  z: Q
is
9 W! ^  \9 y! J8 t7 a        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
( C) S' s) h0 z, g& ndo* n9 ^& O2 }" }$ K2 [( p
        Lan := rootfolder.Internal.Tools.AOLlanguage;
" T% D% q% g# J1 a2 d2 }        if current = @.Destination -- else return+ h# y# P/ ]( q" D5 P% W: J" j
        then5 `5 U. w7 P3 c1 d1 q* p( n
                @.Destination := void;& `- H* ]1 Z/ _, Z& a9 d
                if @.occupied then
: `3 y/ A1 U5 @5 j7 s8 t% b/ _1 H                        part := @.cont;5 }& i' H1 W' r' J9 a. E
                        @.transpOrder := void;
/ p3 N. t+ \- j( X. ^* T0 f0 c                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,, B" f' a. Z1 S+ w" f  I! }
                                @,root.eventcontroller.simTime);3 A; U" \# i6 I6 z5 S
                        @.HasOrder := false;( Q  o% w! U3 T9 a, R- Y) a
                        @.DrivingHome := true;( {+ h( h  g2 O2 j4 g
                        rgManager.tryToStartTransOrder;
$ h0 y/ g( X: w7 J# c; ]                        if @.Destination = void- h9 G& w) ^5 v$ [- |0 N5 G
                        then -- no transport order for vehicle @9 U( s! [& P& y, ?8 ^8 |# {
                                @.Destination :=& _* u' B: h7 ^1 u
                                rgManager.nearestFreeStation(@,track.~);" V8 ]  d* r9 |+ I3 r* [
                                newDirection(@);   - F& w+ i( k9 Z# I3 B
                                if @.Destination /= void then  q" p( ^2 P# m5 Q4 T, h
                                        @.Destination.NumReservation :=- m( T. X; O9 y4 Y
                                        @.Destination.NumReservation + 1;
2 ?/ m+ q& b5 L% ?9 t                                end;' B0 B. T- Z- w6 t5 t- a2 i% T
                                @.CurrIcon := "drivingHome";
! N6 Z+ d. ?+ u1 p% J. v                                @.DrivingHome := true;, ]; J! U# M0 V9 Z
                        end;
, h) f! m3 j8 h+ T% |                else -- the vehicle @ is empty, both vehicle and part are in the same dock station7 w$ {: X+ d$ C! W
                        part := @.transpOrder;- G. k7 Q5 i- C
                        part.move(@);-- load part9 B: y# ^; y" s( ~+ `- j: J
                        @.CurrIcon := "load";1 Y; T5 A2 z/ N& n& L
                        GlobalDistObj := part.globDestination;
9 U/ l% j5 h3 \# J) `% ~                        assignLObj := rgmanager.rgAssignL;  }* M; E  W1 i# R
                        row := assignLObj.getRowNo(GlobalDistObj);3 U( C: Y7 H( [& h4 n
                        if Row = -1 then -- since 70
6 ~5 j# D( s% p) g. N" y0 [                                if lan=1 then0 H* n; G; s7 e/ A/ ^4 X
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),' K! p( Q/ i) u' e
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
0 E7 M$ k+ \: U2 E+ W                                else
9 T5 B6 ^, x, E& k                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),( f& P* y# A. ?/ i$ j, ~+ I
                                                to_str("in docking station: \"",?.~.name,"\""));                                / Q4 G- [6 g* r, W2 g( s+ T
                                end;
* n1 n7 h( a2 s+ {                        else: R9 |) a& N1 Q( Z; k; s8 A' h
                                @.Destination := assignLObj[1,row];1 D3 `  ~; h3 L$ i0 Q
                        end;                        ' ]6 F5 K0 x9 @% v' M7 q# q6 d
                        newDirection(@);' q' }4 W0 _/ A3 r
                        @.HasOrder := true;0 ]0 T! k7 C* O; h4 c. J
                end;
% j+ a+ a- k" U/ U! v: s8 x        end;+ M) m7 v# c5 L( k1 w* @
end;        -- of the method
4 n" c3 F7 H% w4 X0 W. X3 v
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
* m( Z7 ]: I0 y6 h& y# P; b1 ~) {. p
& v* f- q/ j7 F2 n. `+ U2 t这是AGV_putin中arrive的method。4 S% [2 ~- Q  h/ t2 N

' K  }3 X6 i7 K/ G% w1 ^" J; k5 G5 w当到达物料速度越高时,这个报警更多,; {. k+ B# a* @0 j
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
9 Q8 T3 B- O  j$ u程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?8 Q: p- A& e6 J1 P+ f

: y8 d% H; J  {, d9 r另外一个小建议,就是move,所有的move都可以这样
* ?/ w* t) |9 h# f  S  Rif not move() then debug end
) A- p. I% K  K* _! n这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。/ e% d% L! e3 f5 ?
plant simulation中的free libraries有AGV模板,
" W+ a/ X3 d; N5 t: n/ w' Z里面也有案例。
3 l. Q9 ]' J5 ]我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。( a# ], q: W* ~) T
, _8 r- ^# L8 C1 {3 d/ f# v
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 % a  M% ?; |7 n5 Y; K

5 u& S& B7 L6 C; i4 }# L. z! E6 ]" T! S那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 . U% s) X* d# f2 g. i& M  _
这是AGV_putin中arrive的method。
- u3 _5 {; n/ G/ g
! k9 r+ o; H5 W0 o1 j当到达物料速度越高时,这个报警更多,

9 L+ v: b7 Q! H: {另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-7 02:50 , Processed in 0.016809 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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