设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6448|回复: 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'
0 o* n: X' u' w  ]  c! P*/
1 }9 f; x$ c9 `8 H* X9 L( _is, V( ^. j! p, P9 H
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
: l/ V4 D$ q3 W0 bdo
9 }$ H& U. G/ m7 T$ d) r( V1 S7 Y  r        Lan := rootfolder.Internal.Tools.AOLlanguage;& E8 j- P6 C; `) k, O; ?
        if current = @.Destination -- else return9 e* H/ W* w2 U& o
        then& R7 Q5 j' j4 w( c7 i# U
                @.Destination := void;- T" V4 W: U2 _6 a
                if @.occupied then
9 l. m0 r6 J4 F/ P! `6 m                        part := @.cont;
) s/ n! L3 r" C4 l4 B/ n                        @.transpOrder := void;6 ~* }& g) u# }, o/ `1 t
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,! `. |& n  P6 _5 ~. o
                                @,root.eventcontroller.simTime);( K& A4 _+ \! }9 v! v: l$ ?. l3 a( Z
                        @.HasOrder := false;
+ f! q2 h; }) Y" L                        @.DrivingHome := true;' |* i, S7 f3 U
                        rgManager.tryToStartTransOrder;9 }4 q( T- Y' I" v3 N+ y
                        if @.Destination = void
( q8 Z' X9 |$ k9 i# ^3 i                        then -- no transport order for vehicle @9 o8 t4 X  E6 r9 l/ v0 p+ D8 a! f
                                @.Destination :=1 b0 y( H$ w$ {( J$ G$ v
                                rgManager.nearestFreeStation(@,track.~);* k  z( t/ D' s% c; X% S  T
                                newDirection(@);   ' F* E9 q5 w0 o% B+ j* k5 J4 W* B
                                if @.Destination /= void then: ^/ Z, I. u! Q8 a9 ~
                                        @.Destination.NumReservation :=
0 N5 m" m8 {; J- K, z                                        @.Destination.NumReservation + 1;
6 p$ M2 K' b" Y. l1 Y                                end;$ a7 B- `1 {6 N/ P" u) O6 A) N
                                @.CurrIcon := "drivingHome";* C' T+ L6 o! @
                                @.DrivingHome := true;
; g" F4 a" y. t4 N: @4 V: V, @                        end;6 |6 i. s5 g! t8 F/ y, \1 G) s  ?6 z
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
: a+ h6 _  T; X4 ?                        part := @.transpOrder;
+ j+ g3 C: {& E0 E+ E1 i+ t0 O                        part.move(@);-- load part& E; ]% W# z. w% ~0 ]
                        @.CurrIcon := "load";. q: F0 _+ y, d# B. v
                        GlobalDistObj := part.globDestination;
* p# S+ J. o! w' r                        assignLObj := rgmanager.rgAssignL;/ \! `, p" E; m" a4 r
                        row := assignLObj.getRowNo(GlobalDistObj);
" O9 Z/ j5 B. U% F  J                        if Row = -1 then -- since 70* H4 D0 t6 ~. v, z0 a) A/ R
                                if lan=1 then
  _$ G+ W! H# I4 a9 s* B                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),) |8 R% G; S" m" t
                                                to_str("in der Andockstation: \"",?.~.name,"\""));6 b3 w9 `2 F  ^" [
                                else; T$ E" }. |) f; m" E6 i
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),# f! h+ n6 S0 a! {
                                                to_str("in docking station: \"",?.~.name,"\""));                               
( [" g4 p* _# L2 l; n" z                                end;' C$ v" j6 b; g1 k) m
                        else
. D9 D6 v7 k1 P6 U- A                                @.Destination := assignLObj[1,row];' i" D3 X& s) E* u7 [, S
                        end;                        6 c3 _+ B% E* A0 V- p8 b9 w( J
                        newDirection(@);& R' w+ [  h! e: t& r2 Z6 e
                        @.HasOrder := true;
( ~: a- J7 q" l+ }4 ?/ y/ U, v" \/ f                end;3 r- F2 C9 v) Y
        end;9 q& U0 w4 f. Y+ G: N8 w
end;        -- of the method
9 j% b& V. r' P
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 " n# C. i5 I6 C* f
& P$ d! ?  j: d" f- I2 e3 G
这是AGV_putin中arrive的method。7 b$ K* ^& y4 R$ O
8 M  C: ^, Z* s4 N
当到达物料速度越高时,这个报警更多,7 L) ]5 P( d0 O- A3 C
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。- T& w; E- q. |  q' G9 }2 p
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
5 e- W1 }' I. c% n: G2 V
  w5 \" w( O1 @另外一个小建议,就是move,所有的move都可以这样& a- X: X  j. q* e2 E# ^
if not move() then debug end
5 x6 V; p, G' I* V# C3 q: V# B/ l这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
3 O( m, W  K: `/ O  m3 x0 o$ bplant simulation中的free libraries有AGV模板,
! q$ h5 n$ X: Z1 D2 I! W/ g) k里面也有案例。# Y+ n( K+ N, C  h9 Z8 R% ]7 ^
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
' a/ }' t1 J, I9 v' ~9 \7 g3 @* ?7 f! t
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 % n, u9 w3 p. u- E% U$ H
; C% n( Y$ S2 R: ^
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
1 l2 s8 O9 ~  e这是AGV_putin中arrive的method。  S$ l5 e7 h/ i! x) B5 E
, x+ R5 J6 [: V2 Y1 b/ R
当到达物料速度越高时,这个报警更多,

1 P/ {$ |$ }9 _7 l* f, p另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-7 08:06 , Processed in 0.021555 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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