设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6331|回复: 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'
9 X6 M3 P4 C( F3 m+ U*/) ~* z& a; h; Q2 {  a$ F) d9 Y* C
is+ s) n, g. n* n5 `. H
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
9 S/ _6 u% w  c9 ?4 q; \do
, N$ m6 H$ j# ^7 }8 i        Lan := rootfolder.Internal.Tools.AOLlanguage;
3 J% G3 t- s) ?        if current = @.Destination -- else return) y' u" c. T/ d' q/ ~, Z
        then) Q- ]0 M; A9 r: ?. z. Q
                @.Destination := void;; d; N& ?5 L; ^( O) E2 a$ \
                if @.occupied then- Y) L- e0 V& ]6 a1 ?' K
                        part := @.cont;9 A- `; ]: a' t" f9 J: w0 ^  ?7 t
                        @.transpOrder := void;
5 ^& `7 u: W- l9 Z) w' m! G( f  S' S                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
3 F" A. T0 t$ P& h. {  l) Z) J2 r0 A                                @,root.eventcontroller.simTime);+ q: m4 a6 U) e
                        @.HasOrder := false;3 H5 u  M4 ]  t' w! h
                        @.DrivingHome := true;
. E" M" j) h! h  t- z9 j                        rgManager.tryToStartTransOrder;
( F* F. [& j, a1 H                        if @.Destination = void1 l" l9 f5 {  N" }
                        then -- no transport order for vehicle @
1 ]# \' ~3 q1 ^0 Q7 x9 D8 ^                                @.Destination :=
8 b8 ]5 A; b' A3 @5 V                                rgManager.nearestFreeStation(@,track.~);
6 ]3 g! k+ V  ~! w                                newDirection(@);   , d4 ~! u* D* {; z
                                if @.Destination /= void then0 q6 H2 ]! |7 S" b; A" J6 V
                                        @.Destination.NumReservation :=
4 k5 ^! p+ U1 e0 `1 ?$ J8 l8 ?9 Q; Z" q                                        @.Destination.NumReservation + 1;) }. g8 \% M3 ^( ?5 X2 M) m
                                end;$ [. K  Z- b9 V( E( z( K
                                @.CurrIcon := "drivingHome";
# x/ N; {9 i. O0 r( a1 ]# u) W                                @.DrivingHome := true;
' t# K8 I; `; ^                        end;
/ ], f, {/ e( Q9 [                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
, O/ l5 ?$ d" w0 f8 h) _0 ^( s                        part := @.transpOrder;
  Z9 r  h5 O# [0 F: L                        part.move(@);-- load part: P. q8 k6 j# Z* e
                        @.CurrIcon := "load";' q0 A* j, L6 K/ v) d$ Y  x
                        GlobalDistObj := part.globDestination;" U0 S. @  x, A8 \
                        assignLObj := rgmanager.rgAssignL;# @# {# U1 y6 S  `7 i. y
                        row := assignLObj.getRowNo(GlobalDistObj);( f5 O( G/ E# N* j( x1 W
                        if Row = -1 then -- since 70% T0 @, T1 \8 W: h
                                if lan=1 then$ a2 H+ g! t- W/ M$ X+ x  H
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),1 G0 W; I' [# j4 C9 N  i% s) U; A
                                                to_str("in der Andockstation: \"",?.~.name,"\""));( U2 d/ h/ B2 |: n8 v- u& O
                                else2 Y- g5 {  z; R. y
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
% q7 v; c& E/ H+ s                                                to_str("in docking station: \"",?.~.name,"\""));                               
  y+ X" y4 ^5 Y: k9 Y6 _( C) X1 B                                end;
6 t7 [$ P! }- {' C8 x" x% ?                        else
9 |3 B2 _' \& f) m8 M7 @1 W3 b                                @.Destination := assignLObj[1,row];
* Y# b7 [+ t* ^7 L7 a                        end;                        ( p1 `' j8 S) X/ |1 o3 L
                        newDirection(@);
! B; v$ {, Z& L                        @.HasOrder := true;( W% U: v% z: d  g7 s
                end;  n6 S" L/ B5 m3 S
        end;
% \  y; Y- {+ w' n9 s$ @: n8 tend;        -- of the method# Q8 F" }0 w" o* c
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑   d; r' D) M  b- a* l9 G7 ]6 Y+ Y

/ i  w: B' I. E$ @* o这是AGV_putin中arrive的method。
5 D) }# c0 f8 ]4 ~! J* R+ e/ C" _, Z1 K, V
当到达物料速度越高时,这个报警更多," ^- |! b9 q5 s" w" V
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
6 K) n7 w- O6 s4 p3 i( K程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?" P; o. m2 J/ G9 b

  z- I! i; }; _另外一个小建议,就是move,所有的move都可以这样
  @( K% y+ z1 pif not move() then debug end
) c  D: P, k7 F" Z+ C' n这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
6 T2 d) m# n+ splant simulation中的free libraries有AGV模板,
/ u4 N2 h0 W/ ~1 a, X, `# G- }里面也有案例。! a- e2 E4 `3 C# u
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。' q( P3 d  e% L

, m. m0 p% Z9 F. k1 `: i我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ) ]/ b# m$ O, B. v9 i

% E) [4 j, k, c: M& u0 @/ @那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
; k% Y) G) Z  l" z, d这是AGV_putin中arrive的method。
+ Q% G: B& b. I* L5 u  @' I5 x0 ~& g5 ~4 j) Q. U
当到达物料速度越高时,这个报警更多,

4 Y1 D/ B6 \( U* g. [+ Q: B另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-31 08:24 , Processed in 0.015466 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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