设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10288|回复: 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'
( Z; Q  z0 y9 f: z! W# S*/
: H* R5 |5 Q9 \# ois
+ N) P; W9 x0 A$ T3 F1 A        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
4 d$ Q  u7 _, l" O( ^4 q5 {5 Bdo
1 k; ]2 b1 K% L' I: ~        Lan := rootfolder.Internal.Tools.AOLlanguage;/ @0 K1 q+ K  q* s& T3 q
        if current = @.Destination -- else return
( ?8 K  W/ G1 j! @  C5 l        then
' `. {4 B" w9 p; o                @.Destination := void;
! a7 t, i) A9 o* [6 i                if @.occupied then5 s( ~3 \& ]+ j3 }
                        part := @.cont;
" _# Q! V5 f% D, x' b                        @.transpOrder := void;
! @, B9 Y' _* c4 s- j                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
3 W" p) t, A3 c3 |, w                                @,root.eventcontroller.simTime);+ V; p- v4 K3 S/ L
                        @.HasOrder := false;
) `# F# h; M, J( D% T2 {* F; @                        @.DrivingHome := true;; L: h. t8 L- l) r4 ]9 H
                        rgManager.tryToStartTransOrder;
* o. g# F7 W8 S$ e2 [1 W                        if @.Destination = void
8 C2 [' G5 [  A. u4 Z/ l9 f                        then -- no transport order for vehicle @4 A2 \% r7 _( H0 O: _2 O& T
                                @.Destination :=  t2 H3 C9 p( O& s. D
                                rgManager.nearestFreeStation(@,track.~);! T, t3 T# R! I& p: f
                                newDirection(@);   
, [, d6 [; P& X& P* t                                if @.Destination /= void then
) E. H' y3 N# v! D# y9 y' n4 _                                        @.Destination.NumReservation :=# t$ {1 d% C( P" t5 j
                                        @.Destination.NumReservation + 1;0 v4 g2 X- l4 q) q  E; T
                                end;0 E; m& Z* c9 p7 W* e/ }
                                @.CurrIcon := "drivingHome";
0 F/ s5 S* a; n( t; ]% L* C& t                                @.DrivingHome := true;
4 i& ~6 N* ~+ B/ _                        end;
+ |0 e5 C' H' v' g* s  n# i                else -- the vehicle @ is empty, both vehicle and part are in the same dock station2 e) w/ d7 [8 k8 @3 G, \3 v5 H3 M8 j: v
                        part := @.transpOrder;" }$ V: V9 b0 ^0 D) X# F
                        part.move(@);-- load part
) j* S; Q. h9 q, f0 n                        @.CurrIcon := "load";
0 Y# f& [9 M8 l# C  Q: R1 Z2 i. Z                        GlobalDistObj := part.globDestination;
* [9 g' ]5 i9 P+ I                        assignLObj := rgmanager.rgAssignL;
5 ]; C+ B3 @! r0 u; B                        row := assignLObj.getRowNo(GlobalDistObj);+ ^  T2 \7 h- ?4 L+ r+ m
                        if Row = -1 then -- since 704 Q& J5 [# F# ~( {! Q
                                if lan=1 then
" k+ B8 k. \1 y6 P3 }; ~                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
0 @2 C+ p% v6 \, _1 y5 @8 E                                                to_str("in der Andockstation: \"",?.~.name,"\""));! s& |/ {2 F* `; `; n
                                else* X' z, C5 m) J# H! _& g3 R' V! e
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),* h  q8 h$ D9 k7 d' a% u- K: v
                                                to_str("in docking station: \"",?.~.name,"\""));                               
! c; Y! f- Y2 ?/ \- J                                end;1 C! B  A% m! N. {1 r2 e
                        else; S3 R8 A+ C( z  z1 T
                                @.Destination := assignLObj[1,row];
  |4 u& _1 Z, ?" S& s                        end;                        , ~' R" t/ b6 B; R& _- s( t
                        newDirection(@);' z4 o9 b5 {, f7 d# S  N4 \2 f
                        @.HasOrder := true;
0 D, N* o0 N2 h3 F                end;
9 H6 L* [2 D. \  Z+ b5 ]3 f        end;! l3 [7 w$ W9 R( n! e' \
end;        -- of the method' f& `* P+ j9 p* c
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 1 c) ~6 Z" z0 j4 ]1 G
3 R5 \' f0 J6 k' o7 [5 H1 |
这是AGV_putin中arrive的method。
* _# T0 g8 @- J2 ~- T  X% G: _0 v  g6 O+ y/ d
当到达物料速度越高时,这个报警更多," ^$ F, c. Q6 i$ ?  [" y
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。3 _4 B/ ]) n  G! D
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?0 T# t5 t/ |) k) U/ I

. v: L6 ?: U: m, M6 a% M% i9 k另外一个小建议,就是move,所有的move都可以这样
/ i( f3 O4 E. v3 Rif not move() then debug end
6 d" }' ?2 k7 c这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
- R& A5 k: I: I3 c, P$ _- g% fplant simulation中的free libraries有AGV模板,' ~  a; j, n, W4 T, V; y- z- Y; S
里面也有案例。* p" g5 c# f: b, E# D
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
6 p7 O8 N' k5 l  B& K% i
$ \: J" x5 O5 ~3 [3 {/ M我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 6 r# l: Z8 U- r$ _+ R! w
5 m0 X: C, R7 C4 \* A
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 % X% y2 I/ `# N1 n, c
这是AGV_putin中arrive的method。# R, |7 Y9 E! t- c/ @
: l6 T+ A2 N" I  z% R7 k% i
当到达物料速度越高时,这个报警更多,

! |  T1 I+ m( s0 Z' u$ I* A另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-24 18:07 , Processed in 0.018099 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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