设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7298|回复: 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'  H$ N/ Q" ^; S, E$ ?  T9 d
*/
- D5 H$ |/ C0 r1 y! j* a+ {5 ~6 Cis8 T: i" a2 @7 r' ]1 x
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
4 p0 v7 h+ k2 z* m, C$ [0 y! ndo
$ g0 z4 A. Y( G" Q7 A        Lan := rootfolder.Internal.Tools.AOLlanguage;! k  X/ X  B& e' [
        if current = @.Destination -- else return" c( s* [7 a9 I7 f
        then
, b9 w6 t+ n) I0 P2 A                @.Destination := void;
% Q1 D, E2 ?: L9 h                if @.occupied then
  [2 e0 J3 a% h                        part := @.cont;
3 v9 @# Q. H" h4 e                        @.transpOrder := void;
5 \9 |7 R1 I/ V+ j+ R% v7 W                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,; ]3 @0 I" ]/ y& D0 |) b# J+ N
                                @,root.eventcontroller.simTime);6 @/ m( u. C) U
                        @.HasOrder := false;7 Q) f- z! H! g: R% S
                        @.DrivingHome := true;- F1 c0 `, C/ r+ _2 z6 N
                        rgManager.tryToStartTransOrder;
1 O6 [3 S; W7 j; H4 A                        if @.Destination = void
7 a# V' Q0 {! B% Z8 d4 Z! f                        then -- no transport order for vehicle @) d' ^* ^' a: a+ _2 G1 h
                                @.Destination :=
; y) {; u% X$ O+ |                                rgManager.nearestFreeStation(@,track.~);6 |8 A, }) {. j; j8 Y3 ?6 t1 b- {# Y! m
                                newDirection(@);   
+ r3 ~! n/ }4 r                                if @.Destination /= void then
1 g% I) Y" r! [: V  I4 Q( j                                        @.Destination.NumReservation :=
4 t4 p; N9 p0 P* z# N9 }$ Y                                        @.Destination.NumReservation + 1;! X4 y$ B" Z6 V
                                end;
# N  M4 W- ~% k9 m3 N2 x, E1 F                                @.CurrIcon := "drivingHome";6 g4 D0 ]1 Y: E- |+ w9 Z
                                @.DrivingHome := true;
" r6 Y) {1 Y7 ^- |4 \                        end;
! f5 ~4 r4 d' k8 H' ?" d                else -- the vehicle @ is empty, both vehicle and part are in the same dock station8 v: b& U" i7 F0 b( f1 e
                        part := @.transpOrder;
% R" L" g' {( u; A                        part.move(@);-- load part
5 y0 c4 N: z( D# U1 ?# F9 t                        @.CurrIcon := "load";, t6 r7 c4 w3 N/ Z
                        GlobalDistObj := part.globDestination;
; u9 p$ w& B( [$ r                        assignLObj := rgmanager.rgAssignL;; s( [! ?1 o$ _, r* n0 F+ ^+ k# |
                        row := assignLObj.getRowNo(GlobalDistObj);0 k5 m8 b7 v! @" T; T
                        if Row = -1 then -- since 70
7 [1 Y" Y2 L* ]1 {6 Q- L                                if lan=1 then" K0 G6 L# q1 M8 u' ^
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
* t! Y! q+ l( d( c# Y% z) }2 d                                                to_str("in der Andockstation: \"",?.~.name,"\""));
+ O2 O. p2 }8 `/ K                                else" `- q" a2 S, i2 }- g
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
; o* L1 r3 Y8 t+ r2 o7 P$ P$ `                                                to_str("in docking station: \"",?.~.name,"\""));                               
$ j2 Q( t: z) _# u                                end;
& I2 _# m: ~* v* w! M                        else
: _% @$ `- O3 [3 j. @8 z4 K- H                                @.Destination := assignLObj[1,row];8 J6 ]# P- T  `
                        end;                        9 n. L* F2 N; Y$ B9 n6 u" O/ G# ]: x
                        newDirection(@);
6 `. n8 x% L3 @! ?- O) t* V( I$ k                        @.HasOrder := true;
% J0 M6 g% t+ {: f$ Q( l                end;
( h8 r% J/ P  z$ e. I, `0 A, t        end;' ]# k# N" l$ o8 k! K  q
end;        -- of the method: a/ I5 {! K$ f; {
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
# k& k5 _% Q9 p* x! i$ \; X( |) M0 D2 d) s8 \. r4 n
这是AGV_putin中arrive的method。8 P* a: D9 R! H6 q2 y

, \* W: e" ?/ `1 K7 B当到达物料速度越高时,这个报警更多,
' x) d7 @# {# o可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
% p2 E5 r' w7 {0 u- {8 u程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?2 G# ]& z1 G2 S: \( n5 e
# R% B# O4 q- s, n6 Q3 a0 ]
另外一个小建议,就是move,所有的move都可以这样
: @7 p1 d" ~3 h5 d9 D& Qif not move() then debug end
5 F8 R0 m6 `( e, D  v这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
. e' O. v( i) Aplant simulation中的free libraries有AGV模板,$ ]; C. R* ^& c* P2 C. M2 q* O
里面也有案例。) M' J7 e/ v- Z8 z0 \5 G4 Q% v
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。& ~9 v9 i- I( M4 ]) K
$ J- g. v; ~, h# F( o
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 , j$ _2 Z9 Y9 S7 H7 t! X

' ~4 i2 W. s) q( n- g9 d! X6 r那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
6 m- T+ O, X+ q( A这是AGV_putin中arrive的method。$ D- ?' b; H  {2 }) O- U: q
" \4 \2 _# }3 R3 u9 X1 W
当到达物料速度越高时,这个报警更多,
: B2 ~4 u+ }8 P
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-2 13:30 , Processed in 0.023452 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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