设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8669|回复: 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': D# H# u9 }7 A  L3 n. N
*/
6 [! K: L7 |* Y8 His
# x( l# d5 g8 i2 n) ^, q+ Y        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
# O+ B4 l* N  F  t7 O2 edo# Q! o7 y% \' o$ S
        Lan := rootfolder.Internal.Tools.AOLlanguage;
1 R% ?/ |# K2 z0 m$ R        if current = @.Destination -- else return& `5 {- ?; y) B/ g1 c
        then+ \& z' \  W! \! v. {4 y% k! l( h- p
                @.Destination := void;& A/ m' t' n+ y/ c3 j* q" i: {
                if @.occupied then
( u0 {- \6 U6 |; G                        part := @.cont;
, U( ~& |# c1 x0 E1 Q                        @.transpOrder := void;$ x0 O2 v- d9 N9 e
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
# Q# f' ^, }; z; z- G; I, ^4 E, O4 F) W                                @,root.eventcontroller.simTime);! |& q( ?  c4 B0 M
                        @.HasOrder := false;
3 A) `( S) d4 }# x! z6 l                        @.DrivingHome := true;* Z8 O$ P/ w& O) F$ H% v
                        rgManager.tryToStartTransOrder;
7 L& p: `$ X! ^8 G0 o: ^                        if @.Destination = void
6 p  ?' b3 j" h6 T                        then -- no transport order for vehicle @
- w: x/ Y, N' u/ I- h# m  z$ S                                @.Destination :=
! h+ F1 E1 V3 V, B+ x' G                                rgManager.nearestFreeStation(@,track.~);" f1 [0 }, b2 x1 l
                                newDirection(@);   
2 l) e2 ?; ^2 K! n3 m% g                                if @.Destination /= void then' x" U- U* f# D, A2 R9 t4 }
                                        @.Destination.NumReservation :=7 N4 V* g, }  T$ D$ q' `
                                        @.Destination.NumReservation + 1;
" Z) ~3 b; ~  l+ R" y                                end;
9 ?1 [* K/ Q1 T2 |. |1 M5 V4 r                                @.CurrIcon := "drivingHome";1 T* o4 U4 w; t- ~
                                @.DrivingHome := true;, E. Q- a* e! O
                        end;
$ q) Z1 p3 i1 ~- q                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
0 K  C6 x1 Z4 g$ y. X0 H( x                        part := @.transpOrder;
) U$ u  h. G# y* _                        part.move(@);-- load part% t7 S+ A6 B9 y' J
                        @.CurrIcon := "load";  M; m! N: @" h0 T5 O5 A5 X5 ~
                        GlobalDistObj := part.globDestination;0 p5 w. m9 ]) T, r; G, ~$ J$ C0 Q
                        assignLObj := rgmanager.rgAssignL;
- M8 w% J) _. u! b# X0 @# F                        row := assignLObj.getRowNo(GlobalDistObj);6 O; n! t; l3 T; W6 J7 C+ j
                        if Row = -1 then -- since 70
: ]. Q( K* `! W6 x4 r4 B                                if lan=1 then& t) g. R8 s9 [5 C3 O: @
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
9 c. i/ [/ c4 x! |+ l" b" D  C                                                to_str("in der Andockstation: \"",?.~.name,"\""));( h6 s# p2 |3 n' |# E, P; i+ @
                                else
* E6 l7 B  \0 G  v. M, K                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
9 }  B' Z3 A  H. a9 l                                                to_str("in docking station: \"",?.~.name,"\""));                               
8 ?; h, e/ H, L                                end;
$ @3 F9 M/ W! n8 F) X7 Y8 W                        else
# O8 A  \% O  s' V/ V                                @.Destination := assignLObj[1,row];; b' P( P6 l5 V7 p4 L" D8 |
                        end;                        6 O! L- Y' |+ u" }) m
                        newDirection(@);
" q) k. x3 k* F) k5 n+ r# y                        @.HasOrder := true;
. Z' I' R; g3 @$ u$ i) B5 S                end;, K3 g8 A. z& N" F+ c, e. O
        end;* u  C- [0 E" i) a
end;        -- of the method
+ p( d9 u3 D& z) V7 z* n1 T
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
0 x. U$ {% u1 c( x
- u( p; N! B3 B# Q这是AGV_putin中arrive的method。4 H5 U4 ~* C  P9 A
. n3 O% _+ P9 T1 R
当到达物料速度越高时,这个报警更多,
- P2 r% c' Y( {; s. |* p可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
5 s( A1 e0 Q1 A5 m9 |/ o' c程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?1 d7 ]: J: p- `  C' T8 U
8 J' ^' c( U: N0 k0 r& h
另外一个小建议,就是move,所有的move都可以这样1 X9 e) e3 x" [1 a- t" z
if not move() then debug end
" k0 ^% t7 A% K: F4 F, Y8 T, X这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。  j- ~) D# @. d5 A
plant simulation中的free libraries有AGV模板,  k6 _: ^! g5 G. K, [/ H9 @2 Q
里面也有案例。0 f+ a9 u9 k: ]: r8 Q9 I
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。* ~! _  s5 x3 k6 n$ @$ U1 M
- S/ A" d# J" X: t/ o
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 & K" i+ y3 ?/ e/ m
# d6 Z+ v: Y" I& q# R. }5 |- ~' p
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
* L7 ]! E! j  Q5 T7 w这是AGV_putin中arrive的method。  @# P7 \* r4 F
3 |/ z, O  f! M7 Y, o1 R+ I
当到达物料速度越高时,这个报警更多,
( s& H) g9 i- C$ R% G. g
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-19 04:59 , Processed in 0.015355 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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