设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7050|回复: 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'
  R' M+ q6 ?& h% ]*/+ e7 e$ N4 `' g$ D7 K+ V6 G' k
is
6 ]  B" D" K  k        part, GlobalDistObj, assignLObj:object;row,Lan:integer;0 _" K/ ~7 L+ o; m; L1 L
do3 h2 Z# Q) e" g! M/ q/ @
        Lan := rootfolder.Internal.Tools.AOLlanguage;
: A1 F9 U1 y# {  f3 H        if current = @.Destination -- else return/ t! t8 @' \! a
        then2 C3 F/ v# D# z; j& T1 t0 S" c! o+ e1 ~
                @.Destination := void;% @" k$ u; [0 |9 Z& w( M5 D
                if @.occupied then5 b- K* x* ^, K- ^& o/ u% [
                        part := @.cont;( t5 }3 [7 W- P6 C9 V2 L) E1 |- y
                        @.transpOrder := void;$ S* d4 p) `, g& M( k% n5 _- ?
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
7 j( Q2 x: _. G2 U                                @,root.eventcontroller.simTime);
7 n) o! W: M, S/ Y: ~" N* G% ]                        @.HasOrder := false;4 Y1 x# H/ B0 {. m
                        @.DrivingHome := true;4 q" T6 ?% y8 V1 X
                        rgManager.tryToStartTransOrder;
8 ?1 h2 Q# `) g: l# ]                        if @.Destination = void
; ]- n8 Q- r$ c; K) q6 L8 t                        then -- no transport order for vehicle @
0 h2 \" D, D0 M" s2 ]$ r                                @.Destination :=' a% F/ R' z" i2 m% f
                                rgManager.nearestFreeStation(@,track.~);
! P/ B+ V% e( \                                newDirection(@);   
, Q: }& J" V2 |: ^# P! M                                if @.Destination /= void then
, q, C( o7 K* T: C1 @                                        @.Destination.NumReservation :=! D; ]7 G5 ^# U3 T. `7 T$ n, `4 }3 b
                                        @.Destination.NumReservation + 1;
) J/ l! O4 \! V- P7 ]$ t3 E                                end;
3 D# A" w1 s3 U1 w4 ^8 a                                @.CurrIcon := "drivingHome";, X! ?  a0 t! \0 w
                                @.DrivingHome := true;
* X1 ^* K) a3 Q; {$ Z                        end;
* B- e$ w' D. O* T; R" E5 P                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
0 t# {( X! j  L5 J* R                        part := @.transpOrder;; _5 g. q3 h8 }8 {7 J( e* K
                        part.move(@);-- load part
- R! `; i& @- `8 T                        @.CurrIcon := "load";
9 l* a) _: G% k4 d; Z$ {0 H8 ^                        GlobalDistObj := part.globDestination;. q; H, F' a& `4 ~7 O' \
                        assignLObj := rgmanager.rgAssignL;, w4 w! |+ A% q* F
                        row := assignLObj.getRowNo(GlobalDistObj);- n  h" h0 S( g: ?; l7 O/ }
                        if Row = -1 then -- since 70
+ I2 r% y2 R% h6 W                                if lan=1 then' G% `3 P& q# P: ^: V
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
9 ^8 [  d# M: l                                                to_str("in der Andockstation: \"",?.~.name,"\""));" @7 y. h4 z9 {( S9 c6 q) s' I
                                else
2 I9 R6 C# @/ I: H5 X' ~                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),& s  X1 c, O0 ]
                                                to_str("in docking station: \"",?.~.name,"\""));                               
4 I$ h% O0 P. m" h; r- n# R                                end;
, I2 y% T: V1 ^                        else( m, n5 C2 J5 G: I6 W! c
                                @.Destination := assignLObj[1,row];5 o% A# D; s6 y2 C+ o
                        end;                        / C! s- p% h; M
                        newDirection(@);
# {- G. R5 ]* A' G9 L0 p                        @.HasOrder := true;
6 f3 u9 y- T# G" I0 X5 V( q                end;6 n) `# v/ E2 C' H* q, R7 R
        end;
; G6 M  {' N3 B; E9 R6 Gend;        -- of the method  `( K+ M' y2 P& {, Z
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ( _8 [5 K( Y5 B4 q9 B# {
: t: h4 y8 X% K
这是AGV_putin中arrive的method。7 `; V8 f9 B- r4 i! }5 s# ]

7 d" m( g& @) o; }( k$ K& a% b8 E6 X: D当到达物料速度越高时,这个报警更多,/ S; l" p7 c' a3 S0 I' ^" K$ A6 \0 K
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
& `! H  K3 B  e0 L) _7 f2 v程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?* d/ [- h% U$ U2 r( v

8 u8 a7 W$ E7 R9 S) q另外一个小建议,就是move,所有的move都可以这样
# _# y9 e2 _  U( ^) pif not move() then debug end
3 [. Y- S5 W/ m& H这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。6 U4 ^1 ]/ @) S5 s( h% j
plant simulation中的free libraries有AGV模板,& c% T4 j  R. t% N9 _3 A8 v- ]
里面也有案例。
* s1 k  I- d  N; N) c( P# ~我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。2 ~6 I7 [) @! N- a; V
( {6 t7 ?( p+ T! W  a( T$ ^: Q
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 5 A- h6 b$ @: d. z( Y
- {, O0 I+ T4 ?8 S; ~7 W2 v6 ^
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
1 S" w; `0 N! W8 P# E' o这是AGV_putin中arrive的method。5 M4 c( A: x/ b

% R/ ~$ a( R3 B. S# T! H当到达物料速度越高时,这个报警更多,
# d3 H5 k/ E4 U
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-13 12:08 , Processed in 0.018013 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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