设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6623|回复: 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'
; c; x  ^# K3 p*/
! [# H8 c3 [* r9 M3 b0 h2 T# `is1 E! g& [- u4 `  V: B" m5 I
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
- R* t5 g1 _2 M. F& N7 ado9 s0 z3 Y5 k7 J6 z
        Lan := rootfolder.Internal.Tools.AOLlanguage;8 [; M  \. |/ R' ^: Z
        if current = @.Destination -- else return' s9 b& S3 `4 A" d2 H1 ]7 P
        then
* z* [) c; g0 i                @.Destination := void;
# X& Q0 y  @) @                if @.occupied then' \. L3 w" o! k! F
                        part := @.cont;
+ ?/ y6 ^6 s* z: ]0 W6 `# R# d  Z5 ^. {                        @.transpOrder := void;( x0 \) w. ]  _' Z' z' g
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,. f( I# e" n3 n! q5 z# s
                                @,root.eventcontroller.simTime);
  ]# z& N0 |9 T) m; t' N                        @.HasOrder := false;* r0 q$ h1 K, u  O/ b/ U$ Z  Y5 B
                        @.DrivingHome := true;: M: B3 v  b" S  u
                        rgManager.tryToStartTransOrder;! {# D: v" R" s8 J. I0 n
                        if @.Destination = void
1 I+ T/ Q2 J; e                        then -- no transport order for vehicle @+ ?7 ~. T5 G: i% X
                                @.Destination :=
3 `) q* i0 |: ]                                rgManager.nearestFreeStation(@,track.~);
6 e; S. ], W" r9 Z! e9 G- b                                newDirection(@);   
+ T( H. r. z/ x' S9 u1 w( F* m( r! \                                if @.Destination /= void then# Y0 A1 d( ~& B+ ?6 g6 b( R6 j) m5 P
                                        @.Destination.NumReservation :=
( I& I2 v$ L4 O0 T( K                                        @.Destination.NumReservation + 1;8 n8 @% \6 C9 o( F. q- W( c- _
                                end;
$ V! C% J% J  i+ S" L1 p                                @.CurrIcon := "drivingHome";& X& y- O8 `% q: X( t3 L
                                @.DrivingHome := true;
& v% b9 L, N. S% _( Y) g& M                        end;
: h8 Y. E3 `8 Q; T                else -- the vehicle @ is empty, both vehicle and part are in the same dock station3 o% w3 L: H. M2 X: e. M
                        part := @.transpOrder;) N& Q2 L# Y4 E1 w: d3 g+ k
                        part.move(@);-- load part8 w/ m: W# g! I( u. K' r
                        @.CurrIcon := "load";
# W( X9 `4 u. g* y                        GlobalDistObj := part.globDestination;* a4 ]$ X- h$ z" J
                        assignLObj := rgmanager.rgAssignL;$ T; w: [7 z! S# r) O- i: e6 l% }
                        row := assignLObj.getRowNo(GlobalDistObj);/ e; Y3 L. |2 P2 P6 ~1 ~
                        if Row = -1 then -- since 70
' w& A# _+ y, U, ~8 e( `# ?                                if lan=1 then
/ y0 G; ]4 s  q& T+ P/ H" H                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),% p- A5 X# z% m  Z9 o. `/ S: \  Q
                                                to_str("in der Andockstation: \"",?.~.name,"\""));6 f6 ^9 P2 ~5 P' ?9 s5 @9 d
                                else
7 }0 i) l; }" B                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
( p9 r4 j& q5 B6 j7 t                                                to_str("in docking station: \"",?.~.name,"\""));                                ( P1 [- W7 ?8 W' F+ k
                                end;
4 R9 Y% {) _  Q# c* W0 }0 z                        else
3 W# T- R4 p+ i! j                                @.Destination := assignLObj[1,row];& y- N& {4 Q7 C; J- D  X
                        end;                       
# V5 q' x  j5 m5 s: q& _                        newDirection(@);
( z) B: F8 |& s0 y                        @.HasOrder := true;
- }- s( `" S/ \% x( E                end;
% n4 e8 w4 H, m        end;
5 Q7 C, ^: O, h+ g8 c2 send;        -- of the method
' A* C& C/ y+ ?+ y) p- M" _
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 % b! w! D  l6 O* {/ V4 i5 ]
1 u$ f8 H/ \) |7 S# m" y& T
这是AGV_putin中arrive的method。
5 H3 J+ i* c! p
" Q) O( W3 z& Y9 n5 s当到达物料速度越高时,这个报警更多,
7 }8 V$ U% l- M可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。1 h! |1 q; [. c4 j) P. k3 N2 e
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?6 j+ d. Q# H' i( o6 q: n8 M6 C
' ^, _0 M' Y4 K
另外一个小建议,就是move,所有的move都可以这样! Q7 r; w+ X' G1 o9 m: ]# S) k
if not move() then debug end; ^0 @/ F9 Z. Q+ ~+ p- T
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
) R6 Y* N- ]# Qplant simulation中的free libraries有AGV模板,
1 }( z1 {6 O* }( L0 \1 d9 r里面也有案例。# ?5 ]) Y' H8 O
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。6 [9 y2 ^% A8 G6 J) I
4 z4 {3 Y- L8 M. x
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑   M( g+ U; x# i
( {4 @. @/ e& w
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
* B$ {% Y0 p) T# c这是AGV_putin中arrive的method。2 _1 M0 z. U9 r% Y/ H9 K' i
  S) g$ P8 [+ U* W6 R* p, Y% X
当到达物料速度越高时,这个报警更多,
) T5 M  ]1 D" |0 @2 e* }0 I) o5 q: o& ~
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-16 23:31 , Processed in 0.017707 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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