设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6726|回复: 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'
1 ^0 [7 j  @1 o*/  A1 M$ W4 F( g1 M1 ^/ d' d" r
is
& L+ D/ J7 A+ y& m) O        part, GlobalDistObj, assignLObj:object;row,Lan:integer;5 C! J0 a) [" n7 h  b$ s
do# g. n: x: r: L/ S. f2 A
        Lan := rootfolder.Internal.Tools.AOLlanguage;" |+ t5 w  z, H. v4 ~
        if current = @.Destination -- else return/ {" V5 P5 Z1 S$ n+ u. Y2 F* H
        then
1 }. C- S" {  _' M                @.Destination := void;
& V- P7 Z: c$ T" L' A. M: X# u                if @.occupied then# ?* `. z& v7 X4 [- ?( Y, `' F
                        part := @.cont;' J( \2 O& G( K- f( N9 I
                        @.transpOrder := void;# A; t2 z5 I! @7 O, q5 s
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,8 l" d* K- M/ t1 u! _
                                @,root.eventcontroller.simTime);
5 g3 M( d) m1 G" I' h! X                        @.HasOrder := false;
% s# q/ s* g2 k4 {& J                        @.DrivingHome := true;& ^& |' m0 z& R6 f* `9 I/ G* Y: H' y
                        rgManager.tryToStartTransOrder;
2 v8 `+ `5 W! g2 q                        if @.Destination = void7 M- x9 `# n0 |- b' f- Z  g6 o
                        then -- no transport order for vehicle @8 W* p* O; W$ C8 R/ h$ k2 q
                                @.Destination :=8 g' V* h; F7 l0 v1 z4 q( A: R
                                rgManager.nearestFreeStation(@,track.~);
% l) L; P7 s6 v( h5 K; [+ z3 o                                newDirection(@);   ) p9 ^0 A" l" |3 G: v' u! @& P
                                if @.Destination /= void then
( o6 k9 ~" W$ o+ n5 T  X$ S  T) F                                        @.Destination.NumReservation :=. M- P  t$ I7 e
                                        @.Destination.NumReservation + 1;
$ d0 Y* e1 n  H( H/ n* j  y                                end;
9 F9 r0 g: f. D# i$ M! e                                @.CurrIcon := "drivingHome";4 P; l& a0 ^! s. C8 P8 J" t. K
                                @.DrivingHome := true;
. S0 I8 Y7 q5 i! d$ B& V$ b                        end;; B1 f5 h/ D" i/ i% M+ I7 f
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station5 k; @4 L, s7 ]' G, }
                        part := @.transpOrder;
% X. c) g5 q% r; \                        part.move(@);-- load part
, H8 g: C1 u! ~                        @.CurrIcon := "load";$ s- F1 \' V0 _4 M8 R* g8 u
                        GlobalDistObj := part.globDestination;
1 x' a( u' W4 d                        assignLObj := rgmanager.rgAssignL;5 s$ _1 p. \% {& G% b5 d
                        row := assignLObj.getRowNo(GlobalDistObj);. Z8 s% m4 p, z0 n1 _' i8 m
                        if Row = -1 then -- since 70
: S: u3 q/ k, B8 T' `                                if lan=1 then2 K' t( e3 b* A/ J) l7 S9 v
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),, f) J  e  {6 G* z" L5 U4 Q
                                                to_str("in der Andockstation: \"",?.~.name,"\""));& m' q  E7 F9 O  `: B0 o- Z
                                else! ^3 `5 M1 y# q
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),! t1 Q; I7 Q( q/ m8 a) d. Q& K; m
                                                to_str("in docking station: \"",?.~.name,"\""));                                % m. c# f9 c7 A6 @2 }* R! i" O9 M  J
                                end;
/ \7 r; K' m7 ^5 X: \) o8 ?                        else3 c$ H7 Z) L& u$ p! ]% e0 C
                                @.Destination := assignLObj[1,row];
0 [) T$ l$ `& `& f" \0 v. I' B; p; P# o                        end;                        * J: ~6 Z6 F5 \% z! E7 w. n
                        newDirection(@);. _3 w' ?& ?# n% g: R
                        @.HasOrder := true;
0 D2 Z7 ]8 p$ k+ P                end;2 x% t& Q, W" @- O: G4 }8 |
        end;9 q, @7 R8 T# d" E! z' N
end;        -- of the method! P) M6 |  Q) A' v
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 - }2 {: ~- z; Q2 h

' d  S$ U+ b  Y: {% j这是AGV_putin中arrive的method。
- V* H  i! k5 t( S+ x9 `# E- b# G$ d8 T6 I6 G4 C" ?5 [
当到达物料速度越高时,这个报警更多,, C. p0 D! W/ `
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
4 I0 B) ~5 m7 r3 H3 V5 E程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?- a3 ~# z  l7 \8 R

* D3 f0 r/ J% L  W另外一个小建议,就是move,所有的move都可以这样/ B/ v2 R) Q* }3 z: V" m* U/ p
if not move() then debug end
. S: L; ~1 V6 X- M8 R- \* j这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。! G/ k0 I8 A$ _/ N
plant simulation中的free libraries有AGV模板,
/ p( \# C0 c9 T6 Z5 V里面也有案例。
* x: W# k% L6 }- @+ f& k我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
8 [9 S/ ]( [+ T6 N1 G+ H! `
7 s# R; J$ K+ d, M我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
+ h- v+ y6 X9 a5 K/ f. d
8 A# i+ d& _2 S! @" u那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
- H: Z; Z: ?* B5 i# s8 ~这是AGV_putin中arrive的method。
+ ]# Q( k8 h2 R$ l( o$ b0 h- s
" w+ L+ a/ w# B5 }. @1 {" G  o6 {当到达物料速度越高时,这个报警更多,

+ _+ B4 G1 ]/ U, ^* w! C7 s另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-22 23:36 , Processed in 0.014983 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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