设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8885|回复: 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'/ [8 q: m. n9 Y, M  f$ {) a
*/) v5 q  J' I/ V2 N
is
0 r1 y) D) x9 F  P* |        part, GlobalDistObj, assignLObj:object;row,Lan:integer;6 Z1 s1 k. s. u
do
3 F& ?2 M' V6 d4 F        Lan := rootfolder.Internal.Tools.AOLlanguage;" w! N1 w( t3 }
        if current = @.Destination -- else return9 C$ L6 \9 e% X% Y% E
        then
) ^/ y9 |; [- E2 }) `                @.Destination := void;
4 P, L1 w! [7 C9 K  w                if @.occupied then! Z6 N6 O: ?4 @( w! \, }
                        part := @.cont;
! v6 i9 m7 U4 M/ @$ m0 j- ?6 E8 ]                        @.transpOrder := void;6 v! c/ k7 ^& e% q
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,- d  Q) }4 ?; k7 A' K
                                @,root.eventcontroller.simTime);! n& j" R& L; d6 n; T, r
                        @.HasOrder := false;: g2 O" a2 ]8 H
                        @.DrivingHome := true;
0 r! ^: U$ @" u4 @$ h+ C                        rgManager.tryToStartTransOrder;, m/ U2 y( d- @9 N1 b5 {
                        if @.Destination = void. |( @7 c: M6 |* O/ w2 d$ m
                        then -- no transport order for vehicle @
# X/ [' I# G7 {) z# b: |7 R                                @.Destination :=
+ w& x% r: A4 G" S! ^. ~6 C' o7 `                                rgManager.nearestFreeStation(@,track.~);
# Y5 c- T$ I& y5 I1 ~                                newDirection(@);   
; F+ g) [8 |/ r: y' O  ]5 w/ N                                if @.Destination /= void then2 j5 o" T6 H" X2 L
                                        @.Destination.NumReservation :=
+ [9 ?3 g0 `3 H' v. b                                        @.Destination.NumReservation + 1;
9 h5 C" {5 b  ]' s                                end;/ [) s3 T; D/ }: j4 P- f
                                @.CurrIcon := "drivingHome";, n# G# g6 A: s8 c- b. E: k
                                @.DrivingHome := true;" b7 i; e5 T  t: K& F
                        end;9 U( S: P' |$ P0 V3 G; l, d$ p% Y
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
( r! e, j/ L7 X( s5 v                        part := @.transpOrder;
1 V* w( O7 C, |2 T! n5 A                        part.move(@);-- load part
" Q; S; f5 j8 V& ~                        @.CurrIcon := "load";1 R8 c% m( X" F% m1 o) z0 ~  m: F
                        GlobalDistObj := part.globDestination;
7 ~( D( u  r" k- \% [# o                        assignLObj := rgmanager.rgAssignL;
8 O9 r/ C. f2 e* U+ S                        row := assignLObj.getRowNo(GlobalDistObj);
/ B' J+ D5 O2 S5 h' f! j4 _                        if Row = -1 then -- since 70
: |+ m0 ]! y. \9 J# P8 f                                if lan=1 then
+ c# ^& K9 [6 V( j/ C8 j8 j% _                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),1 L. `, Q! l7 m' S! {6 B
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
% A% |( J* v' R6 I2 Y# P                                else( G: |: w+ Y% B
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),# x$ U$ c& b9 g* w5 o
                                                to_str("in docking station: \"",?.~.name,"\""));                                  e3 F& T1 o! N0 u
                                end;  T. n' S9 V, t5 y+ M. N
                        else) c1 {! M1 n% ~# d6 g
                                @.Destination := assignLObj[1,row];, d( u4 I- f2 _3 R1 s: L: [
                        end;                          `8 ?7 U" I5 u! H. \
                        newDirection(@);
: E3 ^8 v5 ~  B                        @.HasOrder := true;
9 I# P  U4 {7 |8 |1 D                end;3 \. g  @! R4 F, z
        end;
6 v5 m4 b, I! }7 M* ~# r9 Tend;        -- of the method* q- y5 o6 n7 ]  _; z
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
+ |% C$ ^% {+ L* l5 w. n. E' |5 k/ s3 K4 |8 @, U1 r" ?
这是AGV_putin中arrive的method。
* x; i" x. _- X( A, ^( ]* g' P' j9 a7 U  R; M
当到达物料速度越高时,这个报警更多,8 N- ^. `( b* N
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
! `/ Q8 b$ O0 C程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
3 q/ H; X+ Y$ M. j  I, [( S  p" r( u3 e6 h6 m# S* q
另外一个小建议,就是move,所有的move都可以这样
7 X/ Y- ~( {, v# |, C( Kif not move() then debug end
' S  R$ m, J8 _9 U' ~这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
% X3 V& R7 Z6 ^2 i6 z% Gplant simulation中的free libraries有AGV模板,
/ m6 ^4 L* I8 M' n6 Z里面也有案例。
8 B" D6 c+ w7 _: S我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。5 B: y( w* Y/ t9 I

' r6 e3 J. }5 n我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ! ~1 k: q+ X( p

% [( z5 Y+ S6 z" m- n1 _. n那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 , D+ L7 K, p, \/ H7 I: n. G$ r2 {
这是AGV_putin中arrive的method。2 L9 d4 V) R( I1 Z8 z& w
9 a& B/ i) Q/ {4 f7 f
当到达物料速度越高时,这个报警更多,

1 L3 ?5 ^! J1 x8 D- K/ `- P另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-2 13:48 , Processed in 0.013561 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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