设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7417|回复: 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'4 u8 t* J4 ^) E' w8 U7 V
*/
+ x. c- u. M- S9 H+ X4 cis; l3 Z; e4 z8 X9 T' U9 F
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;, P7 S% ]8 L) p9 a) W" j7 ]
do# `( y7 u5 d% ~5 f" v; J5 i: D6 p" |% z: @
        Lan := rootfolder.Internal.Tools.AOLlanguage;# z* k' Z/ o. @8 C4 \- V
        if current = @.Destination -- else return# Q$ e0 `/ l  d2 a" g; i
        then8 ^4 [+ G5 d: o/ k, s+ j
                @.Destination := void;
" b4 @6 o& t* s. o) E( j                if @.occupied then2 E( e4 N  w/ Z5 Y5 C5 x9 D
                        part := @.cont;$ @5 y9 C( j2 o* ?. m9 A" q* x. R
                        @.transpOrder := void;% F" K/ H1 Y* F, [1 c0 n4 ?
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,; J2 K6 V/ D) M/ [6 q9 @3 ^
                                @,root.eventcontroller.simTime);/ ]7 ]% r1 n8 E& c( Z1 X% G
                        @.HasOrder := false;
% g6 m: l) d7 W$ Q  g/ b                        @.DrivingHome := true;
; a1 [1 l' `6 D9 t9 I- P                        rgManager.tryToStartTransOrder;; g  v8 D6 l$ O* V. f; {+ y! K9 c
                        if @.Destination = void
% K* ~, |" }+ E; f" |/ E- a8 C                        then -- no transport order for vehicle @2 Y$ U$ ~, s/ `$ h% b: J) r/ n
                                @.Destination :=4 C& Q& }& L4 F' d& s* a, Q3 `
                                rgManager.nearestFreeStation(@,track.~);
, D/ p) n2 d" h% \                                newDirection(@);     _: P: ~( l" c
                                if @.Destination /= void then
* X8 P) o- o% D0 a                                        @.Destination.NumReservation :=
0 [, `3 U# t" b8 b* D                                        @.Destination.NumReservation + 1;
5 X0 y8 c% y% D/ ?# T                                end;2 q5 X' }1 f% m6 S: k: w$ P0 h3 [
                                @.CurrIcon := "drivingHome";: s7 J* B& g# _) p" O/ ~" S
                                @.DrivingHome := true;- R* O! O" N' `& R
                        end;! t& c. X! C9 l! E: n/ f1 G
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
) a7 W# B' P2 f" p2 k. W2 X                        part := @.transpOrder;5 |8 J- Q9 p; u2 b
                        part.move(@);-- load part
+ Y% y7 u* K5 W0 ?                        @.CurrIcon := "load";+ C, q$ _* P- t* Z. I4 j
                        GlobalDistObj := part.globDestination;; S# w) r- Q" a5 c! q
                        assignLObj := rgmanager.rgAssignL;
5 {) x; U! I; ~* e                        row := assignLObj.getRowNo(GlobalDistObj);
: \7 s- ]8 Q9 v                        if Row = -1 then -- since 70
- p9 I- l0 w) C* v; j$ r8 o& o2 C( F                                if lan=1 then! y2 b4 u# o. W+ {% }$ s& q
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
) H" x% o: C) K- y1 i+ G% Z) O$ n                                                to_str("in der Andockstation: \"",?.~.name,"\""));
" M% H9 J/ |2 @& I) |- a                                else
8 ], X6 t( T4 K: Y  t                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
) E2 T$ ?* Q' O' y# f9 {* e                                                to_str("in docking station: \"",?.~.name,"\""));                               
$ u; C' Y: E# c1 ]' Q% L                                end;4 }3 X! x8 W/ ~! v! [; O! V
                        else
" G& j5 b; c* [# V* F" f2 s8 Y8 ^                                @.Destination := assignLObj[1,row];
3 s4 h& p) Z) G2 h                        end;                       
  m) s! G$ ~# Y- B( c: h                        newDirection(@);
/ ?1 W$ ^" x; \# o                        @.HasOrder := true;: J2 Q9 j3 y. \: P& b# p
                end;' v% H6 x2 P8 N$ ^
        end;
& N6 b" W  v8 c5 J& Z* P  mend;        -- of the method
7 |) r: ~2 T5 a% W8 {
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
  c6 d# |  P1 Z7 r0 T
9 ^- r8 N2 g2 m/ _$ A4 B( |  B. i% b这是AGV_putin中arrive的method。
( R; Q! @/ {5 T) P1 J: J& O* y$ E# g3 `  }
当到达物料速度越高时,这个报警更多,
# X$ q+ O, ^+ H! o2 R可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
+ E" z# m; ~5 ~程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?( G  R9 K  t% _- T4 ^, I) X* D" g

& ~9 y9 k+ y& Y6 {. r& o( F另外一个小建议,就是move,所有的move都可以这样' a6 {4 ?# }- G7 T3 N: e
if not move() then debug end9 t* c' q- C3 A
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
) f* E& `, G: h! I6 k3 B- ~* h, \plant simulation中的free libraries有AGV模板,% o- H+ b+ ], C
里面也有案例。
9 l6 e' I2 ?7 O  {3 o9 E& x& L8 W我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
1 L" u! J7 F, N, v& T
* E: `3 ]6 _: ?/ c4 I" \4 U% M我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 % m6 j/ ]2 w9 ?% _2 }
' ]% `3 B7 P2 n3 E8 m
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08   t6 K+ t  e7 M5 k: f1 J
这是AGV_putin中arrive的method。; n* c9 o) h: \0 ]2 _) z# V$ |
0 o; ^! Q1 N4 N% _5 t. G+ D
当到达物料速度越高时,这个报警更多,
. H) a& o; c% y4 v, I: P* l
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-10 09:04 , Processed in 0.022542 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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