设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9950|回复: 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'1 p- M; q( u7 t& S5 j! `
*/) z/ u& P3 |3 \, U+ I
is# v$ J! a5 Q: {  A
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
. V" {5 {6 ~  Xdo8 A( h9 J  g$ ]3 \- B/ ^/ Z9 R6 w
        Lan := rootfolder.Internal.Tools.AOLlanguage;
3 g  M1 o8 [8 u. K! N        if current = @.Destination -- else return
5 `2 t! l% [6 _4 ?" e: v6 {        then
' n% h7 T  r* X                @.Destination := void;
3 V, w1 x. J6 L6 F, f                if @.occupied then
" E% A# u& q; a- n# w  I$ z- V                        part := @.cont;
& a. v) E6 e% L9 ~$ p) j" ]                        @.transpOrder := void;6 i. @4 Z4 }1 P: W8 }
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,4 D, J) a8 D0 a. b7 Q2 @7 p* ?
                                @,root.eventcontroller.simTime);
8 T  T; Z% O" p8 H6 j% r, {) d                        @.HasOrder := false;
3 d( O0 V( K+ O; y4 n. ^" G  h) t                        @.DrivingHome := true;7 M" z7 b7 l# Q+ b% A
                        rgManager.tryToStartTransOrder;4 ?  Q9 l) t2 o4 v1 f0 G. h( F4 D
                        if @.Destination = void
6 E& [$ u' y6 D; v/ M* h                        then -- no transport order for vehicle @
& ]' _2 O1 t7 N1 V                                @.Destination :=) E' [5 `8 D+ {( u% M
                                rgManager.nearestFreeStation(@,track.~);
# M0 ?. ?- Q8 w3 m0 w+ _( e                                newDirection(@);   ( ]  }: `1 ]' ~: _: I
                                if @.Destination /= void then2 S' @# v) U" u2 j) y0 Z
                                        @.Destination.NumReservation :=- s* k  b. N1 U; K5 k. p9 m1 x
                                        @.Destination.NumReservation + 1;  }9 ~8 @3 y, t/ U+ |, L
                                end;! B) B) F$ Z2 c$ r
                                @.CurrIcon := "drivingHome";: d. c9 |7 \. _' n3 Z" U
                                @.DrivingHome := true;
4 p. W4 o0 S, F                        end;
* a6 P5 U6 ~$ H& g3 F  a4 x' V4 w                else -- the vehicle @ is empty, both vehicle and part are in the same dock station( c& G( ]2 X9 b# T. E
                        part := @.transpOrder;
+ p5 \0 I* @& b5 _" Y  t" h                        part.move(@);-- load part- z* k  V( N9 p. H. _7 M; G
                        @.CurrIcon := "load";; \# b. F# q  u9 r5 e% R# |
                        GlobalDistObj := part.globDestination;
* U8 {8 s0 v5 t. w6 C                        assignLObj := rgmanager.rgAssignL;
$ n8 Z' x8 _4 _9 ?. r3 p* S                        row := assignLObj.getRowNo(GlobalDistObj);
2 |; G3 {+ W$ ~0 N% F  w                        if Row = -1 then -- since 70# A& R! g1 D3 \1 q
                                if lan=1 then* U% D9 L0 W& O2 @) T
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),& H( m( ^  k; g* Q: K
                                                to_str("in der Andockstation: \"",?.~.name,"\""));7 Z9 t0 N/ U3 F
                                else
; }+ o1 J+ E4 B3 t                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),) u8 L' D; t) U& ]" ~& D. |
                                                to_str("in docking station: \"",?.~.name,"\""));                                2 n- k2 c) E- t
                                end;
, F* o4 E( c+ [1 Q0 q: V6 M) L                        else
9 F! C, S- B- o) J1 c1 U                                @.Destination := assignLObj[1,row];6 n2 C) l" c3 n; \$ f8 R( S
                        end;                        & h- @: U" Z; X5 C1 M5 \" Y
                        newDirection(@);
* ^/ I. r2 \) L# o! Q                        @.HasOrder := true;5 o+ p6 m4 G" |2 S' w0 f# h
                end;
$ v: ~6 b' W& A( F# b. V+ N        end;- x3 r- ~+ H! q$ O" Z. h3 j( ]
end;        -- of the method2 ]7 W$ M) W: W
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 0 L' b$ c8 H* J( {4 Z
5 G3 q7 w7 N5 b- z. S8 y7 S  h
这是AGV_putin中arrive的method。% M$ n, l  |0 T/ j, l' H& Y

; I, ~- ^, i5 F当到达物料速度越高时,这个报警更多,/ O3 F6 N, z( o7 @5 k
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
7 ]: n0 r: @& D; H3 ]程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?! b8 r1 T7 i6 `, k. z% V- ]
9 t* `9 H& H/ Z. @3 N4 V9 }- a1 J
另外一个小建议,就是move,所有的move都可以这样$ E) \2 f/ L$ @" P$ Z, T) J( n
if not move() then debug end
/ k# U/ _+ y7 ?9 Z这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。9 W1 J$ u5 K* R
plant simulation中的free libraries有AGV模板,
, ]: H  V  ?; q/ |# B. x里面也有案例。  ~6 k% J' j- g0 m, L
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。) I" M% G5 U2 P$ G2 ?
! F  L7 t! ^. R4 c! U% G
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
/ \2 c) d* b* m5 |2 J6 I. ^# j" r" H( b+ x- ]: I
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
2 a5 j3 T) I& {1 X3 y这是AGV_putin中arrive的method。
+ n' H  L. k2 H- i3 Z+ b9 q* a- V1 A: X+ U- N0 ?, m
当到达物料速度越高时,这个报警更多,
# b3 S4 e, `* H) Q- ]" x0 y; w+ N5 ^' W
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-4 01:08 , Processed in 0.021612 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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