设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9268|回复: 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': l9 X/ ?) m. r+ N
*/, Z* d8 k6 l/ C) G+ k  |3 d) y. G  H
is& H$ c; O& s% J5 V: J; S3 v7 G
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;2 D" X6 E8 u0 N; X* i
do
1 W2 t) Z9 e3 E: w; ~9 `        Lan := rootfolder.Internal.Tools.AOLlanguage;, m. U' o' R# }8 z( N& F4 O
        if current = @.Destination -- else return) C. `# d; y1 g$ k
        then' o! ^' T$ L: l& [7 ^# v
                @.Destination := void;! }. W8 x0 p  |: V. z
                if @.occupied then2 j5 G7 y- w' D3 N. ]. M
                        part := @.cont;
  ?& ^, e2 W  C                        @.transpOrder := void;
& @- C5 M& u% a  s, E! g9 ]% v& U                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,$ e6 I9 R9 z# u* G" c
                                @,root.eventcontroller.simTime);
+ R5 T# ?! m7 L0 H, @9 l0 _                        @.HasOrder := false;
* U/ `' _2 [3 f) u% p% r, J/ N                        @.DrivingHome := true;
4 X) l+ [/ A3 P! v                        rgManager.tryToStartTransOrder;
; y3 s7 K+ T' M9 G9 L, P7 U' W: L                        if @.Destination = void
3 Q7 F" I' q% h                        then -- no transport order for vehicle @6 f2 f" \5 p) O  s% O
                                @.Destination :=
! ~/ a' j: R# J( M8 m                                rgManager.nearestFreeStation(@,track.~);$ s' a, [: h9 V0 y" }( e3 M
                                newDirection(@);   + q6 D. V/ X) L8 ~/ m8 o5 ~6 t! \1 P
                                if @.Destination /= void then: B# N3 ^5 i1 D$ a
                                        @.Destination.NumReservation :=
/ X! D  M4 o# x; d7 b& `7 s4 t* ~                                        @.Destination.NumReservation + 1;
! R; N# o- L/ R; Y                                end;
2 S8 N& \0 `$ t) T                                @.CurrIcon := "drivingHome";
8 \2 v7 [0 F4 |8 j* O4 K                                @.DrivingHome := true;6 i3 {* W' {8 l2 D9 B1 x. p
                        end;- ~/ B8 H, h8 j' ?
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station5 d. {# \. u4 Y$ S8 n% g7 M/ D
                        part := @.transpOrder;; Z! ?3 R4 g% ~( |$ E
                        part.move(@);-- load part7 ~' N0 p; S8 Q/ t0 h
                        @.CurrIcon := "load";
0 p( X. [1 A! R% Z5 V$ h                        GlobalDistObj := part.globDestination;
/ a1 {4 c7 \! r                        assignLObj := rgmanager.rgAssignL;
1 F# d! S7 Y5 [# g                        row := assignLObj.getRowNo(GlobalDistObj);- x: U  `9 ~9 s# v, q  ^* R, z( r1 a
                        if Row = -1 then -- since 702 z2 O6 E: d- U1 j+ W
                                if lan=1 then
# z8 b! v! Y4 ^                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),) r4 z5 ~& d& F  u. M) _+ s
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
0 c2 x" o! ?9 L" y! O                                else6 w* ?9 q7 d) Z7 Q7 C/ y( f
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
5 ^0 t: ?" t1 b5 V/ \) s                                                to_str("in docking station: \"",?.~.name,"\""));                                : K; K- X. l1 S/ \- ?) ^: U" J
                                end;
2 T: u1 h- E4 B6 q1 C- e                        else; R8 t  n: ^. W* x# Q6 a, @
                                @.Destination := assignLObj[1,row];
( m. J. k% j( b. ]4 y# t                        end;                        ! J- I/ f& w2 |, C3 Y7 n$ B" T
                        newDirection(@);( ]8 p& C- H6 Q  s0 l
                        @.HasOrder := true;! z% K- ?% \, o: Z1 N
                end;3 {# o' a$ l" W3 G7 u: m+ C+ N
        end;& `4 h; B8 E) E. j
end;        -- of the method
2 `9 q; [/ H% F7 H% b, k
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 8 i( K- [/ @  Q7 e( i; h

( I. G5 I' G+ N) x5 F这是AGV_putin中arrive的method。
" E# R- D% l% S6 V7 }! Q; O; v
* \6 L* D. B5 Y- s3 ~2 o6 y当到达物料速度越高时,这个报警更多,4 P9 I  n% W$ Y( R
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
5 h& @/ n, Y2 w7 X程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?4 k2 z4 L6 `6 I' z0 `) p
8 W& z) S5 C$ C2 x% a
另外一个小建议,就是move,所有的move都可以这样
3 u* _5 N0 V" M6 F2 U6 vif not move() then debug end
; E9 ?! z! {& E+ x) q  L这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。3 Z' e6 ?# X+ _3 n$ X$ ^
plant simulation中的free libraries有AGV模板,
8 W% x/ N+ q6 Y! P% G里面也有案例。
+ Q5 q5 O0 M2 C/ L. U( p' [) U4 ^! s我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
& L+ |0 |5 W) D9 b5 @. I9 D: B% c. ~
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 9 N" D( Q/ H: H

$ u, O3 _0 I' K! _- I7 k; P4 l那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
$ G" b1 r: Q% L3 l7 N7 f  q这是AGV_putin中arrive的method。
2 l2 q8 u4 ]4 k8 k2 P; U: X4 \* I* G
+ X! f7 C9 p! @  m$ |4 c/ q. Q当到达物料速度越高时,这个报警更多,
. f0 {% @* h/ y: t
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-22 04:16 , Processed in 0.016024 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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