设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9480|回复: 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'6 c0 a7 m% }; k8 L' x& w2 L/ H
*/. @, s6 X9 b; K2 K& g; w# |
is4 L& B: ?% z6 O0 D/ F" S
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
& x. c# s- d! D/ q. ]do+ A8 h. G* j$ f7 f/ J2 d
        Lan := rootfolder.Internal.Tools.AOLlanguage;- o/ B+ W/ r8 {1 e  ~% u; D! t
        if current = @.Destination -- else return
" ^! ]; ^" U- \5 l; g2 M+ y: A        then
$ E9 ^# b) A1 r! _6 I. ]4 o                @.Destination := void;: o* _) F2 t2 h# ^. V) b  t% l
                if @.occupied then" ?6 c/ k2 D8 }" s1 B
                        part := @.cont;
8 w/ t% t, t7 |; ?1 Q/ F. i                        @.transpOrder := void;
% m/ l; A  T& O" e                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,$ O$ y( L5 I2 O! g: D# D5 t' m
                                @,root.eventcontroller.simTime);+ |% {! M) f5 \
                        @.HasOrder := false;
, p7 |5 I3 @, x" e! n                        @.DrivingHome := true;9 [8 y6 m# X# |7 @" b
                        rgManager.tryToStartTransOrder;( ^1 e9 \4 w& h2 y: u1 k5 b6 }
                        if @.Destination = void/ A: T1 i/ l( Z4 h$ m% C
                        then -- no transport order for vehicle @. B- `) Z$ p6 \/ y
                                @.Destination :=
7 N8 _9 P& d+ }& h- {                                rgManager.nearestFreeStation(@,track.~);+ n5 F, e, S5 V4 R( k
                                newDirection(@);   . _0 z9 q6 W7 Z4 `$ Z: r7 l' m
                                if @.Destination /= void then
) ^# P% Y8 F9 i( H) Q                                        @.Destination.NumReservation :=- S' c/ R2 r+ x  N6 I5 R
                                        @.Destination.NumReservation + 1;
: J' G7 I, _  I( {, b9 O8 m$ A                                end;
. ?- [' T3 ~7 p$ ~                                @.CurrIcon := "drivingHome";
3 M" W- U0 @& x/ c, o1 D7 @  _                                @.DrivingHome := true;
8 D) b' T; f4 a/ M# g9 W                        end;
6 n$ ?7 Z2 Y0 d8 Q% R8 ?2 X( ]                else -- the vehicle @ is empty, both vehicle and part are in the same dock station- N* s7 x# Q# [8 m) [$ ~' x( q
                        part := @.transpOrder;
& f7 S, y' E7 u2 W9 }. n/ k8 D' d                        part.move(@);-- load part; w4 u* v* a- _4 C3 H
                        @.CurrIcon := "load";
& ?5 q- Q; ]* s) a% j, n/ j- |- Z6 ~                        GlobalDistObj := part.globDestination;
- x* r3 J. j. ?7 j5 e                        assignLObj := rgmanager.rgAssignL;+ |3 o! d6 H* f
                        row := assignLObj.getRowNo(GlobalDistObj);
/ k1 J3 n7 L* K/ S7 V5 q, X# l/ n                        if Row = -1 then -- since 702 x7 C! W+ ~7 E8 o. i
                                if lan=1 then  v: T- \/ \; ]! \) f$ x4 ~# Z
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),  [5 o* t+ v- e8 Z0 W/ Z7 b
                                                to_str("in der Andockstation: \"",?.~.name,"\""));# |% N* X' T- W3 w
                                else
3 g; ^1 B5 q* g& p$ h                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),1 l1 M; K/ S5 U
                                                to_str("in docking station: \"",?.~.name,"\""));                               
6 m6 z: O0 r. w* s! m                                end;6 h* H' o6 N3 W/ r
                        else
7 E2 E, c* K2 y: E8 l* G! n                                @.Destination := assignLObj[1,row];: p% z# N* D1 q6 ?# t4 h: W; M& V
                        end;                        ) K* L/ p& G4 }9 j0 |  n
                        newDirection(@);- i* C0 }, x; i- q4 o  P
                        @.HasOrder := true;! m; j+ H+ J  z/ Z. a! M8 _& [0 t2 w
                end;. V5 y8 l* i$ H+ ^2 v: V
        end;- U& [' b: i' \' g
end;        -- of the method; w: I4 z/ E$ P9 d' Q
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
2 e7 C  q( N3 \  f" w2 g4 f, d& D) y" d9 W3 M3 _4 `
这是AGV_putin中arrive的method。% z0 y9 p! {& z3 E; B9 h! u
$ r2 N9 P5 e1 A* e/ r5 I; p
当到达物料速度越高时,这个报警更多,
  ?* c* H  u! d& M1 Z$ u1 E可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。+ d) ^0 y/ \, J! N
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
  {% q' @+ @& @" z1 {$ C
# e$ b" A2 ^$ V  u% B& \! l& n另外一个小建议,就是move,所有的move都可以这样
7 |$ P4 l- w4 b! G6 Pif not move() then debug end  G5 l5 d  p* K' h5 ]: P
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
. `( j9 I9 a# s- M. U0 p3 Zplant simulation中的free libraries有AGV模板,, U5 y8 n! o; B: |
里面也有案例。. x& o  s4 T0 y+ U
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。* s/ J$ Z' `: x* p; C

3 k- J4 \6 A+ O  v我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
# t1 a  [" f8 {% W0 r  o# w# Z" z4 ?0 y5 C& [
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
* k  u/ i# X, m这是AGV_putin中arrive的method。
8 u6 i( J: z5 ^1 b! A( x9 m
6 G6 g: h7 u  {$ p2 T0 k- c6 y当到达物料速度越高时,这个报警更多,
8 F! G1 b# ?0 v8 W
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-3 11:01 , Processed in 0.019308 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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