设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8455|回复: 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'
2 i* J5 k: O& R% R2 g% U*/
  G8 Y% `& ^3 p  ~" Wis  ]: D! y, V4 X! d! i, X9 J
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
4 U. C/ z, f( S. g- Q  sdo2 ^3 e9 ~' e4 \+ X3 D5 c" d. v1 P2 Y
        Lan := rootfolder.Internal.Tools.AOLlanguage;
4 M1 K! p( D# i* D+ C        if current = @.Destination -- else return& S. a( ^; C9 k6 Z# ]2 d
        then! t1 l& m; j& A. n
                @.Destination := void;
, k% M  k0 `/ c: y% D5 w                if @.occupied then
) M3 R# P- A, x. }3 X                        part := @.cont;  }, ?) G% L3 V* b  j* e
                        @.transpOrder := void;
% A: x) a) k* {: v                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
9 Q: W. A% l2 d- ^5 V                                @,root.eventcontroller.simTime);
: W7 L: m1 o% i) N7 B, C6 S# v                        @.HasOrder := false;
& @% o2 k$ F2 p5 k  P9 r4 I7 q& W                        @.DrivingHome := true;6 X& n: V- g% X
                        rgManager.tryToStartTransOrder;5 c! e" f" H+ n  K4 M$ u) g0 m* ?6 G
                        if @.Destination = void1 U" n9 x+ |; h( G" R8 J4 Y
                        then -- no transport order for vehicle @
1 \2 [4 C: w- L/ ?: k' i7 j                                @.Destination :=
! Y* O' P6 [' _3 A# }' H# d* \8 w  N                                rgManager.nearestFreeStation(@,track.~);
4 s) M' h- o7 h' a$ R! B0 w                                newDirection(@);   6 [/ O/ R; Q' C
                                if @.Destination /= void then
) I- ]* U. i, Z! |) E7 T8 b& e6 d                                        @.Destination.NumReservation :=
; a3 P2 F, K+ {3 J                                        @.Destination.NumReservation + 1;7 M" d+ x3 G4 [) Q; J6 G( k
                                end;% d: D; l/ {( q9 Q/ N, j2 c& d
                                @.CurrIcon := "drivingHome";# |( A$ E2 [/ f: h
                                @.DrivingHome := true;1 y* H% D$ q& R3 [; F
                        end;
3 Y- s$ h& D! A                else -- the vehicle @ is empty, both vehicle and part are in the same dock station1 V' W" c8 C8 O& _
                        part := @.transpOrder;
% Q: B  Q/ i  i/ r9 H4 N                        part.move(@);-- load part0 ]- J4 M  G+ w
                        @.CurrIcon := "load";- r5 z$ g" t( ?7 W  Z
                        GlobalDistObj := part.globDestination;- o* u1 S/ ~2 l: m/ X# N  e  i' L
                        assignLObj := rgmanager.rgAssignL;
0 c) ~% C" |6 T1 U3 H                        row := assignLObj.getRowNo(GlobalDistObj);( g% |" K" s* d; t$ R! e
                        if Row = -1 then -- since 701 v# _, n0 i. P. z$ }- Y
                                if lan=1 then
+ h3 c; S1 n. M7 F# J/ |7 Q                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
. b- X. _- N! ~                                                to_str("in der Andockstation: \"",?.~.name,"\""));
- n6 M4 g4 G1 B* s9 u4 M0 W                                else8 [* n" ]+ ?+ P  s5 W4 W3 J9 N+ j
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
# O1 N- x* s7 O9 T2 e3 G                                                to_str("in docking station: \"",?.~.name,"\""));                               
8 d, M$ Q* r  E0 K! l* `                                end;
9 }" Y9 p7 U" C                        else# ]/ z3 ]- X. @* ~. c0 h
                                @.Destination := assignLObj[1,row];
0 y+ N8 x& H  f: I! I: f                        end;                       
3 |- b2 ~) u2 }5 e" a, C                        newDirection(@);
2 o0 I% \: x) d1 |3 ^- _6 E1 c  B                        @.HasOrder := true;
) X, x4 s. N, o6 g" U                end;1 m. K; @# |! r( h, t5 @7 N) n" u
        end;
: S% f8 f$ k6 L( {, ?: K& uend;        -- of the method# U) l. b6 G. b! y3 f
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 : }2 g$ |& y, i6 v9 @: m

, A& Y/ t% A. S1 |这是AGV_putin中arrive的method。( }  s8 _8 {. A# a% d! |3 X2 D( B8 z
1 S$ ?9 Y! K8 ]8 T' c. E" N8 U+ s
当到达物料速度越高时,这个报警更多,
, k; e9 r1 H1 G( m4 S6 @可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
0 {7 c& t4 z  w3 q" f" R) y程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?" M. f' D5 _2 n- I- U* z) O

- ~6 }5 s& u+ N" A另外一个小建议,就是move,所有的move都可以这样& J  n, p5 r# \* H# L4 Y
if not move() then debug end" e. [: x/ Q/ @+ c& Q
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。% N& E, Q) h, U
plant simulation中的free libraries有AGV模板,
8 `. S4 v: C" n  R+ n里面也有案例。8 J, x- v0 z& K3 t
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。) x7 q+ w: ]* M  }( ^* O
7 E0 `9 w' y9 P3 W
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 # _0 }# r4 X; \+ Z

9 o/ \7 {& E% B) k那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
8 `( E3 _4 ~* t) a- C8 d& p8 w. \这是AGV_putin中arrive的method。
5 U7 D- S3 Y1 E, N2 z; X& a/ ?# D0 G/ {/ H$ S! x
当到达物料速度越高时,这个报警更多,

4 W; R' E4 N# X! ^另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-5 01:10 , Processed in 0.019509 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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