设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10027|回复: 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'
3 z# `' X/ I2 c; G5 X4 s1 Y0 o; r*/
+ ^; w9 U+ ^" J5 V% f: C6 |is8 p8 `9 b( R2 f
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
9 }. L" j# @& q; W: T; Cdo$ O- e+ g  T- t+ N- G  o0 A7 {
        Lan := rootfolder.Internal.Tools.AOLlanguage;  \! w! t6 V. N$ B9 \$ v
        if current = @.Destination -- else return
) m% F3 A; f# W( y2 b+ N3 @        then
% \3 t9 b+ H6 d. r" x                @.Destination := void;, g3 M, W  C+ M/ Q/ o" D$ c2 i
                if @.occupied then' J, r/ S  P# f
                        part := @.cont;
8 m) x& o- s5 ]8 p                        @.transpOrder := void;. I, Y5 A: u7 i6 `& p
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,& F; m& ]6 U% m' t
                                @,root.eventcontroller.simTime);
) ^3 E" }  A" S& s: Z/ B                        @.HasOrder := false;$ H9 w* V+ F2 V6 L
                        @.DrivingHome := true;
8 w+ }. v8 d4 O7 |# H8 s                        rgManager.tryToStartTransOrder;, H- k; ^+ O  P( o
                        if @.Destination = void
6 M$ A! s! j0 G! k  }; \                        then -- no transport order for vehicle @: C( \3 w2 M* F0 D9 g1 F0 B
                                @.Destination :=
% `+ N6 R; h5 L4 F& \" a                                rgManager.nearestFreeStation(@,track.~);
& `+ L0 D( B  h- t" ?* x" S  H4 y                                newDirection(@);   
' H; w- p4 Z1 Q0 I1 p                                if @.Destination /= void then& d1 f- B1 }4 L/ z  z8 V
                                        @.Destination.NumReservation :=
! b- l7 F. [2 n                                        @.Destination.NumReservation + 1;: l5 ^" S# A) q0 I8 z& A' u% ~
                                end;/ X5 U- r6 ~* L/ ?0 _$ _2 x5 c
                                @.CurrIcon := "drivingHome";
# v/ q) i$ {! ~7 x3 k$ I/ a- [  |) `                                @.DrivingHome := true;
" ?3 k$ E! F5 U6 R7 o. G! p                        end;; k9 k( a" ^* `( ?
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
. t. n2 O' {2 [7 Q                        part := @.transpOrder;2 v0 d, e/ p2 g. c- v# B) J
                        part.move(@);-- load part# C$ \; ~, |6 k. {1 G% C
                        @.CurrIcon := "load";
* C7 Y5 ?1 s1 k- Y' W8 @                        GlobalDistObj := part.globDestination;4 q) c. U" B3 j8 }
                        assignLObj := rgmanager.rgAssignL;+ B5 g1 w5 d( ~$ H: H4 a4 ~: j4 B; s% }
                        row := assignLObj.getRowNo(GlobalDistObj);
$ g4 f9 B2 `8 p+ M                        if Row = -1 then -- since 70
# F, y( t7 l0 h- ?% f! X: a% r                                if lan=1 then
8 X" N7 T, z; |! ?                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
, O1 ^6 s5 Z; ^2 ~$ Z. q/ i                                                to_str("in der Andockstation: \"",?.~.name,"\""));! o  O+ @6 O1 d# J: \
                                else
( D: C5 Z& H% z3 T! F                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
" O* g2 e2 I3 C                                                to_str("in docking station: \"",?.~.name,"\""));                                ; E: ?  U  ^0 \. ^
                                end;
0 E4 u. R/ L$ l! u/ U, y$ }8 C                        else( ]9 @7 Q9 t: }+ v- g" g( p
                                @.Destination := assignLObj[1,row];
5 i1 f, q0 O3 c6 }                        end;                       
0 s8 Y% f' ~+ k' H% I! d% f                        newDirection(@);
" c3 X2 ?: g2 _2 O                        @.HasOrder := true;
. r5 a! b$ C$ [, b1 V9 w3 q, ^1 k                end;' v& _/ `% p$ `- ]# S( V/ d7 {7 R
        end;
% }$ t. E' S1 p6 dend;        -- of the method( y6 d5 @) p+ u! c9 E
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 9 Z6 j+ u* N+ I+ d; [* v

( F( t3 k& V5 i  f5 }% r4 ]这是AGV_putin中arrive的method。
3 W; I: Z5 C  |: N* h9 S, m+ A# D* N* s( ]. U+ Z; X9 W, }" V: C7 ~
当到达物料速度越高时,这个报警更多,7 O# V; ?: [; L
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。: B0 C2 W$ P  h& ~2 Z# w
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
5 c: G" Q  i  f( ~5 O' a1 I  f  t" |/ y' c$ _, a' N& c. S; n
另外一个小建议,就是move,所有的move都可以这样# n' S, A" i3 c! X, @
if not move() then debug end& I# P  a8 y9 T: ^
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。0 F; p5 k4 U9 K/ x( D0 S7 U
plant simulation中的free libraries有AGV模板,
( _' z1 u: Z) ~! X里面也有案例。
1 g2 E: X3 S2 `' j我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。1 U" D! @; g) b% R0 j& A

* x5 A" Y4 v( B0 k我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
# Y4 Z: W3 H3 i( J6 ]
7 X: y! V/ g0 H# Z1 h那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
# Y/ o7 Y% G( C( o. m) A这是AGV_putin中arrive的method。# o5 p9 C0 D2 T

$ ~6 V7 z1 b9 `4 y4 w; N4 `当到达物料速度越高时,这个报警更多,

+ Y! U( v2 `" F! B  W7 `, F$ z) M另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-8 06:59 , Processed in 0.021749 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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