设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6884|回复: 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'4 ]! l. D/ K. v5 {- l0 B
*/
; C0 N* `! ~- {0 v6 O7 N$ {is
8 T/ a) ^' D; x( Q        part, GlobalDistObj, assignLObj:object;row,Lan:integer;, b  d  c6 i0 L
do
) {0 @! ~2 z. l9 \8 L        Lan := rootfolder.Internal.Tools.AOLlanguage;
& C$ P' }  T& z3 m- s3 n        if current = @.Destination -- else return
& T+ v/ L% ~& G9 r6 _  E        then
' N9 g) W7 F! q3 G) w                @.Destination := void;9 l5 s2 v3 q! h7 z2 S
                if @.occupied then& [( h+ A& S) q2 E
                        part := @.cont;1 h. Y% ~$ K" v+ K7 L" N4 G! N
                        @.transpOrder := void;" }4 x% o- K" _% s6 B* n
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
4 j" ~; A( n1 c* M. A# |                                @,root.eventcontroller.simTime);' t2 M7 h# J- _7 s
                        @.HasOrder := false;9 T$ X4 b! M, q
                        @.DrivingHome := true;9 p1 I8 S! v* x0 B6 u
                        rgManager.tryToStartTransOrder;
: n) M3 p% t( V* M; u3 \) r$ s                        if @.Destination = void0 @/ @* V6 x( S) r! U% W
                        then -- no transport order for vehicle @
( d& a8 H4 o4 y7 j3 `, A: _( H- X5 p+ B                                @.Destination :=  q5 j7 M/ q5 M% b
                                rgManager.nearestFreeStation(@,track.~);
2 O( c1 h% |. A$ W9 [2 `* T4 `                                newDirection(@);   3 m! f1 B. D5 y# F1 S9 u$ d$ p
                                if @.Destination /= void then
' T2 y. G9 y  f" P( l5 R) A. U$ Q                                        @.Destination.NumReservation :=+ w8 M: Z/ K! j. w
                                        @.Destination.NumReservation + 1;
) y, t- b3 x5 S) l2 k( X# V9 l. I8 k                                end;
* ?2 _/ H+ o+ G- [4 s) t, E9 E  S+ d                                @.CurrIcon := "drivingHome";$ L2 f( V2 \( m( H+ X, c% C9 O
                                @.DrivingHome := true;! j) ^+ K, a7 [. l4 b
                        end;' l9 D7 I  T1 c# r- m7 k
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station/ W* s2 o# H6 G, ~0 O5 E
                        part := @.transpOrder;" q( G2 B2 D' m; h
                        part.move(@);-- load part
+ J/ k& U2 J- l! W; A* Z                        @.CurrIcon := "load";
% e, j: i1 I8 z! k2 Z# y                        GlobalDistObj := part.globDestination;
7 k$ l8 h, ]  `+ K* A  s. f                        assignLObj := rgmanager.rgAssignL;. W9 Z8 e+ X" t  I# u7 X$ A/ z
                        row := assignLObj.getRowNo(GlobalDistObj);
7 {" p/ K; Q8 r5 a                        if Row = -1 then -- since 70) \9 b% M8 n. m0 Z0 }2 U& m
                                if lan=1 then: T' a  D, Z, _, s0 ]
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),9 s2 V" i- D; y/ J
                                                to_str("in der Andockstation: \"",?.~.name,"\""));/ r+ b( T" b4 X2 v
                                else
, o0 R1 Q8 U/ p( d2 K4 x                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),; V( U' U+ ]0 E' \& E
                                                to_str("in docking station: \"",?.~.name,"\""));                                0 L3 t( E  |: w. b
                                end;! F* G: {% q' Q4 M
                        else
+ d% |) h) a# [  Y                                @.Destination := assignLObj[1,row];; Q2 y# G3 O+ h  I4 {- {
                        end;                        ; j+ v% U7 p, A; r( e9 g7 m" J! g
                        newDirection(@);& S  K9 _, Q. u
                        @.HasOrder := true;% ^- m: i' W+ v6 C
                end;( R7 e# V7 h: I1 q# x
        end;
& k% x, N  o- T, {/ s* H1 X# h2 H& vend;        -- of the method# k! x/ A9 T; R
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 . T# E7 O- f0 Y6 J! N

' u. M0 N: b- f( _3 ^# d这是AGV_putin中arrive的method。$ }- x) }# ~, F0 g! j
. G5 N" H( I, z1 r" X5 q% m/ n1 ^
当到达物料速度越高时,这个报警更多,& l3 W4 ^* Z1 `8 u
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
/ c. r  a, v! Z5 h1 p4 g( r程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?) P4 }( A% P0 u' p, i- o

3 [. x: z& H* L+ g, ?; s# H另外一个小建议,就是move,所有的move都可以这样( l. r# m+ }* C8 k. }/ \) u  u' ~1 l
if not move() then debug end  x/ x) `9 ?  J3 n0 A  b) l
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
( ]5 y9 p: s( G3 nplant simulation中的free libraries有AGV模板,3 x% I) I$ Q2 ?
里面也有案例。
! `+ i* K/ J! r* _: A我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
, A' t. z+ k. v+ J( c+ L% `# ^/ G$ v; F4 {) M! b: o0 Y
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ' g( g5 A% \" r& H# ]

+ L. t8 a# }9 q1 x那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ; `9 `4 a+ M9 U7 D3 b
这是AGV_putin中arrive的method。/ @: [/ U$ M2 X* o; W, O) j* x

, y7 d6 l% H: D+ ]4 e, Y$ B当到达物料速度越高时,这个报警更多,

) ?3 a- \, M7 v2 I3 G另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-4 15:22 , Processed in 0.020890 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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