设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8366|回复: 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') v  h! |$ k% ^3 ~: F5 [
*/
8 |# H) \' [" _( H5 |+ Ris
( N" }2 v- K0 r# e  l0 s- n9 L        part, GlobalDistObj, assignLObj:object;row,Lan:integer;! t7 w/ o6 |5 T
do# S+ {1 q  ^& e; o
        Lan := rootfolder.Internal.Tools.AOLlanguage;( Z' \8 ]3 c: q
        if current = @.Destination -- else return" o! D# T/ V/ E9 g$ w" _
        then' F& \: R4 A8 ?
                @.Destination := void;
. H% O8 N7 U3 u/ [& R6 w                if @.occupied then) B' t- u+ i1 g* u' y5 a( r3 M
                        part := @.cont;" D  n% J+ R# y( L
                        @.transpOrder := void;" f% z  M% H  U. j7 g1 e) k
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
, b' z6 L* [& i7 @9 G                                @,root.eventcontroller.simTime);
1 o  H9 L, A9 T2 k/ [+ Z+ P                        @.HasOrder := false;
! q+ A& y' k# t) z' W0 B                        @.DrivingHome := true;
! p. O7 q- n! X" @                        rgManager.tryToStartTransOrder;
4 E4 ?* @/ u5 k8 M& M+ \                        if @.Destination = void
9 U4 H. N8 n% c) H) ~( }1 d  }: V                        then -- no transport order for vehicle @5 K. J! R  I' l" Q) ~
                                @.Destination :=8 v/ a2 j: f+ H: ^
                                rgManager.nearestFreeStation(@,track.~);
4 l9 B; d2 |- h9 u2 z1 ~                                newDirection(@);     {6 D( C; r  M0 `, D
                                if @.Destination /= void then
% h" e# j/ H' w: \  X& i                                        @.Destination.NumReservation :=, N/ }$ S) f" M. u3 \' T( q, O
                                        @.Destination.NumReservation + 1;+ }0 ~; U% m# K9 X4 q  @
                                end;: L( z0 ~0 ?$ [" R
                                @.CurrIcon := "drivingHome";( h9 N- Y% b1 a$ n; f
                                @.DrivingHome := true;, w! ]3 k+ {6 e
                        end;
$ c$ h( Z8 s: n                else -- the vehicle @ is empty, both vehicle and part are in the same dock station$ q4 X! W  q3 a  q; s
                        part := @.transpOrder;9 S/ ^+ ^) g5 s3 S4 }
                        part.move(@);-- load part5 u7 c- u: [, @6 C+ c; z, v: l
                        @.CurrIcon := "load";" A6 E2 ]7 I/ A; b( X8 v- I9 L: v
                        GlobalDistObj := part.globDestination;
& `- Q  S& W5 M* w; i& W                        assignLObj := rgmanager.rgAssignL;7 d6 Z, t& q7 ^& l1 Y
                        row := assignLObj.getRowNo(GlobalDistObj);; v- G1 ?& C5 |, e/ [" C7 }0 |  C8 G
                        if Row = -1 then -- since 703 y- O4 x# y( I5 K* r; b) c4 x
                                if lan=1 then$ k4 M0 |: }5 y) A* F9 x# Q1 o4 u
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),$ ?1 {5 ~" t2 s. ^+ C9 k( G
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
4 D: L2 {8 L2 h1 g% M5 [                                else# z# V4 G+ {- ~4 ?. m, u
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
) P; o  n4 q  Z1 b                                                to_str("in docking station: \"",?.~.name,"\""));                                - D4 z  x$ j1 B$ e  ]
                                end;
/ w% B  i$ t% E' E                        else
; p; g, I4 C2 `& S% M8 R# D                                @.Destination := assignLObj[1,row];
+ U" X# I2 o, a; [                        end;                        9 E3 i0 H! O8 y* t% s
                        newDirection(@);1 ?8 |8 Z, ~) S9 }. B/ P: ^
                        @.HasOrder := true;4 \( j! w6 ^. [5 ^, B) E
                end;- ~* Z; L2 b: V( ]: t
        end;
; v* t* M9 D$ Z( T. c: Dend;        -- of the method
$ u0 h  l* q0 N# y* i" H# T
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 2 C, ]# b* C/ B6 c$ m+ c/ k  \

* G& `0 P7 x, `. h3 U- C这是AGV_putin中arrive的method。
* \+ ?) S) z# v" w( B( A0 O# _  V
2 g2 I4 D/ v5 Y当到达物料速度越高时,这个报警更多,
  {: {7 E  }6 I7 N/ ?可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
+ O  p( n! _! i" c, K6 {程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?# H# P' b4 u* T8 w& M- ]+ u! Y0 W
) L, ?% y) Y0 \4 [9 @8 t$ E9 h( J" g
另外一个小建议,就是move,所有的move都可以这样' Y+ {8 v' I, `4 a' }  p, ?
if not move() then debug end. ]: X8 |9 t! d1 q6 l& V
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
- u- L; E' m5 k* v( x4 p( ^/ }' k2 Wplant simulation中的free libraries有AGV模板,
* T; f8 q: G# e" I. \* y里面也有案例。
# S9 O" l" }' N, Z* d* f我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
8 `8 W  @: \) \; n4 R$ g: F0 X% K5 z1 t
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 % l$ p# t" @. X0 }6 F3 `' d
' D/ @1 u% P" N9 D
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
$ y5 r0 Q9 J; Y, E这是AGV_putin中arrive的method。6 N; Y6 a2 r1 ]) q( s9 y  V

! P+ k% ?7 C/ w7 }; h% q( ]- g当到达物料速度越高时,这个报警更多,
4 \" ]7 ?0 o' g# o/ U( P5 X
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-30 20:09 , Processed in 0.015531 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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