设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9082|回复: 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'; F# a& {, z! j
*/8 q' x& i  v+ m% }
is7 j# ]4 \! i( ~" Q- ~0 Z' ^
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
1 P/ m5 }! V  a) O& mdo
  ]- a9 @6 t$ Q/ J$ [$ P        Lan := rootfolder.Internal.Tools.AOLlanguage;
3 p3 B' F2 |4 \2 e7 v- X        if current = @.Destination -- else return
' K' F  S+ d( F( O8 n) B# @' ]        then. A- w# R2 @- g9 E6 T1 l( g
                @.Destination := void;9 a5 A* a0 ~9 e  s
                if @.occupied then
9 n0 n$ C( _% e% b6 i                        part := @.cont;# u1 s, l5 {2 Q9 a& b
                        @.transpOrder := void;, N) }2 y8 S) w9 U( v9 f
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,1 N6 j6 y) J2 F6 i% _% \
                                @,root.eventcontroller.simTime);9 m3 _3 u! p) ~3 D: E2 _  a1 C
                        @.HasOrder := false;- R$ b* {2 H& b! K) I
                        @.DrivingHome := true;# |# R# N- u5 _, T
                        rgManager.tryToStartTransOrder;- M4 p! Y+ R8 d6 A
                        if @.Destination = void
; U) N1 s+ u; |* u4 U6 P8 g' t                        then -- no transport order for vehicle @, V5 B& b8 D4 L. j: @/ f; s
                                @.Destination :=6 @! ]# F6 i  \* M8 s
                                rgManager.nearestFreeStation(@,track.~);
! g& Q! p) Q5 x                                newDirection(@);   
. c. v5 J9 q5 X: N. v3 \5 z5 i                                if @.Destination /= void then
: r3 ~3 h' V) I; v                                        @.Destination.NumReservation :=
  R$ n& d. N$ V. Y                                        @.Destination.NumReservation + 1;# c! K& ^0 ^6 ]7 f( q& h( N
                                end;: e2 ]% k! k" Z5 F
                                @.CurrIcon := "drivingHome";- c  x& O" r; `) F
                                @.DrivingHome := true;
! o- G6 d" k. [2 J: z+ _" V  ^3 a0 O                        end;! B' K! r& g: H% q, \
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station3 x* i& i; }3 f3 B/ I. c2 T
                        part := @.transpOrder;# K$ v1 q  `' }! K$ i% N
                        part.move(@);-- load part
# x7 w  C* n. n3 H: o+ R7 u                        @.CurrIcon := "load";- A' W& u& r" n6 U& f8 W) G( ?
                        GlobalDistObj := part.globDestination;
- u# P+ T# U( u5 T' ?/ p                        assignLObj := rgmanager.rgAssignL;
7 Y0 f1 J7 X& ]' e/ ?! F6 L; O/ Q                        row := assignLObj.getRowNo(GlobalDistObj);
$ x/ k  |- N& G- G# _- }                        if Row = -1 then -- since 70/ K4 y% f0 r) @! |8 R4 F$ d
                                if lan=1 then: [7 G! N; a6 n9 Z0 ?
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
5 g) P2 I4 t2 Z+ P/ `                                                to_str("in der Andockstation: \"",?.~.name,"\""));" ^% [9 ?. i$ y. U
                                else# R. ]9 ]. y. s
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),2 X# w0 F7 P3 K0 e/ F
                                                to_str("in docking station: \"",?.~.name,"\""));                                0 b* h- f( L" l7 {- y  _, D
                                end;
6 ^0 t9 Q4 Q" M$ P                        else. D. f: ?+ V5 ~) [, B/ O
                                @.Destination := assignLObj[1,row];
& T* b, e1 N; r2 c; h/ z                        end;                       
! W& j+ C8 }( X+ @6 _& e+ a" H                        newDirection(@);
6 l% u# W: ]$ h$ X                        @.HasOrder := true;5 X2 I' S" o) O. ~. n: {. x# D# }" F8 N
                end;9 U2 e. d: U7 P7 R; }6 Z) O
        end;
  P) p( ^& }  B' h7 O7 eend;        -- of the method
/ g3 x' \% N5 i) r( z* R
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
+ B5 n) Q: p4 w9 r2 x! |
0 _5 }: @* O5 V* R这是AGV_putin中arrive的method。& s8 Z- `" G' R7 L
! t! G# k3 I- n) d8 G7 _
当到达物料速度越高时,这个报警更多,
9 a# e0 L) P" Q+ O可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。& M; C( w1 H! a, W, z3 B5 n' F
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?/ X9 @: W' g/ `5 y: F3 ^- r+ r; d
4 R5 n+ {( v# D6 F: ]
另外一个小建议,就是move,所有的move都可以这样7 A" S- r  E1 u. b/ A- q; u2 f
if not move() then debug end; }# x" V* s8 Y& d
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
4 W( f) t4 ~3 W" _: p9 N& dplant simulation中的free libraries有AGV模板,
% o6 _# w9 R8 _3 y里面也有案例。3 ]& _+ a5 D/ p0 J# g# u
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。" O5 u) o  a& x) l- S+ D+ D) b9 W

" b3 ~7 e7 E; U& c) ]我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
' Z+ M, K  b- ^3 H- y8 u3 d5 F5 u( l
2 F. N" d5 I" Y. w那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
- o$ V5 R; d) o% l# o: O0 R这是AGV_putin中arrive的method。- U$ w" }2 K1 Z$ N0 W

: {+ X+ N) J! `: D: g当到达物料速度越高时,这个报警更多,
2 V3 B9 R! L% W
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-12 11:45 , Processed in 0.017072 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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