设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7103|回复: 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'! d  T8 l* m# `) x1 P! Z1 K
*/4 T; G' S8 t2 `
is
( K  i8 L8 i( M        part, GlobalDistObj, assignLObj:object;row,Lan:integer;% \& V% @2 J, q4 c; `4 v
do
; j3 m% I8 e1 e% ]        Lan := rootfolder.Internal.Tools.AOLlanguage;! h  P4 J2 w( q2 ?4 u2 `2 t
        if current = @.Destination -- else return
/ l$ p# J% O  u* ~; g/ u. i/ s3 g6 L        then1 m( g& X% |3 f) o0 ~
                @.Destination := void;( v. z/ l1 g0 z* `' u1 B! A. F+ k
                if @.occupied then; W6 J& \9 P4 |9 ^, L# {4 Y( P& u
                        part := @.cont;
3 U) @) k( I/ \2 U) O# l3 h                        @.transpOrder := void;
! {: c, v7 [& ]# k: R                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
- c* }  M1 w1 a0 G# H. X7 |                                @,root.eventcontroller.simTime);
# c( Y3 g2 @2 |                        @.HasOrder := false;
3 }$ b- o% o2 h3 g/ r                        @.DrivingHome := true;
1 C  z# v( t! g% K' k0 v. ~7 [" W                        rgManager.tryToStartTransOrder;- K; Z+ u: _9 ]
                        if @.Destination = void
2 S& ?5 u( m  t                        then -- no transport order for vehicle @8 p# P2 b6 K" k# c% J3 _8 I
                                @.Destination :=
$ z* |1 T+ L0 U7 |' o% t- V( w6 K                                rgManager.nearestFreeStation(@,track.~);
* f( x4 \& _7 ^, S, l                                newDirection(@);   
( b4 x1 B% W9 a( m! C, L! X                                if @.Destination /= void then9 b4 \4 d; r( _+ |- t: m
                                        @.Destination.NumReservation :=
& ~+ x3 G% |2 B) w+ u& m                                        @.Destination.NumReservation + 1;7 u' D, v" Q) q( n/ e; d& P  F
                                end;3 _: e9 D# Q' w/ `8 v; z: j
                                @.CurrIcon := "drivingHome";0 a/ @6 e# z* J" E* C" p# e" {# u
                                @.DrivingHome := true;) f' ]( g" }/ s3 e8 ^
                        end;2 l4 l1 u7 z* p: }. P  }+ d
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
4 b% v9 Q' G1 k/ U6 @5 w3 [0 C: p                        part := @.transpOrder;+ Z. j6 T$ F# l9 {" \
                        part.move(@);-- load part& Q0 e/ b2 f- t/ H9 `4 s. w
                        @.CurrIcon := "load";
+ O% _. J7 Z- k                        GlobalDistObj := part.globDestination;
: J7 \6 l* f( H0 R# v                        assignLObj := rgmanager.rgAssignL;0 K  T# u$ Z! D6 p8 o" g+ e% C
                        row := assignLObj.getRowNo(GlobalDistObj);8 ?4 x0 G# M' s7 {. _
                        if Row = -1 then -- since 705 G4 ~4 p+ I( z7 [/ A8 O* Y5 b
                                if lan=1 then* r# e5 n% s  o. a( l) ]
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
& B8 Q- S8 T1 }3 K6 `2 c                                                to_str("in der Andockstation: \"",?.~.name,"\""));2 x0 M* F' h, O4 `5 q6 |
                                else
2 \3 F3 \" o$ G5 d2 H% j2 `0 c" A                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
- m/ e. J5 P( N6 x8 |  O( F) m                                                to_str("in docking station: \"",?.~.name,"\""));                               
8 u& z# t/ {5 b, U5 H7 x                                end;! I, N) e( N# x, y8 `# W" Q* ]2 |
                        else
& L/ h' a: }( W) a7 C9 {' P                                @.Destination := assignLObj[1,row];4 r) p- V. g4 O$ R# c
                        end;                       
. X6 D1 v7 {/ ]" A# D                        newDirection(@);1 i5 E+ K# \* q( L% K: l
                        @.HasOrder := true;
) ^9 x# u9 e9 N8 [                end;
5 \! ^# g0 v8 W( e        end;
/ R) L/ q: ?0 j" E' ~, q! Hend;        -- of the method
6 Y4 h6 z. Q( E2 K) y
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 . g' E7 ^4 n) E) i: J
" W3 R. o/ T+ O5 u3 g% z
这是AGV_putin中arrive的method。
4 c" b% f/ H' [$ C' C& P9 R! j
7 M. \1 p/ n; w6 Q. T当到达物料速度越高时,这个报警更多,
: d5 ?' J+ C' T' o7 a, b, r可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。; _4 q5 e, n3 Z! g4 |7 U3 B0 S
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?7 A) v: H3 U4 L& |% A. Q5 [0 H
4 R8 f5 h) @* J
另外一个小建议,就是move,所有的move都可以这样
# C5 _; ?! [! o: ]if not move() then debug end
3 k% V9 R4 C1 N* T8 B这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
, `0 e+ M% Z$ ^+ \7 T0 M  Q: uplant simulation中的free libraries有AGV模板,+ n3 D  m. t; o7 q! J
里面也有案例。
$ h! m: w$ l" z! I我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
' N4 p. `) I5 H' `3 ^5 \$ a0 W" N" T4 h" _" |7 r
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 " r* B. |% J  @) r
# |0 X$ _& t) s/ ^" u) ?. @
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 $ R4 ?6 w2 @7 j: L% E* A' K: k1 ~! _
这是AGV_putin中arrive的method。
5 z  w* |# D' S: q) l3 a% y0 d9 B+ T# X/ p- W
当到达物料速度越高时,这个报警更多,

0 C9 T7 d9 j8 f' A/ D; d另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-18 06:30 , Processed in 0.017580 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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