设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8759|回复: 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'" F3 E# f& ~# ^6 w, P  w% s
*/
0 F" X) d8 S* w% H" c' Pis7 H; V* k. n* B7 L
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
$ J& x$ b9 k# x4 _do
# L' X) l& t- [1 U- Q        Lan := rootfolder.Internal.Tools.AOLlanguage;
: Q, Y8 I3 Z' w! F, r        if current = @.Destination -- else return
: a. S+ B+ [8 e9 @9 m0 ?+ u, V# {0 f- U* e        then
5 c! D4 q# Q+ H; y( E& x4 l5 B                @.Destination := void;
; g1 B3 Q/ A) v+ Q- f4 P/ W0 ~                if @.occupied then1 Q" l' r* S$ `2 x6 v
                        part := @.cont;' p4 _+ v, k6 Q4 d2 t3 b, l
                        @.transpOrder := void;' b  ]$ w' ?: U1 ]  @& l7 G4 g) k
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,) O0 R7 p* @  ?& p: R
                                @,root.eventcontroller.simTime);: m, N( h+ `, h) ^# l
                        @.HasOrder := false;
3 {: f% E$ k, a( Z                        @.DrivingHome := true;
+ r# Q2 Z- v8 s9 l$ W+ r1 |9 o                        rgManager.tryToStartTransOrder;2 K/ C4 H' Q2 w
                        if @.Destination = void9 t6 T. t) Z  P4 y! X3 f5 J
                        then -- no transport order for vehicle @
3 Q0 G1 N7 b6 d2 h& c                                @.Destination :=5 K8 d& B3 V7 c% Y1 A# }
                                rgManager.nearestFreeStation(@,track.~);
: \0 q7 _7 K, h) O                                newDirection(@);     J; F; z* H0 [- ?- @4 z
                                if @.Destination /= void then: L  H6 S) _' {; y
                                        @.Destination.NumReservation :=1 n0 n* Y, Z2 Q  X; l9 D
                                        @.Destination.NumReservation + 1;
( H0 B8 f9 l+ q8 v                                end;5 @: D- A! Z) K8 x) S& Z7 L
                                @.CurrIcon := "drivingHome";5 w3 z$ v$ V5 @: ?0 i/ }
                                @.DrivingHome := true;/ I# J  Q* V) k$ Z
                        end;( a; u7 s9 M) V) v7 I
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
2 d7 f6 \, J1 |9 M* z6 j* J) K8 b                        part := @.transpOrder;9 ~$ Z* u9 t) |3 q5 l
                        part.move(@);-- load part
/ p/ t& D. r1 [4 z" k                        @.CurrIcon := "load";
; W$ R, X' ^2 ?5 g                        GlobalDistObj := part.globDestination;2 e8 @  h# B6 Q4 L
                        assignLObj := rgmanager.rgAssignL;
( p& _9 H1 }" ?& f4 ?9 f                        row := assignLObj.getRowNo(GlobalDistObj);* Z# E9 @  K! ^' A) k! V
                        if Row = -1 then -- since 706 k- _* u3 A% m1 ?/ F% I2 c
                                if lan=1 then
: j: x) L6 k4 K, ]( i) A                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),9 x  Y$ R7 O: s; g/ U6 C
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
4 q# b( e! ]% C: M; U                                else0 E4 l, P5 m. d4 \
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),' l- p5 l" ]: }1 n
                                                to_str("in docking station: \"",?.~.name,"\""));                               
* ?/ I# G( S5 b2 s+ Q1 M6 e% T' f9 t                                end;2 e3 T  l( \+ x% |( E
                        else+ |/ a) o4 ~3 H# g/ s
                                @.Destination := assignLObj[1,row];
9 q! r% ^. i) x& P; U# F                        end;                       
5 O! V) G# O* W# j! V                        newDirection(@);
& l$ [( G" _$ A& Y/ n                        @.HasOrder := true;
3 t& v& [& d0 F  T; w                end;
) \  H& B' \( K$ L        end;
8 V$ ^: K9 T$ }) M" x* L7 Gend;        -- of the method
/ U  X& F) T. P! z7 x$ L5 i/ ]
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 + r( b+ M( s3 [9 s; T3 D
9 N4 p, }3 l" M& ~
这是AGV_putin中arrive的method。) Y1 h7 R  p5 h) Y" _, D
" Q7 U3 l: l/ M: t; Z- W# n
当到达物料速度越高时,这个报警更多,
& h8 R9 g2 ]& c& j可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。7 ?7 _, E! N$ z# w
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
& v, T0 e  N+ `% G* W( L4 ^8 Y, y" P
  b# L( m/ D# d! K另外一个小建议,就是move,所有的move都可以这样
" E  H$ G# b( A! Gif not move() then debug end
3 c" t0 S2 ?  s这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。" `: J/ w1 W' r
plant simulation中的free libraries有AGV模板,
; U3 s) ?- i) \, q& D  }9 |8 v里面也有案例。
! Y. |% w  ~% r/ z我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。2 k9 [3 d, Y5 |2 G$ v' V
: n' g1 ]2 \) G  e  N" n  i- z/ e
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 6 M. F1 a4 V- ]5 J

: W* N4 k3 p4 [. g2 t9 W( b7 C/ B; M那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
& b$ z. a3 @: r* i4 a! S, G2 F这是AGV_putin中arrive的method。* L5 p1 m' h' s+ \. _

. R4 }5 i, R) @/ L1 X) D当到达物料速度越高时,这个报警更多,
& b! q/ G% @2 |, L# v* N0 K
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-24 17:40 , Processed in 0.021583 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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