设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6870|回复: 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'  t2 f* R7 v5 c2 `
*/0 i" p4 B6 i- L- w" b0 A1 L( H
is6 Q+ y  s/ k) z+ ]1 Y
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
8 }4 x% g2 D3 u8 Ido5 D0 D5 G% Y: c" c; {
        Lan := rootfolder.Internal.Tools.AOLlanguage;
# ]; ]  a. S( g# a& a* ^        if current = @.Destination -- else return- S  I6 q7 F9 u- V7 o
        then
$ R3 E6 c0 k1 |( }3 ~& l& N                @.Destination := void;0 Y+ q7 y1 q; m! y9 u
                if @.occupied then
! A: r' p3 ^5 i: L( C& V                        part := @.cont;& l2 j. ]3 ~; c3 A2 y* U
                        @.transpOrder := void;' V, M; h/ T5 ?: k: u! Q! u; t
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,7 K( _% z* x3 K4 }. A9 z( m/ n3 p
                                @,root.eventcontroller.simTime);
7 A9 P0 V# c1 N( ^/ M* s0 f( H2 Z                        @.HasOrder := false;  W# Z! \6 z2 i0 r3 B! x, Q
                        @.DrivingHome := true;
& f0 S9 R7 F8 p# N! T. N  y" w                        rgManager.tryToStartTransOrder;7 T( ?! U' g! f2 a  H' c. P2 {
                        if @.Destination = void, N: f* V  N: M
                        then -- no transport order for vehicle @. m/ O0 \/ [; O% v, R
                                @.Destination :=
) G1 _! a' _0 J# u                                rgManager.nearestFreeStation(@,track.~);
  `& S- L5 r0 Y- z                                newDirection(@);   ! a1 {) _( f. M5 l' k8 s' T
                                if @.Destination /= void then
- i. q$ U4 p5 s1 J8 N                                        @.Destination.NumReservation :=7 ]2 y' x' K: R' Z9 c  k5 @' C
                                        @.Destination.NumReservation + 1;
" p, x6 O  ]' @; x) Y  v5 P& z                                end;
6 ^8 ^- L1 A3 p) B                                @.CurrIcon := "drivingHome";
- @$ d& c& F8 k& [) K1 {                                @.DrivingHome := true;6 I" N3 G. \2 s  N
                        end;
/ c! h$ |5 v$ `* y: P8 G5 A- Q, P                else -- the vehicle @ is empty, both vehicle and part are in the same dock station; M' X& Q  `6 ~! G1 Q
                        part := @.transpOrder;
" w. N4 w5 \! x) c$ }; l                        part.move(@);-- load part2 J0 ~# x1 W9 g# w# l
                        @.CurrIcon := "load";0 r! f/ ?. W4 t( h6 ^) w/ B8 {: X* A: G
                        GlobalDistObj := part.globDestination;
5 r; V. d) A& E8 \9 t1 Q7 i                        assignLObj := rgmanager.rgAssignL;
) \' ~: P( r  [0 W6 \% x& m3 V                        row := assignLObj.getRowNo(GlobalDistObj);  ?5 R; I. J% o% k
                        if Row = -1 then -- since 702 Z7 V# f) R- A* v( k
                                if lan=1 then' E9 b& T" c* b* Z: y  S! v2 c
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),9 O, i/ _; @8 M, _  W2 }) D1 s
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
% |" }$ p( h7 Y7 z# g                                else
' y3 ^( ?; h2 X5 c/ [                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),! o6 K/ w7 y% l" t' }
                                                to_str("in docking station: \"",?.~.name,"\""));                               
: z  _. h7 C- I3 U% m  Y2 v1 |4 G                                end;. G" H  `/ H4 v2 W1 Y/ x6 h
                        else0 @  B. g8 I+ B: c* ?
                                @.Destination := assignLObj[1,row];  P. l4 t. k$ `
                        end;                       
" Q9 |$ N4 G4 P+ I8 p; P                        newDirection(@);
4 Q3 S' e3 _' ?; P7 [                        @.HasOrder := true;
7 a. s7 D/ ~) B                end;: h8 h  F. K; O7 h/ U6 C1 v2 @6 l. j
        end;
! Q6 [: Z. q% f: c7 U5 Y$ ?6 aend;        -- of the method0 o$ n, g0 S( J4 o+ @
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
6 k6 t6 q& D+ w( F2 c
! H! O3 T) z% Y2 e- c5 I这是AGV_putin中arrive的method。0 \/ L$ {% L" O
) g2 s2 L4 x# k9 ~& P4 U7 u
当到达物料速度越高时,这个报警更多,
+ B3 X/ n) a4 e1 @可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
; V, i; |% U% y" D$ i程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
8 M) n) ~" b  |, q
5 ^1 e2 I5 O+ T; b另外一个小建议,就是move,所有的move都可以这样
- m& h/ e# u# D! ?/ I+ Qif not move() then debug end' s- O1 c9 J1 N" j  h7 q5 y9 f
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
9 t$ R: n# O$ {" mplant simulation中的free libraries有AGV模板,
' Q9 t( X1 Y  i4 r里面也有案例。% n( O: _5 U" Z# Q: \+ B! e
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
; `" E& x5 M/ o% N9 y- u
" ~& N( g0 j, ~( z3 J$ Z, @我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
. ?4 s& w; p  \+ x9 X7 }+ w6 `. x$ g8 C5 Y5 N
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
/ ?  a: h  Y/ |- X! s6 v这是AGV_putin中arrive的method。
* G7 g( X5 ?" ~! k* w0 D* S0 Q, u( o! u5 g! k; x- t
当到达物料速度越高时,这个报警更多,

7 E0 ~& e$ A5 ?9 D9 e. x另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-3 21:37 , Processed in 0.017592 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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