设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8409|回复: 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'. \. E3 B, w+ v1 m
*/
5 t# |8 R3 @: Lis
& E- k6 ?" G6 @- Z7 v$ z6 |8 u        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
5 l. |* i* ^8 C0 I, J2 d4 Ldo
0 x8 q; t0 Y  f% d/ ~8 U        Lan := rootfolder.Internal.Tools.AOLlanguage;8 a* o9 l$ G. _1 _  i1 W* ]! ?
        if current = @.Destination -- else return
8 ~( l0 b( d% i+ t8 O" x: W        then
/ s% M& I' ^6 N; \; ^+ R. w; k                @.Destination := void;/ E/ k( c  f% m0 R
                if @.occupied then
5 H8 O% y' W& C0 |: ^7 @) Q) _                        part := @.cont;2 @4 V: D) W7 S2 S9 T* z
                        @.transpOrder := void;
! v8 b9 g3 t0 i                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
# {( W% R1 X# t+ U9 s6 O3 i: I                                @,root.eventcontroller.simTime);: X, ^7 ^4 |8 W8 d
                        @.HasOrder := false;* U7 w7 U( @* @/ [" I
                        @.DrivingHome := true;+ B. J; Z* U9 E' I* t! h' T" A
                        rgManager.tryToStartTransOrder;3 h8 A' z- `. S5 p2 I
                        if @.Destination = void
9 Q7 P' h9 [+ P                        then -- no transport order for vehicle @
! m* R' r  p) i/ J                                @.Destination :=
0 H7 x: c' ?4 ?% U/ Z                                rgManager.nearestFreeStation(@,track.~);
/ P5 z% i( s, R& B: N3 U' P                                newDirection(@);   
- h# i1 ^( z8 N& ~1 X+ B$ B& k' i                                if @.Destination /= void then8 X7 F' L  ~) K0 w# M: x3 _
                                        @.Destination.NumReservation :=2 }, o+ I/ R5 B: c" x+ n. c
                                        @.Destination.NumReservation + 1;" t( o4 z1 F  z6 Q0 j
                                end;# K- h7 J+ A! D
                                @.CurrIcon := "drivingHome";* _" ~9 @) S+ r6 Y. b3 ]$ s! ~
                                @.DrivingHome := true;  U( j# S  j0 \; h
                        end;
* J. v( i6 M- k& |  W9 y                else -- the vehicle @ is empty, both vehicle and part are in the same dock station7 k. C4 b& i$ o) a
                        part := @.transpOrder;8 i1 ~* L& }* |  j0 t4 |( Q3 S4 M
                        part.move(@);-- load part
; d2 w3 I8 _0 h+ p5 Q/ f4 t                        @.CurrIcon := "load";+ r' D( \% [3 I& P
                        GlobalDistObj := part.globDestination;
/ v* A: v+ Z6 M5 d                        assignLObj := rgmanager.rgAssignL;
/ W. s; g2 M; \4 o% G; G                        row := assignLObj.getRowNo(GlobalDistObj);
1 n4 e8 n1 e. z5 D% Q2 f                        if Row = -1 then -- since 703 o7 h9 j1 p: d6 W) F7 @; I1 g7 i, |
                                if lan=1 then0 q1 B  M) T' V3 o
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
  G9 G2 ?* }( f; v: `3 E                                                to_str("in der Andockstation: \"",?.~.name,"\""));
3 x- E4 D! q) Z) ^                                else7 X* j! t( @5 o9 O
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
" s" W  h- X- Z. C9 G# U; k: x( C                                                to_str("in docking station: \"",?.~.name,"\""));                               
9 N! N" s$ s  I1 U' q" x6 @                                end;
$ A6 r9 h9 u. |; V8 Q! f3 G                        else
0 o' L, \0 e! C7 E* Z                                @.Destination := assignLObj[1,row];
$ v/ r& B) `) S0 n+ o; Y4 F+ @                        end;                        8 J, d" ?" E1 d( X% L3 ?8 l- J1 F
                        newDirection(@);" Y# u& e/ w" @4 B) P+ z' ]8 ]
                        @.HasOrder := true;3 s/ J$ q0 t) w7 l
                end;
$ w  u) Q0 |  h4 W        end;( |- K5 K1 G$ s
end;        -- of the method
3 I: l% F: o* t/ k: C9 B1 Q. F
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 . A2 x! u* N' z0 {( N7 y% D
" [2 @" F. U# [
这是AGV_putin中arrive的method。
1 R- m% l0 n( X% d
. p% ?3 |/ q- |# J( a当到达物料速度越高时,这个报警更多,
$ k- ]) l) G* ?可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
) n  d) Y- `+ }' E/ b" s8 g- N程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?1 Q8 h% i; e& i; {0 F( I0 D

9 X+ I& L9 m  H另外一个小建议,就是move,所有的move都可以这样
: n4 |+ ?4 [& _( ?+ @: D/ b2 iif not move() then debug end
/ @' A' _% l. z3 c$ l这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
& w# u  z8 t5 B) ?/ tplant simulation中的free libraries有AGV模板,
$ r- @! ^& I) t0 z' Z' M1 m里面也有案例。! d' q0 D" N  |3 _" ?
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
9 {; \( l( B( }1 _* D) K/ V* h5 ]$ _/ M; X3 k% m
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
1 O, T- p  U7 P, N
$ X/ K6 u" d" U$ Y$ n' G那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
7 f6 c5 w: I- ~  T+ f这是AGV_putin中arrive的method。
# S8 N3 n6 H9 o1 d9 i, x8 J" [+ r7 r1 P5 G/ ^  b, E
当到达物料速度越高时,这个报警更多,
& ~% U7 `* r1 Z) ~  N9 P
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-2 04:40 , Processed in 0.014132 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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