设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5437|回复: 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'$ v( V1 P0 e+ g* V# [5 ?( R8 S
*/
- d2 Q, y+ u+ k( C7 His
2 ]5 C. n" X( V8 g        part, GlobalDistObj, assignLObj:object;row,Lan:integer;$ K9 O  k: J' P3 c- W% e: z
do
. ]5 l/ H6 j4 j6 x6 o        Lan := rootfolder.Internal.Tools.AOLlanguage;. N" o% v9 F8 U. }+ Z
        if current = @.Destination -- else return
4 n2 R9 M. `- h7 v$ j; Z, p        then
) l# x. l9 a0 q* w                @.Destination := void;5 N4 O. `" i' x/ n' ^; g
                if @.occupied then
0 [( x$ m& F( ]1 ~  ?4 g8 \6 h                        part := @.cont;$ g, \) J3 _( _7 j$ d
                        @.transpOrder := void;
4 h- q: {8 K7 s6 _# V- s                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
/ }6 R/ M3 r; a: V( u' [+ G1 ?                                @,root.eventcontroller.simTime);7 T0 P$ b( U* q; ~0 ~
                        @.HasOrder := false;
4 ^6 h  o; y. V! C% j6 P/ O                        @.DrivingHome := true;/ I) i9 @% ]* A9 t: F" Y
                        rgManager.tryToStartTransOrder;
4 Q/ K' L- l- |& Z, i- c% J                        if @.Destination = void, ]# c% O1 L6 l& _; q
                        then -- no transport order for vehicle @" [/ R, A1 F4 [
                                @.Destination :=
* l9 }  `' q1 j% V                                rgManager.nearestFreeStation(@,track.~);
: {6 F$ B& o+ \' w. }+ O) U6 p8 }4 l7 l7 b                                newDirection(@);   * r( C- v* J1 J( u
                                if @.Destination /= void then
1 v1 J3 m6 B& Q                                        @.Destination.NumReservation :=  r4 _/ ~! ~9 m
                                        @.Destination.NumReservation + 1;- Q5 K; s1 H/ b
                                end;
0 I. |6 G$ F$ K- [. v0 g- T8 g                                @.CurrIcon := "drivingHome";5 p! P* H# b6 U) {% ]6 T8 `, C2 g
                                @.DrivingHome := true;
& d6 T' }! Z$ n& D6 j" D                        end;" P/ F; q/ b, V8 h; c& e
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
7 T4 c# H: O+ Q- G& Z: t0 r                        part := @.transpOrder;' W+ J+ t0 @5 i* O, e/ e
                        part.move(@);-- load part$ ~) ]- z: C/ h- s
                        @.CurrIcon := "load";' _& _" x. R9 v
                        GlobalDistObj := part.globDestination;
( w3 I6 Z: |9 A; z0 s$ N                        assignLObj := rgmanager.rgAssignL;
, F3 o8 A+ Y2 N* B" g+ F! J                        row := assignLObj.getRowNo(GlobalDistObj);
- {4 G- ~$ Y9 q: \# ~! Z2 V2 ?                        if Row = -1 then -- since 70
, v+ Y0 L6 D0 {4 I) ]' r6 r                                if lan=1 then
+ ]1 H. @" V7 |5 l9 o/ q; N9 y3 {                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
5 {2 f7 c, M- o' w                                                to_str("in der Andockstation: \"",?.~.name,"\""));
5 g; M2 O4 O& ?* g  Z                                else
, d# v/ p/ D7 }! r7 J, g3 g" `9 m                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),5 a7 x8 M& |1 ?
                                                to_str("in docking station: \"",?.~.name,"\""));                               
  a5 M8 a' X: J: h( z3 T4 @                                end;, F; `7 f& U6 D
                        else1 v) Z% q$ X9 G
                                @.Destination := assignLObj[1,row];# j( W5 V) ]) n8 W3 F( `
                        end;                        / R2 q# s, K3 T3 z
                        newDirection(@);
3 g# }1 Y' R) G$ p  G; R                        @.HasOrder := true;1 |% [; @0 V+ Q: j$ R4 O
                end;
7 m. e, k" g# E        end;
, w& G  l+ ?3 ]8 a+ eend;        -- of the method/ ~7 C5 K, l/ F3 B: u) x
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
; `1 J& [! S! M
5 E- c" u8 C- K2 F# m这是AGV_putin中arrive的method。, M( c* C7 Y' S/ D; f/ t
5 p# a2 h9 Z% P0 ]
当到达物料速度越高时,这个报警更多,/ [( P" d. d- `# e/ ?
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
* k: _% F: `- y程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?9 Q, e  T6 U- y; g& e* I

) @/ V' E4 \7 g" a- W另外一个小建议,就是move,所有的move都可以这样
+ s! _' N  n. t  a% J6 G, Qif not move() then debug end9 t0 F3 u1 R; o1 B
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。+ d- b7 H5 Y# S) G# p2 s8 ^
plant simulation中的free libraries有AGV模板,( W2 t8 G; Z. {: ~
里面也有案例。0 |- _3 n/ e; f- w
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
7 w3 X- [+ o4 o7 g! Z. M% G* F+ ~  K" g" `
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
" a  m$ w% d/ v$ q0 ?
- Z4 R" q( ^- C* T4 ~那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
; \1 h: r: \  m' A这是AGV_putin中arrive的method。
9 y5 z6 D% a7 W* B$ B( n1 N" M% n) c: J# P6 @% ]: d; o
当到达物料速度越高时,这个报警更多,
0 W2 T* W, G0 p4 L; Z
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-11-24 01:45 , Processed in 0.024578 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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