设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9902|回复: 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'2 J2 X+ e% G8 S9 g+ {
*/
8 G2 G0 I0 l0 }/ q& }9 H6 P; Dis( [6 x1 ?5 h) r" X1 h/ l' p
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;7 ~' l) e8 s/ W# x4 N
do
- g& [" z# s: M) F        Lan := rootfolder.Internal.Tools.AOLlanguage;# k+ _- W9 k" R. p, j2 \
        if current = @.Destination -- else return" P6 A- E" W7 X& I, T' A$ Y6 U
        then
* U: z# Q8 b: T4 D: h! f                @.Destination := void;
9 L& N2 @$ }8 r7 D2 w                if @.occupied then
. _4 |7 Q& m9 e' i- D* }                        part := @.cont;' |- [) E5 y! W
                        @.transpOrder := void;* O( Z6 Y- [* g) Z" N! M
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
* r6 U& Q8 C3 `. U  p6 h                                @,root.eventcontroller.simTime);
  f/ n; P1 }1 K                        @.HasOrder := false;
4 [9 D. c( Z. [2 A0 Q                        @.DrivingHome := true;
8 y& o. c4 }9 a& z                        rgManager.tryToStartTransOrder;/ T7 x0 z. S8 u0 g' w
                        if @.Destination = void
7 w) I4 `6 `) G                        then -- no transport order for vehicle @
$ w, H7 b6 T) Q7 [) O& q- C                                @.Destination :=
" \& F. h6 U) C) Z, t% S, q                                rgManager.nearestFreeStation(@,track.~);
' B/ l. v# r7 e  S% J                                newDirection(@);   0 |2 n& Y$ u0 j
                                if @.Destination /= void then
9 f8 P2 z7 e! [+ [                                        @.Destination.NumReservation :=
9 ~2 E3 p5 e4 E5 C: s4 g. O; i                                        @.Destination.NumReservation + 1;3 B& ^& A  Q5 h2 n* K
                                end;
/ m! r8 K3 T: [, m7 a                                @.CurrIcon := "drivingHome";. A) e1 U1 U' W# u
                                @.DrivingHome := true;9 ?$ K( h! I3 S. z4 X% _) z7 Q" A
                        end;& }4 X) `6 h+ J8 C
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station/ \6 T& k: ]& m
                        part := @.transpOrder;
) ]3 O, j% ]! ?3 ^; w( i2 f5 P                        part.move(@);-- load part
7 ^5 |8 O5 L; n+ b! N/ J                        @.CurrIcon := "load";3 ~; b# h+ C* U* b8 O. T+ H
                        GlobalDistObj := part.globDestination;
' i# k0 t9 n% C                        assignLObj := rgmanager.rgAssignL;
3 c; B0 E4 x0 ^                        row := assignLObj.getRowNo(GlobalDistObj);8 U% ^& J6 |$ D9 ?6 }' D9 [
                        if Row = -1 then -- since 700 X7 G  z. s- ~: }8 @2 D; `
                                if lan=1 then
1 P& G+ ~6 b. G/ v' d) E                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
/ a8 Y9 b0 h5 `0 A) ]% Z                                                to_str("in der Andockstation: \"",?.~.name,"\""));2 r. j( e+ ]% T& s9 C2 l, N
                                else  j: `7 U8 [5 p+ W$ K: i
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
0 p* _9 y# E' M( ]# ?9 `5 I( p                                                to_str("in docking station: \"",?.~.name,"\""));                                : N+ b: I: U8 a+ P. c# Y
                                end;8 ^# T4 j& P5 m; R! H7 |' ]
                        else* w6 v' T7 J0 u$ q. r" F8 U) p  L. \
                                @.Destination := assignLObj[1,row];2 t$ W0 f8 L4 C3 q$ d
                        end;                        + J5 h: A1 ^# t3 ?4 J
                        newDirection(@);3 j& {) W& ?2 e4 M$ V4 }/ y5 F
                        @.HasOrder := true;
- J0 c( ^; B  p5 A8 R                end;% y7 `3 @) r- Z& f* R) U* q' w
        end;7 G  [  o+ U& k( R% C
end;        -- of the method  n3 J$ `: q. w; o
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 6 @9 b. p% t, G& R" U! j
6 j8 L2 b7 }* R* m
这是AGV_putin中arrive的method。
! d9 `9 [2 J8 m9 j* U1 T* A* r+ r( c7 P4 u+ D' Q
当到达物料速度越高时,这个报警更多,# w, D: ?* j0 r4 j4 V0 J! h" p* x
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
0 q  ]2 b, G- P. V# i$ K1 {9 g程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
' E1 o0 y  l' V# k" Y
3 V  z& n5 H- l! q$ B& w4 j另外一个小建议,就是move,所有的move都可以这样9 g& R, l2 |/ J
if not move() then debug end
. b+ n3 y- [& m: q2 L* ~2 O9 q这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。( U  V3 c" J6 k9 |  f
plant simulation中的free libraries有AGV模板,$ S* \( J+ d" T3 G
里面也有案例。
3 X3 J; O. g$ G% ~. H我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。8 }: W: _7 c2 j. [6 k' C$ ^0 [

5 w" z' Z2 Y' B9 E  j我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
) t3 z, {7 D4 X% _" f, Q% o( z* l0 b& x
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 # }2 C* v; q( g9 n* J, o) b; d. m
这是AGV_putin中arrive的method。/ K5 V  }3 A; _+ k# ?# I* J. Z/ _
9 Q0 T& v9 c) y
当到达物料速度越高时,这个报警更多,

1 P' n  _) g8 J; ^另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-1 19:06 , Processed in 0.020994 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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