设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9632|回复: 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'
' c! o9 y- x3 [*/
8 }7 r9 t1 o; G$ E7 x/ O2 Dis1 v* `6 N1 u2 F5 C% p6 s
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
- I0 n, `; ~% W. z. Mdo/ Z1 s, b/ W. l3 R4 v
        Lan := rootfolder.Internal.Tools.AOLlanguage;" e: Q# T1 U7 k
        if current = @.Destination -- else return
* |" L, R5 Y% W' J        then
2 e! F  x" ?6 R, _  j                @.Destination := void;
- t0 @7 ?( ]4 Y8 v                if @.occupied then
( g3 k! P7 x8 R, [5 O* D9 ~9 p9 a                        part := @.cont;+ J' L+ W# S+ B+ I/ D% R! R
                        @.transpOrder := void;
5 f$ q8 q6 v0 e& B) ?, N                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,. t/ p# q7 h, X) j& X3 B  [! s. G
                                @,root.eventcontroller.simTime);
7 k- E+ g3 g! a3 X1 s6 q# y2 f                        @.HasOrder := false;. N& M9 ]8 `6 H' F% R# |
                        @.DrivingHome := true;
% ?! q' Z" t% S9 t$ f                        rgManager.tryToStartTransOrder;
4 g; }% c) E, Z: D# T                        if @.Destination = void$ ]! m3 F- V& A' {
                        then -- no transport order for vehicle @/ v+ J  j3 b# g8 i
                                @.Destination :=( z' C, ~2 Y* i/ t
                                rgManager.nearestFreeStation(@,track.~);  l1 d5 D( Y* h" l1 P, N  _. V
                                newDirection(@);   4 ^$ Z! O7 W7 P
                                if @.Destination /= void then
, D3 p2 B( ]- E  u" M                                        @.Destination.NumReservation :=
3 h3 E; Q2 f( m( z                                        @.Destination.NumReservation + 1;
% H- Z* u4 v8 [1 a" M, q: m                                end;1 X% u8 e4 h+ u) `1 t
                                @.CurrIcon := "drivingHome";
. s* k: J3 ?' r4 J  J7 }                                @.DrivingHome := true;3 l6 z2 a6 I: Q4 V) b
                        end;5 c1 b% `! a( `  `. Z, h  Y
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
% G" T% U2 a6 y7 M" {( V' [                        part := @.transpOrder;4 I: N3 E5 c1 n7 b8 Z- O5 }7 y
                        part.move(@);-- load part
. D( K. p. y* M2 W0 H# F% T' F8 T                        @.CurrIcon := "load";
0 I- u' f+ m% i2 ~/ P6 Z0 D                        GlobalDistObj := part.globDestination;9 h7 Y. O) f& g/ i9 }4 _) w
                        assignLObj := rgmanager.rgAssignL;
: _! Y3 p8 ~5 `7 @' m  G                        row := assignLObj.getRowNo(GlobalDistObj);8 s& {% O$ p' {% G1 m) S
                        if Row = -1 then -- since 70
! [7 C- B  r4 j( g; I                                if lan=1 then% R/ M: I6 I/ {0 A7 u
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),( m1 j4 Z4 |% ]  ~; v1 j/ Y# Z5 x
                                                to_str("in der Andockstation: \"",?.~.name,"\""));2 R. [% \% s. F% U8 d# ?: ~
                                else
" X. h' s7 f8 |( \) V1 b7 t                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),& p4 q1 S  x( @. r; R- e4 j
                                                to_str("in docking station: \"",?.~.name,"\""));                                , R6 f( Z$ w* x
                                end;9 ?* h8 j/ y5 z+ V0 f, d
                        else8 W" ^* K! T4 Z
                                @.Destination := assignLObj[1,row];
1 d7 V; ~) I0 W# E4 n( @8 Y+ f                        end;                       
2 A9 T" B% ?: _' j& j9 R                        newDirection(@);
% P' O  }* K7 P+ A9 O' |1 V                        @.HasOrder := true;. y$ Z/ R2 L0 h5 {4 |2 y
                end;2 q$ f* V7 \9 R' m
        end;
7 j; T1 U, L+ send;        -- of the method
* w1 d- \6 |& b& l; u7 G$ o
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 0 e+ N# G2 y/ z0 o

8 `0 U5 |" N6 q  E这是AGV_putin中arrive的method。
+ ^3 T5 F1 e5 d# j/ j" k$ I' F, e. f3 r
当到达物料速度越高时,这个报警更多,
9 p9 h: I- T. M, j可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。2 k& u3 u- l& I7 b
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
$ b- u: F- b1 ~0 t% W
* Q, s5 k6 y7 t; B) ~5 ~另外一个小建议,就是move,所有的move都可以这样
* _8 V  A+ d: {9 u& a# `2 m. n* U; aif not move() then debug end6 l' L& f6 P! ?3 r6 z
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。. [+ b% h# D9 Z, t* W$ a+ Z9 z
plant simulation中的free libraries有AGV模板,
. U: i; f" M0 ^* s2 K里面也有案例。
3 a, d# o- R; P3 d7 _+ R( L1 L8 N我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
- A% Z4 f/ t/ Q* {/ E; S& W8 v; v  z$ T: p3 w  X4 c
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 - r0 Q, N  q& Z5 A4 Y$ ^
9 U' n& d8 W7 H) D. |
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
3 n. F4 F8 [" \2 n4 x& @) u这是AGV_putin中arrive的method。
4 S4 C+ Q) |* w5 v8 H' C
1 ?  S1 B4 u, i  M当到达物料速度越高时,这个报警更多,
8 ~. n3 ^5 a" u, r& D' k5 y
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-13 03:32 , Processed in 0.023369 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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