设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5259|回复: 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'
4 P) l3 m1 a2 U: [0 n; N; M9 a2 H*/
) p# }. k. e" a. X: eis
) Y& v( E6 _$ F. T        part, GlobalDistObj, assignLObj:object;row,Lan:integer;! B# |+ i* Z8 W, w8 i, ~' ^
do
+ t' Y  O- x+ J9 a& j+ q        Lan := rootfolder.Internal.Tools.AOLlanguage;
3 y" `. g9 @0 j9 K# b5 v        if current = @.Destination -- else return
- G0 e9 g, X0 _. ^$ z+ \        then
# p6 L/ {1 }7 ?9 t8 r% y7 F8 y8 G                @.Destination := void;
: y$ V$ ^" |  e8 P0 f. F. Z                if @.occupied then) }, n4 K; h! u# L
                        part := @.cont;
) H* S: b2 \; p% e                        @.transpOrder := void;
; i% F7 g, z. U9 ]                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
/ X: E/ i) P, `2 C# p+ h                                @,root.eventcontroller.simTime);
! P: M7 H/ M. m) M4 H                        @.HasOrder := false;
9 \1 V6 K/ G% ]/ ]+ P                        @.DrivingHome := true;: t. n+ _3 q% a6 I+ [
                        rgManager.tryToStartTransOrder;
# ^4 B4 s7 |; l9 y2 g                        if @.Destination = void: F  I  g) a& E. h
                        then -- no transport order for vehicle @2 W; D/ E6 R* p& u0 S5 g# p
                                @.Destination :=
3 }, V- w3 k* L1 t/ C& N! j1 {% m) ^                                rgManager.nearestFreeStation(@,track.~);
$ B, I2 z8 ^0 ]; O% D: ]6 A" a$ ~                                newDirection(@);   
# P& `7 E) w  z+ J' V' o5 b                                if @.Destination /= void then
6 p* x2 J+ h5 A, b                                        @.Destination.NumReservation :=$ A, c7 s4 b+ p0 g
                                        @.Destination.NumReservation + 1;
/ B4 v7 U, ?2 g% p" x                                end;
$ s" F! u8 G; ?* y7 Q5 X) [$ [                                @.CurrIcon := "drivingHome";7 |1 }$ z4 }# N" \  J5 {# @/ |0 {
                                @.DrivingHome := true;. K9 e) G) ?: i
                        end;, Q1 u$ V, |0 c6 ~% f% ?/ l( D
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
( I0 p8 B+ {& I$ _7 p                        part := @.transpOrder;
- Q: |4 Q$ U0 X) d( s! \                        part.move(@);-- load part
4 D( H9 u. g+ [; Y: Y2 R                        @.CurrIcon := "load";
- E5 ]2 y) z  y: F                        GlobalDistObj := part.globDestination;
- t, B) K& ^. ?" B* j                        assignLObj := rgmanager.rgAssignL;
, D! W' u+ [  L                        row := assignLObj.getRowNo(GlobalDistObj);% T$ g- Q+ ?" u: I* k6 E2 C
                        if Row = -1 then -- since 706 q. v: G) F: P' U
                                if lan=1 then
5 g) i# l. x7 h8 s                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
3 l! t( j& z9 _! q                                                to_str("in der Andockstation: \"",?.~.name,"\""));4 Z  E. X8 q' Y& Q2 x. g
                                else1 [% q) Z, O, X( ~7 n* N2 c1 ^# L
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),# f. q! r7 ^9 X/ M& p4 c
                                                to_str("in docking station: \"",?.~.name,"\""));                               
& B+ [$ u# T$ C2 k% I+ H; t                                end;
7 }8 K2 V! r0 `                        else6 e7 g0 o/ O0 x6 L
                                @.Destination := assignLObj[1,row];
: m% w; G( a9 e) _8 X" x2 F                        end;                        $ b) E! ^1 H3 V
                        newDirection(@);
# U9 w0 @! t8 g) q2 d                        @.HasOrder := true;. i9 r& v) I2 w
                end;& r6 d- j3 C1 D
        end;$ [* k# V( s( D5 f5 a
end;        -- of the method
, j6 J( j: I8 P* ]6 [/ P
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
  c' y, j. ?6 t* g/ v9 x
" s+ \, k. c, c) e  o) K这是AGV_putin中arrive的method。
# Q7 v0 F% ^# _1 S: \  q% T/ A7 `
当到达物料速度越高时,这个报警更多,
8 M; b0 H) v5 K' {& [6 I; P( x可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。3 m1 Z3 [; X  e) p! x
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
2 o* E$ j5 K( D5 y) z0 p* E2 W. W8 ?* L, @8 W
另外一个小建议,就是move,所有的move都可以这样
, ~3 B$ }5 s9 Y( ?if not move() then debug end7 {. l( N% O7 ]
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。% n1 Z5 f3 f, W6 n* f/ ?
plant simulation中的free libraries有AGV模板,9 \1 J1 ~5 ^/ E; I% ~, F$ P, B
里面也有案例。- f# R- S- D2 z
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
6 e- W, I  Q* H
8 l: Y8 I( h& t+ b我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
9 [; s8 N! w+ A% p, J$ j' G
# A. G1 A- r) o那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
' N3 [/ z8 e; Q) S- e/ i这是AGV_putin中arrive的method。
1 n% j4 K5 i& ?  E
, Q! L" B  t# j/ [当到达物料速度越高时,这个报警更多,

7 n) g2 j* Y- }" w( @, Z另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-11-6 01:47 , Processed in 0.017706 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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