设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7750|回复: 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'! d( ~! f4 j4 Q% _$ S
*/( Q% G: ], j6 d- m) K4 o, \- g
is7 k+ `! y" s$ q* A. e
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
+ g3 u  I5 L1 d2 E) cdo
4 r# o8 \4 E- l; g9 ~) u        Lan := rootfolder.Internal.Tools.AOLlanguage;/ _, y: I8 `3 P" t
        if current = @.Destination -- else return& k" e- T5 b4 \% q- x% @9 \: j
        then
' v" i. y( E4 ]+ b                @.Destination := void;
0 _7 z* k( c/ S# r( U( W7 {( L                if @.occupied then
$ E, j4 e, A. l                        part := @.cont;
- s! J! U, b" i0 f, i$ |, A                        @.transpOrder := void;
4 ]% n' I( P/ q& \                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
' _4 |' t: j$ h9 E$ S+ P                                @,root.eventcontroller.simTime);
/ c+ L2 g2 Q5 R* r: O& A                        @.HasOrder := false;
; y5 `* P6 n2 m$ h# s7 W5 |                        @.DrivingHome := true;  R) z1 h9 M' e7 ~5 q' w. E
                        rgManager.tryToStartTransOrder;  H6 X" A; n! ?) |3 Z8 y2 o" i2 z
                        if @.Destination = void
0 C* s9 v. _4 O1 i  O) Y6 M( H                        then -- no transport order for vehicle @
" O4 w1 O$ [) T+ _                                @.Destination :=
0 v% B9 f) U4 n! R                                rgManager.nearestFreeStation(@,track.~);
5 d5 K5 i7 \# y- l# _/ s0 b" R                                newDirection(@);   ) Z& V7 ]) f' I7 j# }: s' M1 S
                                if @.Destination /= void then
+ G, b& S7 @! Q                                        @.Destination.NumReservation :=
, G) j# x6 [6 W8 v                                        @.Destination.NumReservation + 1;8 O% L# T) `8 [' l
                                end;7 A+ y0 G5 a( F! q' E6 L
                                @.CurrIcon := "drivingHome";4 p9 k3 b* a# U; q7 _. H* f: Z) e
                                @.DrivingHome := true;
* ^* b9 n1 \& L) I7 Y( K                        end;# B$ ?4 _4 f: U- v: @: ?
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
6 t9 Z4 j$ ?7 @% a+ m) [) @                        part := @.transpOrder;2 u. m! ~* ^# x$ l' C5 Y, x6 n
                        part.move(@);-- load part' m, o1 e# U( D4 x! v' v
                        @.CurrIcon := "load";
6 \( O4 ^$ T2 u                        GlobalDistObj := part.globDestination;
6 P+ `( l2 ]7 v( s9 v& Y: R                        assignLObj := rgmanager.rgAssignL;$ v/ u/ {7 c+ S( w! [5 {8 m
                        row := assignLObj.getRowNo(GlobalDistObj);! k' {% z( Z# k) o
                        if Row = -1 then -- since 70$ ]  p* B) _. D8 q$ N2 D
                                if lan=1 then4 Q+ \+ T/ W" G, z5 v% \6 h
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
* a; U1 o3 _2 E  t2 ?! q3 ~. j  D0 @                                                to_str("in der Andockstation: \"",?.~.name,"\""));
0 h5 g- }' K$ U* j) B( M; ^+ D                                else( o# {; L: }: }, o) e/ [2 S4 X
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),; V9 W* A& R, O: v) ^
                                                to_str("in docking station: \"",?.~.name,"\""));                               
2 @& ]" }  U9 p' c. O( o$ g0 w. Q                                end;
0 e: N" W7 N' h+ J' B1 z; X                        else
' @/ |$ Q8 O; u4 U0 A                                @.Destination := assignLObj[1,row];
  n" j) a: H- p' m/ \                        end;                       
1 k. h& O, |+ {$ e+ \: H6 b2 Z                        newDirection(@);
. R8 q& R0 u4 E0 J                        @.HasOrder := true;
9 l  N( ~3 X1 A  ]" t0 p                end;
. d& j' |8 i% p. z) x        end;
0 G4 T3 @( D' x, Y+ Aend;        -- of the method
% q1 }) c0 l, q
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 9 r' g6 M9 L; Y* l) Y3 ?

; Z0 z" H4 \6 R; m. c' R& v" J这是AGV_putin中arrive的method。* \+ g$ U3 I7 ~" X, a& c$ Y
% Q. m9 j( v6 d* C1 y) _- o3 s
当到达物料速度越高时,这个报警更多,* l" w& l& [! w
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。3 V/ N6 `$ @! H0 X3 B! m
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
8 o* [: [% y- O5 H
- Y- k8 F0 b# p8 S另外一个小建议,就是move,所有的move都可以这样7 r6 Q5 ^. `, }) {  a
if not move() then debug end
. R( h/ `: T2 w; @+ N这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
. R. U. j% T1 m) c3 `plant simulation中的free libraries有AGV模板,
2 K4 X$ }9 x  s里面也有案例。
; [' h4 }) X1 J3 e8 \9 _1 p我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。4 b) Y; m! @# p3 n* s" x% v. l8 P+ X
. J6 ^/ m% q$ z  H, [8 F) K+ t
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 / K+ a( P( c. e; d' E
7 e  z5 C; {6 L( |" |) f0 L
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 % G5 ]% P. j, R: r  P# @0 K
这是AGV_putin中arrive的method。4 \- x- P) C8 O. u* u, {
6 n; N$ _$ d# `; ]. a% ~
当到达物料速度越高时,这个报警更多,

# F! T! C! s) O( g" q5 X另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-27 21:40 , Processed in 0.019871 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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