设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8211|回复: 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'* a% h/ N% `# U! N0 h
*/
: E/ t6 T" U1 ^is
6 C! J7 o" E2 {2 N1 E/ L" l        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
( S6 N. H3 ~$ K4 p& Kdo
4 h) P) h8 r) |3 ^1 `3 z, v# }$ R        Lan := rootfolder.Internal.Tools.AOLlanguage;
7 h2 H4 |$ ^# v6 N1 Q        if current = @.Destination -- else return
( w' ]0 a; H, [; _' Q6 K        then* s! O7 `/ a! ]( b0 `0 y$ i2 K
                @.Destination := void;' U0 @( u0 }# |
                if @.occupied then
4 w: Q$ [6 W) j2 F  e1 @: B) W                        part := @.cont;* D  [4 K$ ?6 V% R
                        @.transpOrder := void;1 I: `. @! m1 l( p/ |4 ], b/ p
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,8 J+ @% g5 h0 I
                                @,root.eventcontroller.simTime);
+ A5 S! R! Q9 P. l) `0 \% C* Y) N                        @.HasOrder := false;
2 _7 D; N- F" @6 k+ b! T. f# A                        @.DrivingHome := true;+ x# }1 u, E' d& x3 ]# H: ]
                        rgManager.tryToStartTransOrder;% ~( W0 _) [: C0 [
                        if @.Destination = void; G7 p2 j6 \- O7 R
                        then -- no transport order for vehicle @
0 Q% e! t6 N* W                                @.Destination :=
4 Y, `, }- p( Z" B; q. \+ R$ V                                rgManager.nearestFreeStation(@,track.~);
0 E# p0 Y" P2 d$ E$ P                                newDirection(@);   
, |6 b& C* ^1 D' E! n# C1 T                                if @.Destination /= void then5 |  w+ \2 |( b
                                        @.Destination.NumReservation :=/ B; p6 w3 t8 U
                                        @.Destination.NumReservation + 1;4 o  k/ \, m9 u  u& y: h) {
                                end;
0 a$ }5 |- C' V                                @.CurrIcon := "drivingHome";4 Q$ ^0 N0 S4 T
                                @.DrivingHome := true;* X6 z& L6 b* U, C) t& I) m$ [
                        end;
8 U0 [0 ?2 e& Y' z' w4 G                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
4 w* i( @. r3 a2 ~' O8 r; X6 S                        part := @.transpOrder;
* T  W( E/ ?1 ?$ U: [                        part.move(@);-- load part+ G1 A' x' F7 p4 V$ m2 E3 N4 i
                        @.CurrIcon := "load";) E- m; f" c0 V
                        GlobalDistObj := part.globDestination;: e$ f0 P' N# x; u2 Z( A
                        assignLObj := rgmanager.rgAssignL;
1 c9 h; H( L( q  N9 _                        row := assignLObj.getRowNo(GlobalDistObj);
! v7 G0 V( J4 g# `                        if Row = -1 then -- since 70. u6 V# n6 q) B7 i- U/ {* M
                                if lan=1 then
( e* f9 y3 y& i                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
8 x1 p( d, R- V% ], N                                                to_str("in der Andockstation: \"",?.~.name,"\""));
" B  u  R& @( M4 K* \/ d                                else9 _: k0 y; F$ j% \
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),: g1 O7 |% k+ ~* B
                                                to_str("in docking station: \"",?.~.name,"\""));                                " e; A9 |  ?3 K3 w/ k
                                end;7 Y4 G/ Y& b5 @3 w
                        else8 H3 a2 [9 W, k& H. T5 F
                                @.Destination := assignLObj[1,row];
! y2 L" N7 i( {4 F" w                        end;                       
; k  ^& s, u8 _* l  s                        newDirection(@);: l, x3 U7 f5 K* [) X5 ?0 w
                        @.HasOrder := true;
  o6 |& X% s4 L6 G) N                end;
6 i3 c" N, I" o" x, a        end;  K9 X% P, M. r
end;        -- of the method
6 E  O. z! k! `- ]
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
5 K5 k" }4 q, ?/ R# \
7 [( J1 w* }, |* T' d% Y6 Y3 T- M! [5 e这是AGV_putin中arrive的method。
, u* r3 N  F! ]7 ?6 t( e
0 P6 M3 e0 }1 m) J! R当到达物料速度越高时,这个报警更多,
. c. |9 I. U* s# g/ m: Z. N可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
9 [4 E" x2 z  C' k程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?% E/ X& b8 s7 ?+ M2 T8 w. L) l

' e4 ]3 X; c/ q& m4 q: A' r( o另外一个小建议,就是move,所有的move都可以这样7 {. e. {5 G: M* L
if not move() then debug end4 m1 j" j9 \& W# @; X
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
5 l% q0 z  \& e2 gplant simulation中的free libraries有AGV模板,
+ E- R" O, @, \" q" q8 d里面也有案例。" d. a0 j7 H" i' S1 j: W  }
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
$ ^" [) v1 c/ \1 [3 z( E' R: I1 o& A& {
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
; o+ V# _9 n! {- W2 {( @3 R6 H# L8 S6 e' Z) |( W6 j+ y5 _2 e
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
( F, q. m+ i3 |. w, L$ N这是AGV_putin中arrive的method。  T- r/ N' S1 a- e- w
# g' H5 R5 T% Q3 j0 p- C, X) Y
当到达物料速度越高时,这个报警更多,

& B& i6 ~* X6 v0 G) H0 L另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-21 01:19 , Processed in 0.020414 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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