设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8175|回复: 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'
- D9 k' I, Z( F% i*/$ Z: w; q, p* T( _+ @
is% a/ G. D  R5 L8 ~
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
3 e: u3 B) n* l5 a9 Edo
' ~! C, [5 O& J9 I$ E9 s3 \6 L        Lan := rootfolder.Internal.Tools.AOLlanguage;
# g3 n# F% Y) X3 A. }        if current = @.Destination -- else return  j! c: m% ~/ A- r4 W
        then0 ]; p+ s, i. T' ?/ m
                @.Destination := void;2 t2 ~7 a& j4 B
                if @.occupied then
4 m8 G' l* X6 z4 w, X! D+ T# O                        part := @.cont;
6 c5 y# r) q5 ]3 P5 r                        @.transpOrder := void;. ~+ T, M8 p1 v% }) K
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
- @' j6 _# j2 m# m' O) K! o8 }! P* c                                @,root.eventcontroller.simTime);% M3 A: v5 y+ w4 a% L; D
                        @.HasOrder := false;! x( T. d. ^5 t4 I0 k- C
                        @.DrivingHome := true;9 f) N- r. N6 E) N! u6 X
                        rgManager.tryToStartTransOrder;
. Z' |* d7 C0 X$ X! }6 p                        if @.Destination = void, V% U2 |+ l1 h( u+ E( `
                        then -- no transport order for vehicle @
1 [! y* x4 Z3 A8 W                                @.Destination :=# C5 z$ j: @8 l: y: k; M
                                rgManager.nearestFreeStation(@,track.~);
: c2 n4 @% L8 k' w                                newDirection(@);   
7 a, \# K) Q5 s0 T5 ^/ D( m& N                                if @.Destination /= void then" r4 X" \2 @( h% j1 I
                                        @.Destination.NumReservation :=! g; R( S" m" v5 K5 z) C
                                        @.Destination.NumReservation + 1;( ~4 P) x+ ]6 F
                                end;4 H, L+ r) q6 P
                                @.CurrIcon := "drivingHome";; X" _) r: k5 c# c/ L% @; u
                                @.DrivingHome := true;- @, D4 I! P1 V8 ^6 G
                        end;
* C  s; f; d7 t! H! N                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
# Y* F! n9 |- U) L" f                        part := @.transpOrder;
' s) w: G, g6 L3 p( H$ X+ V+ p, X                        part.move(@);-- load part& O, X/ S( ~7 ^- y; ?, W( S
                        @.CurrIcon := "load";
* f5 {& ?# j0 S+ o# P                        GlobalDistObj := part.globDestination;
1 C( x6 G6 X0 s5 B. c6 J                        assignLObj := rgmanager.rgAssignL;
4 I# p4 v$ Q; D; g% b                        row := assignLObj.getRowNo(GlobalDistObj);
# k8 |8 l/ K5 q, o) e$ e                        if Row = -1 then -- since 70
9 U4 M5 a% M! U3 ^                                if lan=1 then
7 A2 d$ |8 f. ~0 t+ |0 }                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
# g' H5 I3 B; j5 x                                                to_str("in der Andockstation: \"",?.~.name,"\""));
3 K! y6 \: `9 i( R                                else, ?- u7 w" l. }1 e# ^# ^
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\"")," a! B! p* l8 R" L6 c8 \
                                                to_str("in docking station: \"",?.~.name,"\""));                               
, B/ V8 V+ ?/ T: k4 \: D9 t' C( G. E# S                                end;
4 ?5 N* |  y7 ^                        else! ]0 o# F6 j9 W) i4 t" L% y, d
                                @.Destination := assignLObj[1,row];
8 m( f: F' o2 x( B4 _: i  o# _                        end;                        ! L, t. k& O  m2 z* F) a
                        newDirection(@);
& p# d) S6 C6 d0 F9 U* b: p) i                        @.HasOrder := true;* g( n1 T0 U& ?
                end;# t) e; H/ C+ H
        end;8 ]( \$ `9 y! Z  E0 g+ ^
end;        -- of the method+ o' P: T' }; O/ D7 n2 s* Q
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ' F& C: F/ D; z! ~. C1 E, `
" |6 e8 }& l0 H2 {3 h. p" V1 j
这是AGV_putin中arrive的method。5 e9 f3 G- e( L/ e
9 h0 Z1 d2 y) I3 E
当到达物料速度越高时,这个报警更多,
8 n. B; f( d5 |% g可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
0 }7 T4 e: s/ G( Q1 |7 Z6 ]& c0 k程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?  a+ b$ R! `  `/ ]

$ q% K' J1 @( _% }! ^另外一个小建议,就是move,所有的move都可以这样  S; x7 W5 U+ _) D4 w% T" L/ i
if not move() then debug end
7 J! b& R$ _3 B* a+ e这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
! S; b( J2 t$ ?plant simulation中的free libraries有AGV模板,0 t$ p0 s# N+ r! |
里面也有案例。
, r; p# ]' k4 C- |! C, A我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。2 i$ G% Y. I6 ^) V
9 Q# A3 D) t; d# `& V4 i  ?! ?
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 7 d6 J( p* e, E1 r( q5 d# u9 i
! B( l5 D) \. ~
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 . }0 c0 S" Q2 X$ j3 g* ^
这是AGV_putin中arrive的method。- n; G' m: q$ U8 q

  f3 m) w" o. [0 G1 N; w- T当到达物料速度越高时,这个报警更多,
& U" |5 I8 _  g' h, i) _2 m  S
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-19 03:53 , Processed in 0.023269 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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