设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8660|回复: 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'
! w. K3 R4 a# N3 b& m% @*/. b0 v; u% G! r: O/ O7 B
is4 h- k0 y  d8 b
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
2 ^, c) K! [  edo+ O* t  l; e+ ~5 }) u1 g% j3 x
        Lan := rootfolder.Internal.Tools.AOLlanguage;
8 f7 m; N% t9 g) e  E        if current = @.Destination -- else return
  O  X# G$ g* @, s: Y/ Q$ V7 R$ e        then0 S" \) n& b& u2 i' E; ?
                @.Destination := void;
$ d2 R0 O" i& O5 F                if @.occupied then8 I2 s. I3 u: H/ x/ W8 l$ @% J
                        part := @.cont;
+ A* n" a5 F, d2 }) F& e/ C, r                        @.transpOrder := void;
. i0 ~- l1 X' W7 n9 V                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,7 h- t, Q/ g6 c8 n& ^
                                @,root.eventcontroller.simTime);, e6 @5 L6 T& }) O) w1 m
                        @.HasOrder := false;1 J3 J% j- a. c. x( s2 e' E- ]
                        @.DrivingHome := true;
$ p" C/ O1 |' }4 \7 g) E! G                        rgManager.tryToStartTransOrder;; F* I5 ]: |1 _4 X2 I
                        if @.Destination = void
3 E6 `7 D) X$ e6 r                        then -- no transport order for vehicle @0 T* R5 |* T9 J0 g) f; Z9 |* g
                                @.Destination :=
* O* H/ R5 Q) s; g! B                                rgManager.nearestFreeStation(@,track.~);
  K9 }8 |3 t! y: h+ w, y                                newDirection(@);   " q2 r  M& |) c% t3 l
                                if @.Destination /= void then
3 P$ E  j5 @7 `                                        @.Destination.NumReservation :=
: Z* r3 v7 t2 S2 S                                        @.Destination.NumReservation + 1;3 j, @' C3 \  s5 r7 G0 ]( ]
                                end;! ?0 Z2 R( M3 B+ S% o/ [
                                @.CurrIcon := "drivingHome";" p, ]9 d3 l) A
                                @.DrivingHome := true;
& U% R+ M! T& h, j" d6 K                        end;6 ?7 g8 F: E6 T1 S4 L
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
: |" {. e8 t# c3 A' `% M8 x" B$ }                        part := @.transpOrder;
! \# i" e: |. q4 e                        part.move(@);-- load part
9 ]- j: P" X  A* O1 B                        @.CurrIcon := "load";
0 r9 [6 M' }4 c, K6 [5 [* k. P                        GlobalDistObj := part.globDestination;; z2 A3 y7 N1 L7 ^0 |' v
                        assignLObj := rgmanager.rgAssignL;
; X9 i% g, M) u/ Y8 [2 k                        row := assignLObj.getRowNo(GlobalDistObj);
% g: Z# o: R% S8 G, \% J                        if Row = -1 then -- since 70
0 n! B9 n9 |( [$ {3 l                                if lan=1 then0 I- K4 O; y" f+ ~) \5 B4 E
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
$ K$ o3 M, \" b/ Z( d                                                to_str("in der Andockstation: \"",?.~.name,"\""));
1 t# I' n' Q( l9 z                                else
+ G% y- \3 O  b- t+ K( |2 M7 k' s                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),& O; k4 j: d  m8 q
                                                to_str("in docking station: \"",?.~.name,"\""));                               
+ o* j- N+ z1 K0 b6 L$ g, `                                end;4 h* y6 s; s. }: l7 G) \
                        else
1 V! I& t0 F8 @" g! x                                @.Destination := assignLObj[1,row];  o# B5 ~' V* t4 n
                        end;                       
5 f2 F( Z! I8 Y- w# K. Y                        newDirection(@);  T0 l, }- l; ^& }, z
                        @.HasOrder := true;
6 `! g) M$ J  l/ n( G                end;
4 j) z# O2 k7 L( w" }* f        end;. p) D4 X+ Y2 b
end;        -- of the method
* A% k+ F. Q' D! k6 N. J
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 0 m+ x" A4 d6 v# a
+ W4 O0 [8 U! |) p, }8 V) @8 i
这是AGV_putin中arrive的method。
0 I( A& p- R3 u& r7 m7 L
6 Y! K, W2 @3 P$ i# U% G当到达物料速度越高时,这个报警更多,& \# u9 K& ~# O" d
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。4 m8 o: q$ D9 H+ `& ~
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?  t& \* X. V6 N5 [3 W% ?$ R

1 ~4 V  l  \4 p" q/ ?, i另外一个小建议,就是move,所有的move都可以这样
0 r+ y" t' L/ ]" Hif not move() then debug end
1 y+ w8 Q: g5 g& j这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。* o- u+ g8 A- q8 g
plant simulation中的free libraries有AGV模板,
8 t+ c& x% R4 E, D" Y里面也有案例。
7 p$ J" A% b' v/ H. L/ v我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
" P( z. _! W/ l; k: S3 u  {
, p- Z+ q: p3 l; t/ T! b我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ; T+ r2 [4 M: y

, L0 h. G2 A" S0 ~' }# ?  C' b+ y那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ( C9 m) L. G  y
这是AGV_putin中arrive的method。
1 f0 Y( N9 U7 A4 h; O6 D# W& }- X& v
当到达物料速度越高时,这个报警更多,

" \: N+ Q, X% }1 N, E8 v0 U) d& f另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-18 16:04 , Processed in 0.017549 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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