设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8569|回复: 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 W# L0 ^, H9 @
*/
& S2 w4 Y/ M) I  R: j5 fis! d' m' ], p6 V0 m
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;( h9 R1 A" P: D- z
do
9 g3 \. r; V9 Q! m5 `/ k        Lan := rootfolder.Internal.Tools.AOLlanguage;0 n& @& b" d$ w. a
        if current = @.Destination -- else return
3 V6 O" W3 ~  @2 Q: r% X        then
# r! o( ~! y0 M! l, w2 Q                @.Destination := void;
) K- L- ?& ]+ B7 _/ Y                if @.occupied then3 w1 i" g; B+ H2 q" O
                        part := @.cont;% B) {; N+ p; b+ \3 m/ N% t0 U- K
                        @.transpOrder := void;
4 U" P; ^9 `6 ?5 Q+ w2 I1 z                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
" L( k- R0 b. F1 i                                @,root.eventcontroller.simTime);6 S3 F! m$ p8 r
                        @.HasOrder := false;
! h0 g0 Q: A( z                        @.DrivingHome := true;
, a8 g  z# _5 i% J1 T5 P                        rgManager.tryToStartTransOrder;0 d. n6 w, h4 [6 ]# U% d, M
                        if @.Destination = void
" _  r( Y; r- |  E4 [; Y% o                        then -- no transport order for vehicle @
+ W7 {* l  M4 r9 S, Y                                @.Destination :=
/ ^) f% b, s1 n  B/ V                                rgManager.nearestFreeStation(@,track.~);
' f5 `+ \7 z/ i  ]5 G                                newDirection(@);   1 ^; W) G: W, S5 e4 N! W( q
                                if @.Destination /= void then
' A3 Z8 ~* b! ?* C                                        @.Destination.NumReservation :=
3 A) V$ k8 n( G$ w  V) \3 I: U0 X8 _                                        @.Destination.NumReservation + 1;
1 L8 Y% o8 N" T) j3 d/ r                                end;
; w. T$ G, c: q. M7 A% o* S5 K                                @.CurrIcon := "drivingHome";
4 h3 |9 b! q: r2 B1 r7 Z! d0 r                                @.DrivingHome := true;
! N7 s# f8 G. E. Q0 x5 _0 p                        end;& [* T$ B# N" \+ A" `4 s
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station. w( A- Q# P! t
                        part := @.transpOrder;
2 T2 Z3 M# S1 B! L                        part.move(@);-- load part$ \" b5 b9 h3 v4 G4 c0 A4 w
                        @.CurrIcon := "load";
4 h9 t! a8 ]2 E1 @                        GlobalDistObj := part.globDestination;2 A* J8 T- q0 ]: |9 W8 `
                        assignLObj := rgmanager.rgAssignL;0 u/ J+ a; m9 D$ X+ \; z
                        row := assignLObj.getRowNo(GlobalDistObj);
0 o* p+ m" P5 n: E                        if Row = -1 then -- since 70
; {6 P. j6 ?4 x% ]& ~) _0 P                                if lan=1 then$ ?% R& B) C% r+ p! X3 W3 W
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
# w; d0 n$ k. ~                                                to_str("in der Andockstation: \"",?.~.name,"\""));
  o& l& t& Y1 _                                else- L/ e; W  ]3 c1 v
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
2 L6 ]3 b% b4 u6 G& b# A; S                                                to_str("in docking station: \"",?.~.name,"\""));                               
- A: B3 W* d) ^* X1 x                                end;
9 u4 P2 B- G! L5 m% ^- E, k                        else! c4 X( K& T7 o
                                @.Destination := assignLObj[1,row];% K' _: s6 ?( a$ B$ T* j7 L6 G
                        end;                        9 p& g+ A9 q2 Z  ?
                        newDirection(@);
: j2 F% N0 ^8 d5 ]% e. T  y                        @.HasOrder := true;
/ k0 G( C/ z5 l5 S( i% _                end;( H, D  c3 M# p7 n2 r0 c
        end;8 t; L$ d  B: ]# G" S
end;        -- of the method
1 q1 o& X; V% h: k) n
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 & q1 Y; c& X6 T8 R+ L  J7 o: f- a
* b" c( _# g  w2 K' j  L
这是AGV_putin中arrive的method。9 _9 M# F$ h  R3 a

* H7 K/ F( z" C3 k1 z! v当到达物料速度越高时,这个报警更多,1 _2 b3 A( ]: I; z8 ^9 V2 t
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。7 b! f1 z+ i- G' [3 h, A; {
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
9 i6 T0 n' W* h# z) s: t
2 `8 l! z. C2 z: [* G. f另外一个小建议,就是move,所有的move都可以这样
& T. [. e* A3 x$ O) C1 Uif not move() then debug end$ E" `. E. \8 }# {# _9 `1 T+ E- X
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
; u! D  `8 F& b2 }8 Iplant simulation中的free libraries有AGV模板,
5 n) `; }8 P' e$ f2 q8 N里面也有案例。: |' ?1 v" s: V" t8 h1 d9 x
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。) d* Z4 z  Q1 |7 Z* X9 M8 Y$ x" p
9 T; Y+ c% S' b8 n, q: A1 p- w3 c  v
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
* A1 l. D: c! j* z
4 \; Y* X6 z5 W7 Z4 h/ a% s+ v* E2 B那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 " g! Q/ V% H5 k1 q2 ~; i
这是AGV_putin中arrive的method。( H4 {  _" f- P' H2 K
5 o  _4 G/ `5 k% R& p
当到达物料速度越高时,这个报警更多,
4 m, W* ^$ F- s: H0 T
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-12 14:23 , Processed in 0.018096 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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