设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9396|回复: 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'6 K7 \! |! |0 B; {! x: s% h, {
*/
) r  i% Z" q/ i( U6 Q) `$ Nis
4 ?0 O3 p9 c$ @& a  Q' r        part, GlobalDistObj, assignLObj:object;row,Lan:integer;3 e7 p$ x3 ~+ {- v: y& j- B
do
6 E9 c& C8 n7 _7 y+ ~5 Y- _        Lan := rootfolder.Internal.Tools.AOLlanguage;1 l% Z2 ?* y3 Q4 B  D
        if current = @.Destination -- else return
8 C. j8 F* i4 v: U$ M6 Z7 g6 O        then
; `0 I5 i& Y, M! M% p  t0 O  `                @.Destination := void;
* E. K5 n9 d. }. j7 [7 z( J+ Z                if @.occupied then
( [. G$ C+ P: o# p  Z                        part := @.cont;8 c$ r5 d! o% l. f) h  i, r4 q3 }
                        @.transpOrder := void;* D% E/ K7 k3 o1 N
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,! Z$ s# H5 h# ?- z
                                @,root.eventcontroller.simTime);
& K$ p; n# U" s$ H) z                        @.HasOrder := false;' U# k- M. \6 E
                        @.DrivingHome := true;
1 S5 u; F; \! n7 n. W1 y; R& y                        rgManager.tryToStartTransOrder;5 f) J4 W' `6 z. g: k: b) l
                        if @.Destination = void
) h5 @8 R" Z1 a                        then -- no transport order for vehicle @. w: A/ y, {# m, _. q  ?2 |
                                @.Destination :=
) x* R* D' P! L: m5 z6 g8 W                                rgManager.nearestFreeStation(@,track.~);+ s5 `8 E# k3 r" Y  a* ?: I
                                newDirection(@);   8 S6 v$ _4 E% A8 {4 k/ Y
                                if @.Destination /= void then* A5 W7 N! [% v% [; w
                                        @.Destination.NumReservation :=
& d- R+ ~1 U' u9 V                                        @.Destination.NumReservation + 1;
  n# E$ O' P% C- K0 l                                end;* n5 ?4 G" [$ b0 W+ J
                                @.CurrIcon := "drivingHome";+ l6 W: m, |, b
                                @.DrivingHome := true;" e4 p% Q6 u! [$ ]! W3 Z; b
                        end;$ W" m3 z% Q/ X/ c' a# c
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station1 B7 A/ n% u; {$ Q
                        part := @.transpOrder;
, `+ b8 \2 L' T( t* h                        part.move(@);-- load part8 \  W* X) v( T: O6 K' R. _2 v% X' ]
                        @.CurrIcon := "load";
5 W, x7 J/ M9 g4 l* |                        GlobalDistObj := part.globDestination;/ n( w! |" L% v, p- `
                        assignLObj := rgmanager.rgAssignL;4 p; {* ?8 A2 J; Y7 B* N
                        row := assignLObj.getRowNo(GlobalDistObj);
8 T4 K2 D% I8 f, `* q  L                        if Row = -1 then -- since 70
. `8 z, A6 t& E; x1 z6 J7 |) Y8 D                                if lan=1 then
# A& O+ g: C+ z) b9 s+ o  f                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
1 Q3 T+ m' ^* G- q& {7 l                                                to_str("in der Andockstation: \"",?.~.name,"\""));/ ?2 Q8 Y; _1 }0 t9 T! q
                                else
, S. U. e) m5 L9 Y                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),5 ?/ }' e0 j2 \
                                                to_str("in docking station: \"",?.~.name,"\""));                               
4 G7 G% T+ Y. X0 L0 q5 g! Q                                end;
" t& c. Z4 X; V; }0 ~% y                        else
( {- B8 V. R- S" _8 B* ?                                @.Destination := assignLObj[1,row];
9 T/ ^# d7 K) S0 C                        end;                        ' r/ q/ q& M9 j! A0 ~, L1 G
                        newDirection(@);
/ M, E. x0 F7 f                        @.HasOrder := true;. h& t+ A+ e8 u+ U* \# D! {# Z& P
                end;* b6 t* R$ a+ j
        end;
: @3 {8 _3 k; p* O! ~& bend;        -- of the method
7 e' [; |& a0 e
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ! I  @' k/ h9 J1 `7 u: M& e6 |

" _# f. o8 e- z3 u5 Z( a这是AGV_putin中arrive的method。. Z  y1 O5 l8 j3 ^3 e: C  l
6 h" [& c( O# t( J* D. `+ j% q
当到达物料速度越高时,这个报警更多,, E  `( u' x" k+ C" F0 M% l
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
& e9 V( h1 i$ H6 q/ S, a5 n程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?3 s) _9 Z2 ~4 b
! R. O3 H' Z4 d! {$ A0 I$ S' u, k
另外一个小建议,就是move,所有的move都可以这样
  Z/ ]9 [. v8 U- |if not move() then debug end5 X, d$ ?7 Z, M+ E6 Q
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
, S2 W3 [: |" p& cplant simulation中的free libraries有AGV模板,1 G) N+ [! h; B$ ]& A' I2 H5 J$ w
里面也有案例。! B3 f, t% I$ v" J8 l" z' {. E
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。) A: K: ]7 @9 g( v; y" P
4 D" M2 R& {' W7 e, m
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
; J  V, z  s- u+ }  k; F7 q
% U2 B$ ]/ e1 I+ F那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 # c/ c, W( Z9 y7 y- G& D- o
这是AGV_putin中arrive的method。+ ?  P3 r4 n# H) o& Y

3 s4 B  B3 k) d+ X; E" V: g当到达物料速度越高时,这个报警更多,
/ c" K3 N4 p0 H* B  v  ]
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-30 04:05 , Processed in 0.021512 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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