设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9336|回复: 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 r# A, ~2 N5 A( ?$ G5 ?5 c8 m*/4 i, F- Y/ _& @  R" A3 z8 u
is
. Q! c' M* d+ w7 r& ?        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
& i+ A/ T" w* k8 ^2 _& ]: gdo
. C, m3 _7 \$ o$ |        Lan := rootfolder.Internal.Tools.AOLlanguage;
$ ~- ~* ]; V& f& g8 E        if current = @.Destination -- else return
( W" q# W+ N( ^% s3 Y        then
! ~' i( p+ y: X                @.Destination := void;
7 A: }3 B, \  _. y/ `3 h$ h+ v                if @.occupied then+ @" D2 K" o, \5 `. v# w% s& P# v
                        part := @.cont;5 c7 h) D9 R( g( l$ K, R
                        @.transpOrder := void;* f* |: P3 B! T$ b$ B
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
, j5 `$ T/ z2 X                                @,root.eventcontroller.simTime);- u' ^  m4 }$ _% ?- h4 @5 @( O- D$ }
                        @.HasOrder := false;
. y+ U7 @9 s. s                        @.DrivingHome := true;
1 [- v1 g$ d. y! R: j/ h3 o. }: b                        rgManager.tryToStartTransOrder;
( {) \1 K& B* D9 f                        if @.Destination = void
& a" v2 N; }( ?; W) o) b6 m                        then -- no transport order for vehicle @
9 u5 U* v; C( a                                @.Destination :=/ f: `5 {9 c& N, ]
                                rgManager.nearestFreeStation(@,track.~);4 C4 q( f, H6 P1 G0 {( l
                                newDirection(@);   
" z4 ~5 d" C6 K! Y4 ?5 p$ {                                if @.Destination /= void then; y; F  a  c7 K# M8 t
                                        @.Destination.NumReservation :=
) K, o: O6 T3 M& X( v0 T; K5 _                                        @.Destination.NumReservation + 1;, w) a6 E0 v* q
                                end;9 k: ]3 [6 q7 ?
                                @.CurrIcon := "drivingHome";5 _3 }* ~9 L9 x5 q' ?
                                @.DrivingHome := true;
9 J$ b* B' G" \9 i, o/ F                        end;, E) a& r8 ~/ V4 z% V4 J0 y
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station; v( z+ L, G  p2 a3 q* g
                        part := @.transpOrder;5 K) O+ [& a( J* D/ \
                        part.move(@);-- load part# s, [, A5 W( ~* X
                        @.CurrIcon := "load";
* c9 ]3 Q! Z2 \8 @# C                        GlobalDistObj := part.globDestination;- ^- B2 M+ T( |8 ^( h, i; r4 y! z
                        assignLObj := rgmanager.rgAssignL;
- a0 a& x& Y) W% U7 Z! O                        row := assignLObj.getRowNo(GlobalDistObj);
% e; A8 j+ J  E# I: X                        if Row = -1 then -- since 704 F: H2 W* @6 z+ J
                                if lan=1 then4 d+ X% d  j9 L
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),8 r8 k$ P- c" N0 s- F; G
                                                to_str("in der Andockstation: \"",?.~.name,"\""));: l; z  F9 J/ l; D
                                else9 @( [. }7 _6 ^/ ?
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
) F1 K6 o$ U) e8 O                                                to_str("in docking station: \"",?.~.name,"\""));                                ( |* D! p# y4 ]9 B' `! }. u
                                end;, T' |- Z: O2 L5 k7 E
                        else
, m1 @0 P6 f5 I2 b                                @.Destination := assignLObj[1,row];+ k% ^, ^& Z$ U8 H- K/ }, V$ k
                        end;                        4 s% x% q6 \% v
                        newDirection(@);- [0 n0 Z) E4 c4 j3 m/ H) L
                        @.HasOrder := true;, t2 e9 C' a* V9 j) T3 c' ]6 E
                end;* G+ ~, I" U5 t# ~2 L& b1 I; V  J) C
        end;
7 o0 A0 r6 h4 c' fend;        -- of the method
6 v' }2 d+ A, g9 M( d0 M
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
& G- @0 t1 e  d) H5 z2 ~* F
/ o, \# R# ^% y" U+ ]2 I) h6 T这是AGV_putin中arrive的method。
- n0 p  h  C0 a
1 }7 b! y1 z- B3 U7 ]当到达物料速度越高时,这个报警更多,
; w) M, `# Q2 G. X# A" ~- L( f, U可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。% p3 j' P' ?3 q0 }" q
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?; k4 K8 f% k0 X" N& P
: R* I  w3 ^0 g* W
另外一个小建议,就是move,所有的move都可以这样
6 Z* ^+ E1 T& @0 f# \( z( g' Qif not move() then debug end( I6 V% [/ N4 s) W$ Q
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
! t1 i! E2 p4 \6 z% Nplant simulation中的free libraries有AGV模板,
4 _% o& O/ H5 U  }  N: ]3 d里面也有案例。
. l. g5 ~6 j* D0 A我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。4 }% L  y; K* V9 @6 j0 v

: u1 B2 r9 |. l6 X  ]% T5 @+ G我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
% X% t5 J9 _# Y$ z8 G
0 l( H7 l" k! E$ t/ [那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 / d5 K2 z+ h( U# F( \
这是AGV_putin中arrive的method。
) {' |1 S$ f- Z( e
- B; L9 u6 k5 ~- d+ y9 Y当到达物料速度越高时,这个报警更多,
: m6 Q- l0 f1 S" t  \
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-26 03:33 , Processed in 0.021572 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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