设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10303|回复: 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'
7 |! j5 f3 K* d) j6 V3 @3 T/ }*/
8 `- k: P) k: ~, Y  Yis
) K1 r* w( X% J. v. Q2 s8 Z        part, GlobalDistObj, assignLObj:object;row,Lan:integer;& {: ]  r; _; `/ d3 V/ H
do, H/ F9 `: R0 o+ u% j
        Lan := rootfolder.Internal.Tools.AOLlanguage;5 w1 \7 s6 E% y1 ~
        if current = @.Destination -- else return1 d+ F8 ^2 G) v) _. i
        then
+ i5 a0 w& @+ q! v. B0 m$ M" ]                @.Destination := void;# y4 q# G+ H* n! t4 q2 P
                if @.occupied then' P2 g. |6 }* c1 u+ @: y  G$ [
                        part := @.cont;
+ r  S  t, w: X; t$ D0 A; h* y                        @.transpOrder := void;
9 n5 r: [' P3 ^* ^- \                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,* F* F' L7 K% p" e, r% S7 O" D
                                @,root.eventcontroller.simTime);: i# d2 L- ^3 w" p
                        @.HasOrder := false;
, h: o  S' t7 l2 F                        @.DrivingHome := true;
: R1 h+ F/ t1 r                        rgManager.tryToStartTransOrder;
& `, c/ Z& n# U) d7 J/ w( ~                        if @.Destination = void
( G" K+ c: d& `3 n                        then -- no transport order for vehicle @
# {, e5 @6 u# g2 z2 ^                                @.Destination :=! C2 t5 T2 j( K6 e& J/ k' W
                                rgManager.nearestFreeStation(@,track.~);4 X/ D; ?+ \, ~1 U9 K
                                newDirection(@);   
* g/ J0 A( O+ q" M) N* c                                if @.Destination /= void then
( d. e& b% i1 e' [$ w7 p6 ]                                        @.Destination.NumReservation :=# r; ~3 O8 F/ W9 F! J& k6 V
                                        @.Destination.NumReservation + 1;
" a- O0 R( W( }& V* j                                end;
, |% ^3 T" {+ F3 V! x                                @.CurrIcon := "drivingHome";2 ?/ g9 J9 y8 M$ F
                                @.DrivingHome := true;7 ^; E& P/ ^4 X; Q% n* b6 u
                        end;
2 {0 r" Y$ Q* ^( G! {                else -- the vehicle @ is empty, both vehicle and part are in the same dock station1 U8 K4 Y* b) H) M. N
                        part := @.transpOrder;3 `$ ]: A: E9 e% A5 J5 C4 ?+ n
                        part.move(@);-- load part
! ]& o4 o+ S! q  j* d$ x                        @.CurrIcon := "load";
' c. R% ^6 h; K1 l6 M. X& b                        GlobalDistObj := part.globDestination;
7 L% I% W3 J: z4 o                        assignLObj := rgmanager.rgAssignL;
: d5 R8 _/ M* G6 X                        row := assignLObj.getRowNo(GlobalDistObj);- S8 k9 y: N4 G+ S  U7 g
                        if Row = -1 then -- since 70
2 h8 _& b+ F2 [/ [" S                                if lan=1 then( L1 E& W) ^  W1 r$ ]. E# `' d
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),# L& Z4 T' G! a: H
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
* G5 o1 {' |  R8 S9 g% _5 W                                else7 n& D$ D' q: x) m2 E8 A
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),4 Z6 d( @5 m5 {* d  E
                                                to_str("in docking station: \"",?.~.name,"\""));                               
3 p: F; k  O9 `' j  L. S/ k                                end;
1 V- C- T% l( e4 U4 ~) r                        else
# s% ~, b5 P: C& n% g$ p( W& o                                @.Destination := assignLObj[1,row];
5 r5 j9 W6 s  K2 f                        end;                        * H& T0 r5 H- W
                        newDirection(@);
4 s0 O. U+ [/ c                        @.HasOrder := true;
: G0 r# O& E/ J6 p. x4 M0 o                end;
: I8 f9 o  _7 _7 _3 P. x) W& R6 d        end;5 O% T' ^+ ~% g- e6 n% o" V9 f  N
end;        -- of the method) d. \6 W; P1 c6 D+ q+ b8 K$ p
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 6 T" r! i' F( Z! H4 `

/ p# k5 i* J9 e% \# Y7 q# ?这是AGV_putin中arrive的method。  R( O  T- F" Q. d. @

8 d1 Q8 c0 k7 F- t8 I. w( c当到达物料速度越高时,这个报警更多,. L' C, U5 `% b' N$ u9 d
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。" g1 V  N4 v" O+ `( E
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?8 `/ H7 a4 Q4 V' C& ]  G

% N% }+ J* ^/ V另外一个小建议,就是move,所有的move都可以这样
- T, [  y! g! q, j0 Cif not move() then debug end
8 y, y; J/ I/ C0 @! h* a5 ~这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
/ n' H) Z6 T3 C' _2 Iplant simulation中的free libraries有AGV模板,  D- H5 \% X2 Y, E% y/ L) w6 b
里面也有案例。
. O7 O1 E' Q* L1 N我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
) e  i( F& [8 h+ A0 T% ~7 f9 |, M/ |3 w0 w8 Z- |% ~& `
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 0 L' ]+ W& e" m- m# H6 }$ K
0 B! @& i. C$ B1 `1 d
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 1 @* ~% u- I5 j( ]2 Z4 l* H
这是AGV_putin中arrive的method。
1 t6 G! o5 m0 V1 a) ~- ^
7 }/ v- ^: }1 I3 ?当到达物料速度越高时,这个报警更多,

. N+ M1 u; c( k" N另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-25 23:48 , Processed in 0.018718 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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