设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6644|回复: 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 x- x' R& p* U$ R
*/. k2 A' j* \+ B6 |5 X
is
. x5 j* F+ g( g  E! y" }        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
, q- q0 U8 f. n* B% }/ [. @do9 D# s4 O7 v7 i; w# `8 A$ ^0 Y" l  J
        Lan := rootfolder.Internal.Tools.AOLlanguage;
7 L& u* E" O" ?6 ?' f0 X5 \% s        if current = @.Destination -- else return  i* I' P. V9 i
        then6 X% k1 p. V9 \( L7 r+ Z
                @.Destination := void;
; Q$ ~9 L9 |) O) ^                if @.occupied then; P. Y; G: q- r- o" N; `: B) Y/ p
                        part := @.cont;' n# h: @5 B% c0 k* v
                        @.transpOrder := void;# ]+ {& c, B% s
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
+ G3 i9 P$ R% r2 V- W' i( l8 C                                @,root.eventcontroller.simTime);0 e) H7 \+ L7 h7 Z
                        @.HasOrder := false;
) P9 m7 |& p& F% n2 J& ^% s6 `                        @.DrivingHome := true;
4 n4 Y7 O( |+ `. P% P                        rgManager.tryToStartTransOrder;6 O: N$ ?, a" u8 P) ]
                        if @.Destination = void
* j4 ?" z. p1 ]" ]. ], D8 y; D2 ?                        then -- no transport order for vehicle @
: M: }* S$ J, }; ~# [  J                                @.Destination :=
8 H: n- A% f& c9 N9 B                                rgManager.nearestFreeStation(@,track.~);' t* |% s9 E; l' x! |, s6 ^
                                newDirection(@);   
# t' b3 w8 f4 d) x. o; E, n3 j                                if @.Destination /= void then' P& K4 `. O0 N" a; h3 \" b$ I
                                        @.Destination.NumReservation :=4 e0 T) d  j0 ?+ e8 F8 W3 _
                                        @.Destination.NumReservation + 1;
( f' Y* d' ~: o% ^' I                                end;1 ]( R5 o' A2 a/ E' [
                                @.CurrIcon := "drivingHome";
* i$ o' x8 o: N, u" U6 ?0 ^                                @.DrivingHome := true;. o9 V! P5 V% T# ~* L7 y
                        end;/ V/ j% [9 s! I* V6 e8 \
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station( _" E# y5 I0 b% B& Z3 {
                        part := @.transpOrder;
& C* f; R) r; B                        part.move(@);-- load part
8 r  d9 g" ^& \% M. l                        @.CurrIcon := "load";* Q/ x+ d/ @; q) ?. L& Z$ W
                        GlobalDistObj := part.globDestination;
9 p, F7 q' n* c* y4 J0 g                        assignLObj := rgmanager.rgAssignL;
6 L- w! x/ `. ~8 I! X, B( D                        row := assignLObj.getRowNo(GlobalDistObj);
" Q% A2 [  e& D1 V9 ]                        if Row = -1 then -- since 70
  ]6 j1 o+ N0 A/ E                                if lan=1 then
  y+ H7 V. ]9 g                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
) {8 S/ P* g8 e, U2 |% Q+ Y                                                to_str("in der Andockstation: \"",?.~.name,"\""));
2 L* y* a# o, r- v0 v                                else
1 D* }4 C- s1 [& J( O# ]+ Q                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),8 x- _. l1 b6 \* W: u* S
                                                to_str("in docking station: \"",?.~.name,"\""));                                ' [4 E9 }& d/ ^0 G: F
                                end;4 a  E8 s# L1 z* S& H- W
                        else
  d% u" Q+ `- m' A- t. g; d                                @.Destination := assignLObj[1,row];1 w3 h0 @& T9 P
                        end;                        ! l6 u% v+ N2 S. W& h% U( o
                        newDirection(@);
' D. X+ h) l8 Q# F# m2 _. f7 R1 o7 D                        @.HasOrder := true;
! P3 J+ w9 a# U8 M  C0 ?9 R9 M& I& R                end;2 g9 _5 V' [  h0 X
        end;
9 C+ o$ C+ y6 p1 ^! z3 Uend;        -- of the method
1 K) [" X2 ~4 B& u
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
( v# |9 B% \, W3 s+ i& }
9 T9 N3 e" t" E& H) T/ Q+ R这是AGV_putin中arrive的method。
+ j* f) }* A/ `" {; t# r- l% w! ]. S' }" H( `6 i
当到达物料速度越高时,这个报警更多,: J* Y( c6 _& I+ A& K
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
: f) Q- |% D9 Q* J/ f程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?+ Y* _/ N$ E2 P: t) A7 O
; z: u: V: G% @/ N# f* P+ b
另外一个小建议,就是move,所有的move都可以这样
+ T5 D) u) n  J' W8 xif not move() then debug end
- O- x; z( R; ^0 C' r: J. A7 ]6 s这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。6 ?# p- `2 z) c" b8 M
plant simulation中的free libraries有AGV模板,
% Y  _1 U- f& A$ j' j. t; a$ e里面也有案例。$ t- i0 Q- o$ ^
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
7 a/ K# x, b. c4 p) ^9 ?1 D' \1 d1 q/ K3 W. S# n
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
- j' o! D' F( k% {6 c1 R& w/ Q2 q/ ^
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ! W- Q' d4 h) I8 e
这是AGV_putin中arrive的method。
+ C6 k& k$ B) ~. L$ }( x( x
2 X0 o# C' {0 W# G+ h) M) {当到达物料速度越高时,这个报警更多,

6 K/ t! b3 G( E' q另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-18 07:42 , Processed in 0.019666 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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