设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9983|回复: 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& s2 O* s0 ~+ b, @9 ^  [4 F- n
*/
4 B5 i- g$ q5 Z. n; R: g. Kis
$ o- l( R1 j& e( J$ m7 I        part, GlobalDistObj, assignLObj:object;row,Lan:integer;) N( I; f* x( y) t5 W: Z6 k
do
5 K$ S( C. K% H1 |5 p! T        Lan := rootfolder.Internal.Tools.AOLlanguage;
  ]* u5 @7 q# D7 {! W        if current = @.Destination -- else return
& e% O3 T" S# W: t* A        then) A! l5 H# T% [. Q8 l- |
                @.Destination := void;
( J' Y$ |9 d) ]                if @.occupied then/ S, d, a3 \. q. V) w% n' T
                        part := @.cont;0 A( u& D  l4 f$ L
                        @.transpOrder := void;
6 O! t$ b1 d& Z' Z                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,4 g  I% D+ [9 s
                                @,root.eventcontroller.simTime);( \2 T' e. Y5 K: ]$ [
                        @.HasOrder := false;6 X+ a% c; c7 e7 @' i9 E& W
                        @.DrivingHome := true;
3 p/ ]8 c% n7 q. ~                        rgManager.tryToStartTransOrder;# _! o* H4 [8 m2 N' `
                        if @.Destination = void
- _- j5 y  a( @' F                        then -- no transport order for vehicle @
2 x! Z" t* Q% k6 K' J5 I                                @.Destination :=
* W; U- P1 p! @1 q! z& _% r                                rgManager.nearestFreeStation(@,track.~);- W+ `/ I) k4 n; s
                                newDirection(@);   ( O) _9 B' h/ q5 R$ ~2 ?
                                if @.Destination /= void then
1 r& p/ a$ c) p. [                                        @.Destination.NumReservation :=
4 L& l3 f/ t6 g: b+ o  ]                                        @.Destination.NumReservation + 1;
8 L& A5 H* I0 X2 E; M                                end;
& ?3 A# t  ~' D& }3 N! `! \' w4 n                                @.CurrIcon := "drivingHome";* e5 m3 V$ f& d" L6 I8 V; Y
                                @.DrivingHome := true;+ ~& L" ?- {" A) S: G4 a* |
                        end;( C, A  B: ]9 Z1 {) r
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
& {" V2 v2 m" x! J$ q% d                        part := @.transpOrder;" P( n- }) z' Z: |+ T, d" ]# C
                        part.move(@);-- load part8 C% [) U: e1 j5 ~* j
                        @.CurrIcon := "load";* e" A( n8 ]* v& h$ e: b# z
                        GlobalDistObj := part.globDestination;
/ I9 u  o4 q; [1 ~. |                        assignLObj := rgmanager.rgAssignL;- _  L( e+ }/ Z0 W
                        row := assignLObj.getRowNo(GlobalDistObj);7 L# m. u$ b) j  {
                        if Row = -1 then -- since 702 e& r$ Z* w! _6 t# G
                                if lan=1 then; V0 f) |1 j2 L. z
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
, ^& f5 _4 [; g0 r. K% M                                                to_str("in der Andockstation: \"",?.~.name,"\""));
  @6 z2 }) d' w                                else7 M0 P4 N' K% U, }5 r
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
2 a% V2 P; J2 }' s8 k7 ^, [3 q                                                to_str("in docking station: \"",?.~.name,"\""));                                6 O6 R6 J- h" \( O# \3 p! m( b9 J* }
                                end;
4 M, `, t) i( t+ E- D  U5 W1 [                        else( p/ _& i/ D" B3 ?, C% I# O
                                @.Destination := assignLObj[1,row];  j5 z( R5 f8 N. b  F% f& y
                        end;                       
" x+ e) e% P2 O. s0 }; ^                        newDirection(@);
8 `! E- |5 Y& u6 U& E- F9 c1 C! W5 ]                        @.HasOrder := true;$ P( P. u# L2 A% E" @
                end;4 T9 ~2 f- E' |  W0 I. F
        end;" o( B, q# ~0 P- ?/ z4 U, \
end;        -- of the method3 M3 c# ~; M1 Q# ~9 L; N& A' t
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
9 H; D, q! @! @( p7 d1 H: ~3 P/ |, @: }! v
这是AGV_putin中arrive的method。" j. m* j1 p) V# a; j
2 Q# E' D! P( R+ P) ^
当到达物料速度越高时,这个报警更多,
% \: Z' {  ]( x8 z% e可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
6 Z+ M, D0 r- b. k! o程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
6 \" z, H3 k. F9 f. W$ U2 u' C4 s1 O1 `+ ~0 C& t
另外一个小建议,就是move,所有的move都可以这样
) d) g$ ?; S6 [  I/ z5 S. Dif not move() then debug end
4 R1 d' X+ O. O% x这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
/ S2 i3 ]' \9 j; B' q( ^& Nplant simulation中的free libraries有AGV模板,
8 \# A" o, z# u- A' A里面也有案例。
# q# |# ]! ^0 N) }+ l; k# C我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。6 A- A: J4 v- [9 X

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

6 K* a2 m/ f3 }/ [' J; l那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
. P1 q1 H2 [) [: y3 l这是AGV_putin中arrive的method。
4 L6 Q4 x' q. x1 H) ~. d  C
7 d  |6 c9 x& _: O$ c当到达物料速度越高时,这个报警更多,

+ f, M7 p) G; P/ j: m% v另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-5 21:46 , Processed in 0.031052 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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