设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7801|回复: 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'
' h4 D3 }$ h" f3 W7 s2 y/ |/ |*/. d; w) j& I$ o1 x) a/ M
is
5 Y3 M3 f" N* `/ a        part, GlobalDistObj, assignLObj:object;row,Lan:integer;; Y8 B, P; [( Q5 c# O, X0 r
do: W  ]4 O: B8 d1 W6 t- J
        Lan := rootfolder.Internal.Tools.AOLlanguage;9 ^, u( T- l. B' {0 U: S2 r8 \, N
        if current = @.Destination -- else return
6 K; @% R' X  O/ p        then& N5 }* f4 u. P; l
                @.Destination := void;
& i. G! l& M3 t                if @.occupied then1 `8 `. [* T: i1 N7 f
                        part := @.cont;
. \6 `, j2 H6 I                        @.transpOrder := void;. Z8 G0 l# c* i+ [/ A, K! J
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,- e/ s' s$ e: Y# D
                                @,root.eventcontroller.simTime);
* Q* a2 ]6 ?+ A+ O: ~1 I* s                        @.HasOrder := false;
, h3 V3 \3 [4 N5 y+ o$ q6 j1 I                        @.DrivingHome := true;5 y- ^% |( _% z4 L
                        rgManager.tryToStartTransOrder;* h# O) v! v+ [/ X6 ~# d  ^0 \
                        if @.Destination = void0 l3 u9 @2 w! D
                        then -- no transport order for vehicle @
5 m; |# {8 P$ v. o* V* |                                @.Destination :=
9 V2 _, d0 i/ Q. Q+ }/ D: {                                rgManager.nearestFreeStation(@,track.~);
) @4 M* F! r- u, @! L6 f# p                                newDirection(@);   : s, K3 M' O8 @
                                if @.Destination /= void then# q; ]3 R1 W3 G* T( F
                                        @.Destination.NumReservation :=0 l/ ]/ K% _1 L8 h3 X
                                        @.Destination.NumReservation + 1;$ `$ g; L$ s# z$ E7 q
                                end;
5 P* p+ G5 b3 |8 _# i                                @.CurrIcon := "drivingHome";% }0 l: O6 K! w1 \+ I- U8 U* D& m
                                @.DrivingHome := true;1 ?3 G, R  D4 B2 F6 M5 K/ n
                        end;
9 Q: c" S3 [  S4 \9 N  a                else -- the vehicle @ is empty, both vehicle and part are in the same dock station9 Q4 S  \1 S- v) {* Y, N
                        part := @.transpOrder;# f  n# ?" h* J! K5 v# v9 |* z6 T
                        part.move(@);-- load part
* w- D; M+ E8 Y6 P( x( P  R/ w& n                        @.CurrIcon := "load";
4 b. e& v2 F$ D" }% d; R                        GlobalDistObj := part.globDestination;
" m& w6 _8 S* p. d: k- s                        assignLObj := rgmanager.rgAssignL;
' l# }5 L& X' z7 v1 n6 G* W0 ]                        row := assignLObj.getRowNo(GlobalDistObj);) U% @/ r9 z2 `0 G$ Z8 D; R* z
                        if Row = -1 then -- since 70
& t6 ?8 b, W( ~% f+ ]                                if lan=1 then1 A7 z% t( ]( a) [1 J
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
8 ]  w! L: {$ }' J! q6 f) [3 q                                                to_str("in der Andockstation: \"",?.~.name,"\""));' o& y6 {3 y: V( N6 w
                                else
  E& |) p4 L6 @% B                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
2 R% s9 n* t2 S1 c6 @4 i9 n& g4 N                                                to_str("in docking station: \"",?.~.name,"\""));                               
! u$ ~1 O  T. W                                end;
4 Z9 w6 p8 H- I2 X( ?9 y/ j/ L                        else
5 G1 U+ @$ h; j/ u3 \                                @.Destination := assignLObj[1,row];: f; r' u* y; @7 @' s8 f
                        end;                       
! \  ~% P1 S  G% @1 D4 w6 Z                        newDirection(@);
2 _- l3 y6 l0 ~& B- ?7 {                        @.HasOrder := true;3 w/ p: |8 @9 J, i& o+ S, o8 m  j$ M
                end;
& v" A% a5 P& Z( U) e( n        end;
, }0 o* |6 O3 g+ [/ lend;        -- of the method" ^. r/ A! g) f/ i
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 % s" J2 [6 m! _& e. I* {+ ]3 N

* b0 |8 `' g$ U$ T1 P$ `- m% p这是AGV_putin中arrive的method。
0 G$ p2 J, }: s! j7 ]5 I
$ K! d4 {. p5 Z- g; A% k- H当到达物料速度越高时,这个报警更多,
$ p# a2 |  d: _; l* y/ a9 j/ g6 U1 W可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。# y: J7 Q; g5 j. T
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
( i7 d$ N3 a& o# F, W  }, ?) f4 @! J6 u% r* r4 e& e7 `) f
另外一个小建议,就是move,所有的move都可以这样4 M# O' o8 \8 T6 \
if not move() then debug end" k  ^% @, q$ G9 p; l% F8 b5 `" w* y
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。% O/ y" `3 t6 c
plant simulation中的free libraries有AGV模板,
2 G2 ^' h; P$ D- P' @里面也有案例。
5 W! I; b8 H8 S( C& S. q我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。% k: |. o5 ^; N

9 _! v7 y4 }8 ^. e" X6 g我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
1 L, K0 J8 S5 ~- X8 W9 v5 l- \  t; C1 Y) ^7 M8 T. W+ k( O# {& J
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
" {8 `/ K/ f1 `6 z% _这是AGV_putin中arrive的method。, p1 i. F: _' ]; Y' H
3 _! r; P9 [+ w* ?0 `1 j; X& U
当到达物料速度越高时,这个报警更多,
1 p1 n1 ?+ A6 z  S* T- I" R
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-29 20:10 , Processed in 0.021932 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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