设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10239|回复: 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 ?2 j1 }1 S# `4 h& B5 ^# U% u
*/
" m9 w/ o1 Z7 i: |- B1 a6 ]% P" fis3 p5 K/ H8 A* g5 @
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
) f; A# v* U( Y2 Odo. U& R" l  b$ x2 W/ k9 t
        Lan := rootfolder.Internal.Tools.AOLlanguage;6 m. s$ G- y! c( ?
        if current = @.Destination -- else return* {/ d, N4 \0 j8 g' v4 {
        then8 d, Y2 ?% T1 O! n0 R" S
                @.Destination := void;! V/ [) v0 L/ S' v- a4 ~9 h
                if @.occupied then+ ?1 O& Y) ^& J" M" [3 P
                        part := @.cont;$ \- j, ?& `  C! N7 l
                        @.transpOrder := void;  A# D# F+ s( e8 v& v% a
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
5 n" M$ f0 y3 H, t6 L% J6 ?) ~- M2 O                                @,root.eventcontroller.simTime);
7 c" a" Y" n& y8 L1 f: E: S. Q                        @.HasOrder := false;
: F" E4 C1 I# A$ j' T# w6 Q. _                        @.DrivingHome := true;$ K% J* K0 m0 Z
                        rgManager.tryToStartTransOrder;9 E1 M) |5 e* L. ]9 a: C
                        if @.Destination = void+ m! c( n1 g( h: U0 f
                        then -- no transport order for vehicle @
! j( J  V& l2 k* h' l  {; I5 X                                @.Destination :=
  a+ ], l) {; ]9 P$ s7 M* ~                                rgManager.nearestFreeStation(@,track.~);
' d4 {* Q  u( c/ `4 k1 {5 t                                newDirection(@);   1 [; N9 y* P* V- B4 k' z+ W
                                if @.Destination /= void then
5 @, \& E1 {0 I! X% }6 S                                        @.Destination.NumReservation :=" g# E, p. e: X2 |7 I
                                        @.Destination.NumReservation + 1;& H' z2 _+ d: b3 j6 |
                                end;  L8 E. G6 G. H& }0 ]9 O
                                @.CurrIcon := "drivingHome";
3 w: e' @; \9 s6 u+ o* M2 i                                @.DrivingHome := true;
# ?4 v4 \- F  ?0 ~                        end;
. \4 j* |. }; b7 ~                else -- the vehicle @ is empty, both vehicle and part are in the same dock station1 y& g1 N9 _& v; V6 [
                        part := @.transpOrder;
6 e1 p+ \  R. X& h; x* l                        part.move(@);-- load part1 y& |2 W* o" Y: V: p
                        @.CurrIcon := "load";
" Q6 |+ e4 y& E+ g$ x                        GlobalDistObj := part.globDestination;
. f, s6 G# ?6 f( ?7 @                        assignLObj := rgmanager.rgAssignL;& P: T6 y5 g2 t- T( y0 R
                        row := assignLObj.getRowNo(GlobalDistObj);
" L+ w! G4 Z( b- P% V                        if Row = -1 then -- since 70
; b6 _, t2 E9 J8 Q                                if lan=1 then
! h  H1 d) p& I                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
5 ^) ?4 l" |0 v* b+ ?                                                to_str("in der Andockstation: \"",?.~.name,"\""));. X  M/ @* G; {4 @3 {
                                else% p* g  j+ F" w* z, z/ e
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
- _  ^+ u0 n( j! G9 q4 B. J& G7 e( y                                                to_str("in docking station: \"",?.~.name,"\""));                               
8 c+ l) O; J% z1 J' E                                end;, W, ^5 H. {' a
                        else
$ O  L" V4 ?4 }                                @.Destination := assignLObj[1,row];
( O' G+ F' {. F3 e                        end;                        4 ^7 e! W+ N  U
                        newDirection(@);
* W0 d; X. I2 G' ]: {/ k2 w9 a9 ?                        @.HasOrder := true;& t5 |1 p: i0 @& E0 Q* l. J, F
                end;* h9 q  K3 r! ~
        end;
  V# d% ]0 t/ M9 Z" Dend;        -- of the method, ^  L1 k1 O5 B' n
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 - e4 e" D7 d0 c# E$ h* O$ O3 e

) s' w: I+ f) H3 ?* n1 u, s& c+ B* q这是AGV_putin中arrive的method。
. m) s  Z4 P, |8 y) n+ k, K* F. I# s/ Q
当到达物料速度越高时,这个报警更多,6 q6 h2 r! R0 F) g* ~& u6 l
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
  o! s+ p7 V& P8 a* B  p# \1 Z( D程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?& k6 V2 B& d+ N8 w* @8 t

, G& N7 l; [: q4 k另外一个小建议,就是move,所有的move都可以这样
' ^/ B/ ]) `- n+ |( c' g* ~$ z: [if not move() then debug end
- J6 o( {* f! b+ q5 r# s这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
8 ]' k: z5 R0 N1 [; Z& G1 I7 |plant simulation中的free libraries有AGV模板,0 r( M- _% ~" O% t. N7 d0 [% @
里面也有案例。
# H' `/ J' ^  S% P" U& G我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
* d, c1 [: j1 K3 q
6 z1 q3 Z- p( N; C+ t3 E% w我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
1 a6 ]2 o* V3 t
5 S5 l1 k3 d" ~  F; r+ Q那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
9 w1 Q- z; x9 j  y" N这是AGV_putin中arrive的method。5 X0 ^  h% p) k  C$ ]

7 C6 _% T: K7 b& r4 ^( U) a当到达物料速度越高时,这个报警更多,

. n  T+ d9 B! Y1 a8 R另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-22 01:32 , Processed in 0.015922 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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