设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7634|回复: 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'
7 r) P; J( ]) s5 s*/# f# ?8 Y8 A% c. S1 k8 q; y
is/ l& m  A: F- k. R1 \# h
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
7 p* g) W" @7 O6 qdo" L; y& V$ J+ d* f
        Lan := rootfolder.Internal.Tools.AOLlanguage;& e# |  E% z3 K5 x: D
        if current = @.Destination -- else return
9 v5 W; i  S# [7 K6 Y, m+ ]* H& d        then5 W) k  E& v9 b( Y* x% L
                @.Destination := void;6 X  n. i7 w2 l* N
                if @.occupied then
# i3 D5 P, r3 O0 C# H- {9 Z9 I6 C                        part := @.cont;$ Y8 D' X! ^3 }6 f
                        @.transpOrder := void;% P7 P! }6 Z3 e  h" o
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
7 N$ T5 W! |* U                                @,root.eventcontroller.simTime);8 B4 S. ]; ?# Z/ q
                        @.HasOrder := false;
1 W5 S5 s- M. T- i- S                        @.DrivingHome := true;1 O5 h$ f% @; p% U; q& v
                        rgManager.tryToStartTransOrder;7 y3 b; @% u0 m* D
                        if @.Destination = void+ O6 S3 u. p" x
                        then -- no transport order for vehicle @9 }9 P% X  N! [+ K1 ]$ V
                                @.Destination :=' N" A! y& P. J) r4 Z9 R& y# o
                                rgManager.nearestFreeStation(@,track.~);
  e% _9 ]6 h- G0 }                                newDirection(@);   
4 H+ d8 e8 \* |% n$ v                                if @.Destination /= void then3 Q) O9 ^' c9 W+ E3 V7 V
                                        @.Destination.NumReservation :=1 ?) p8 B  D4 _7 j" B: l& f* I
                                        @.Destination.NumReservation + 1;1 `" m6 R) t; T# x: ?2 e) }
                                end;
: h- h( r% |& g+ k$ }: m/ q                                @.CurrIcon := "drivingHome";/ s1 Z3 ]' z  F+ _  g
                                @.DrivingHome := true;3 R5 H! Y% v) ~0 N# }  N3 l
                        end;/ k; R7 T' ?# h0 A; B% N9 W
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
8 D0 O. s; `, l7 b" m; f8 j. o                        part := @.transpOrder;& D0 I' ~5 N: b. q
                        part.move(@);-- load part
# N, G. `6 X1 Z% o) x8 W                        @.CurrIcon := "load";
: T, ]7 V; c/ e) c                        GlobalDistObj := part.globDestination;. f% y. u: b: o6 A6 H
                        assignLObj := rgmanager.rgAssignL;
& ?1 m6 L( X7 o1 @6 k! \, p! i' j                        row := assignLObj.getRowNo(GlobalDistObj);7 E9 ^/ o, j8 L
                        if Row = -1 then -- since 70
& K4 V# u( a6 u2 ^                                if lan=1 then/ ?# m) \  }- i  Q  }3 B
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
9 O8 q# e+ }, ?                                                to_str("in der Andockstation: \"",?.~.name,"\""));) Z' m8 V/ x$ I$ u/ _
                                else
$ p, r1 Z0 a/ {  k) d. s% W                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),! |. ~. D* K! a8 G. q2 R& l
                                                to_str("in docking station: \"",?.~.name,"\""));                                : H7 ?8 ]7 R) I) }' _' X
                                end;
: _1 D" ?( F4 d& c( p) a                        else. G( N* f# f* G: I
                                @.Destination := assignLObj[1,row];: c) g) a5 W! `0 u3 z1 s; a! y0 k
                        end;                       
2 V' A( H- X1 l. ?3 P4 B                        newDirection(@);. c* T2 f$ M( y! O- T0 Z% D# P
                        @.HasOrder := true;
  t: t- F2 f2 N1 R$ K                end;
( w& d) [# F, ^) c; u7 p5 B% R- A+ O' W        end;3 D9 [& G- D  `) [' t; x  W1 k
end;        -- of the method
4 }% P( U0 q6 u% U, k3 i5 n5 F! g( D
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 5 U! U7 [; j" G5 Q+ W  M9 g) g

7 P$ b8 d1 w( _这是AGV_putin中arrive的method。& R  }7 b2 b9 e3 t! Q7 U( y8 A' U

. r% Z3 c% f+ _# S, ?) `5 h6 y当到达物料速度越高时,这个报警更多,
1 W, `; f. v. P可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。& E* `2 H; v3 t7 A8 L9 X' C# z
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?- J. {! O: [. N
9 \0 p- P9 L4 }" M7 q
另外一个小建议,就是move,所有的move都可以这样
1 W  C/ s( ]0 ^/ y  Qif not move() then debug end  D- {& R  H$ v% X# k1 n$ V
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
# S! {( T) ?% ]. d7 J' n) J" Zplant simulation中的free libraries有AGV模板,
- `( [$ F# u  Z) `0 u2 Q里面也有案例。
) i3 O& G) Z: u# L我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。6 ^6 a5 M* H1 }7 u5 m( K

8 u& _4 }* u, f% ~我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 1 P* {( B" U' |+ j1 J+ m
) o0 {, T) e0 j6 Q6 t, w, b
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
3 z  V. P7 a% o, I这是AGV_putin中arrive的method。! S' S3 j% M3 k/ E# z& Z
9 ?6 u/ O0 c) F% E, n7 E
当到达物料速度越高时,这个报警更多,

# e  a9 U& o4 [6 J$ W. G1 n3 Q4 @另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-21 06:30 , Processed in 0.016784 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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