设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6187|回复: 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'' X& d  r4 \: k; [
*/& M) ], M% F2 O' O
is! v8 K. h! w6 l+ a; D) Y) M) w' I! w9 H
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
7 @* i9 R! t/ y4 Kdo
$ D$ a) G' p6 c3 {        Lan := rootfolder.Internal.Tools.AOLlanguage;  U. V( _& L+ M  d
        if current = @.Destination -- else return
( _1 x/ E. X# N9 w( `, t9 W  X7 X        then8 S  j3 i( H6 i
                @.Destination := void;2 I) G, y2 V7 ^6 X7 g: q; J! V
                if @.occupied then2 e6 g7 S, `* B0 {1 ?1 A
                        part := @.cont;
! x( W: V8 E; [: Q$ ?/ g2 `                        @.transpOrder := void;3 e' E9 `) I5 k- V- V0 g
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
! D% ~( x7 R) H) F& d0 W+ u                                @,root.eventcontroller.simTime);
6 S2 \2 Y- `! F& u+ N                        @.HasOrder := false;; B$ I* A; M2 t$ k5 e
                        @.DrivingHome := true;0 Q& r: b6 e4 K% |) q1 E% O$ c
                        rgManager.tryToStartTransOrder;
+ f8 B& v7 g- }4 P                        if @.Destination = void
5 `( U" b7 P1 d& }" Z4 \& K3 o                        then -- no transport order for vehicle @
' V) v+ Y$ d, j* X/ X                                @.Destination :=9 ~, r5 s# D% M9 d' g) @6 |. I. R
                                rgManager.nearestFreeStation(@,track.~);3 R- F7 R( L( ~, z1 e
                                newDirection(@);   6 L/ I8 W- g' J0 `/ O( Q
                                if @.Destination /= void then0 i0 C5 F9 ~# B; S* V1 Y4 H+ y
                                        @.Destination.NumReservation :=& [6 {- @6 h8 }! C5 d4 W. m
                                        @.Destination.NumReservation + 1;
+ \0 e% s2 X- [. d! g- [* t                                end;& a8 W6 ~% B: o) z: k
                                @.CurrIcon := "drivingHome";
! K* y% f- Z( r8 j; v- x# B/ N' o                                @.DrivingHome := true;
$ D4 ^& m# i3 |0 Q6 N+ y1 `. x# c( {! n                        end;$ U9 \, b+ F2 X3 F# y- V6 I. F* p
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
, n0 l3 V! |) u# }1 \, {4 ~                        part := @.transpOrder;
' }1 {* }( n4 H3 m3 o, K                        part.move(@);-- load part
4 a/ ^! o. Y' B  y6 i3 r5 {                        @.CurrIcon := "load";
# K+ @; ]/ _2 w7 X! l                        GlobalDistObj := part.globDestination;
8 x/ e5 F  D7 Q6 [# E                        assignLObj := rgmanager.rgAssignL;
, G" I' i3 F0 P$ S9 E2 i- D( C) i' d' b                        row := assignLObj.getRowNo(GlobalDistObj);- a" N; t/ ^8 s, r/ T4 w
                        if Row = -1 then -- since 70! _- f  a3 G. \9 B' }
                                if lan=1 then
) z1 @) B- C- D. u# q! R8 f                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),6 E* t  V1 C* d5 W8 [  i
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
6 f- N( N$ K$ U                                else8 G! v4 C' b2 C
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
, ?( b4 c* o* P$ r                                                to_str("in docking station: \"",?.~.name,"\""));                                9 M/ x) u- ~' I# ^9 j+ r2 g0 @
                                end;3 S- ^' @. K% }. U
                        else1 j* k# u' O& B4 x; }
                                @.Destination := assignLObj[1,row];' Q; L0 K6 Y) e. W, ~
                        end;                       
, o; L4 H& A) y1 o  m, b( E                        newDirection(@);
* D/ d( }2 k" b/ M, d8 t- F" t                        @.HasOrder := true;$ R0 }5 P1 w$ e% n4 }' \  I9 q1 t
                end;" W7 m4 T" c: c  O5 I
        end;
, m2 E3 u: F- ]/ Yend;        -- of the method" b! m4 T5 w) Z3 N" c  o5 Q
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 # G1 @7 e1 r2 k0 e7 {) b
9 T) d3 @, u7 s1 J5 R7 ?4 ~( w9 d
这是AGV_putin中arrive的method。
9 w3 l/ T1 v/ I3 g- }: {8 Y8 r6 h: [8 R
当到达物料速度越高时,这个报警更多,( {, I- [; [9 r( Z+ d
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。. V6 R7 f: f5 i2 ~+ S
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
/ P+ X$ Y" k$ G' h- V7 ~/ R$ n& R4 Z* \* p' k
另外一个小建议,就是move,所有的move都可以这样( l# V6 l! w1 z
if not move() then debug end
5 t+ ~4 Z2 ?5 ?# Y' A' A* f这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。+ L/ ?& F8 Z2 U9 Z6 I, Z
plant simulation中的free libraries有AGV模板,
: E. {2 o1 m9 S$ W里面也有案例。. v- `1 x" Z7 w
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
7 T) ^+ M$ j7 [& h( Q! U, f! o+ m# Z) k* H
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 . t: s- f8 G# G8 H4 p
  d- ?! E, Z  ^! p7 V! D0 G
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 * F* a' r* T2 p3 G, G
这是AGV_putin中arrive的method。
" R2 b% K% F8 f, h- u
* V, p  I" @* J# T3 P当到达物料速度越高时,这个报警更多,

3 f, m2 S; ~  d( m另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-23 20:36 , Processed in 0.029555 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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