设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9451|回复: 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'
2 {2 s/ \. v4 j*/
  q: H+ M- U- @2 nis9 v7 Y9 T! l  a  J9 s7 c- F& {) l
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
2 U+ M0 [8 i- F9 ^+ d- W" vdo7 ^- r* a% \( [! W
        Lan := rootfolder.Internal.Tools.AOLlanguage;8 a2 ^) I% B% v9 ?1 |3 t
        if current = @.Destination -- else return8 l. F8 @- I( {, w
        then
' i" z- T: \8 g/ W$ D                @.Destination := void;
& M$ l/ V0 ~: y- F+ `, A0 N) s                if @.occupied then
0 @. m& {/ l& T1 G& n                        part := @.cont;
6 V% u" G+ t2 l- t1 O2 L/ o+ _; H                        @.transpOrder := void;9 M* t$ S* h4 v0 A
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
& R, i  \& G5 O' o$ w! |3 ~                                @,root.eventcontroller.simTime);$ f( M6 D# S( R6 r2 W
                        @.HasOrder := false;
1 W5 V& Z3 _) L  h7 R& s                        @.DrivingHome := true;
  I! R1 k: r0 u                        rgManager.tryToStartTransOrder;( U# ~/ k# f1 f) K; B3 k
                        if @.Destination = void
; i/ r( b3 j; Q) P9 E2 q+ [                        then -- no transport order for vehicle @
9 z: E% }( J8 `# R0 h; e                                @.Destination :=7 j3 g/ I' P( R% I* M& L  ?
                                rgManager.nearestFreeStation(@,track.~);. ]" {' q9 ?5 L# j- T' y. B8 E$ e
                                newDirection(@);   
' n: T% `5 _( Q+ e+ `0 ?( b4 l                                if @.Destination /= void then
# S+ f# j$ k4 i/ c4 Z" z: h7 l                                        @.Destination.NumReservation :=
) u5 s7 h( X# `- m7 Y; f( v                                        @.Destination.NumReservation + 1;1 _( j0 f3 g2 k5 S5 Z& u4 C
                                end;8 x, e' F5 U- x$ k5 |1 B
                                @.CurrIcon := "drivingHome";
1 h  Y# e4 S% q+ H+ ^* y4 W" p6 H                                @.DrivingHome := true;
3 K4 O! ^# p0 |                        end;
! S% m! L9 I& ?) e% h8 ], P. R                else -- the vehicle @ is empty, both vehicle and part are in the same dock station2 A. H" U+ {( {% j, {
                        part := @.transpOrder;
3 C& ~3 b8 o  J" F7 m4 Q                        part.move(@);-- load part
5 o& f# _2 S2 D, G; x0 Q, R: i                        @.CurrIcon := "load";2 u3 C) X/ b  f' l6 n% v' Y
                        GlobalDistObj := part.globDestination;* e: v* \5 Z0 U! E
                        assignLObj := rgmanager.rgAssignL;" C& z: H; P0 t. z% O" @9 `2 c0 N# A
                        row := assignLObj.getRowNo(GlobalDistObj);. ?# G( k( V1 L6 K7 [
                        if Row = -1 then -- since 70
& O# V  {1 w9 f8 R1 ^- Y                                if lan=1 then
! g) Z5 A' [2 ]) f: l                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
# X+ \* s, e# k; X( W5 r                                                to_str("in der Andockstation: \"",?.~.name,"\""));8 w' h1 V% b. K# s/ I) Z5 ^0 ]
                                else
1 ]) q! C8 ~2 ?8 y9 h# ]& v                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
- f+ k& p2 F9 U                                                to_str("in docking station: \"",?.~.name,"\""));                               
0 x4 e1 v8 @9 [' ^( [                                end;
1 e8 q2 C" n* _                        else0 x' K1 m, v* {* M+ ~5 r
                                @.Destination := assignLObj[1,row];: E2 p7 ^, F" `5 r' _
                        end;                        5 Y- X0 U8 s0 _' M* M& m! y
                        newDirection(@);, N, H7 `( ?; a
                        @.HasOrder := true;
7 l" D# J1 v5 V$ U; d- d                end;
. |: u& J# t( ~/ ~; ~: h4 I        end;4 @+ C3 C6 j' ^( l+ e% [' x" Y
end;        -- of the method
5 m4 m( b& H0 k& e9 r5 i# f
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
. |3 w. Z9 ]1 y; K! Z7 W/ n  f' C' ]: r! Q3 x4 _
这是AGV_putin中arrive的method。5 i( y7 I5 L. r( e( L

9 `- O. @* k. D1 ^, Z8 F: H当到达物料速度越高时,这个报警更多,; _% c# d. S: e0 J3 t! q) g
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。+ G4 D% V4 ~. A
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?% o2 Z9 O. L6 c- v2 P" A6 \. X: G, l) n

; W/ S7 H' }4 b8 Y% Z2 a: l另外一个小建议,就是move,所有的move都可以这样. I( G% N, |# c. U! c3 L9 R! ?* {- _
if not move() then debug end2 R5 o' M4 J' }- ]  e6 f* b$ Q( [
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
- x, N3 p4 y$ {! Zplant simulation中的free libraries有AGV模板,: z: z8 S- J5 i+ d6 l; U
里面也有案例。! H- ?( D1 @0 _7 V9 x: N
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。1 ~4 d  i5 c; H6 O
8 U& z3 d* I8 S! \1 l/ @3 [
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 2 v  j& [0 }  g3 G/ O0 D
" g8 W3 x2 L* [- l# Z
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
7 {2 k1 ^3 `) D+ w0 J$ b# |7 r这是AGV_putin中arrive的method。
! V& C$ }: I, @3 @7 J# k
. N! Y3 [& V+ ]5 V8 I& E& _当到达物料速度越高时,这个报警更多,

2 s- X# J6 c! Z另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-1 16:31 , Processed in 0.025838 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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