设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9302|回复: 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'
# z3 i: V! p# Y" P6 s*/0 B3 ]0 Y& {  N' G3 \) E! {
is
1 q; X9 t3 h9 J  c/ t        part, GlobalDistObj, assignLObj:object;row,Lan:integer;0 p6 \, D0 }  I9 |' R* H) `
do
; `, v+ k4 n$ J- T, c4 {9 z        Lan := rootfolder.Internal.Tools.AOLlanguage;
- J1 T/ ]7 R: ?0 C" ]% Y        if current = @.Destination -- else return# s2 h, E; R) k) z6 ]
        then
5 T5 B# A& n/ m2 h! N1 K- Y                @.Destination := void;" x* b/ r1 @; K- Y  ~) Y
                if @.occupied then
- O  ], ?, C8 |8 g: [                        part := @.cont;
+ t! ]9 Q4 _. H; q  p0 g0 Z* ^4 R" M                        @.transpOrder := void;
5 @. Z7 h" u/ G5 V% e7 _8 p                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
+ w7 Z2 y* _* I3 E* d: W9 Q                                @,root.eventcontroller.simTime);
6 w% P" F5 H9 G4 q9 C                        @.HasOrder := false;
1 }& d3 D. q) V                        @.DrivingHome := true;
* s1 [' P. L6 i+ l7 t5 V                        rgManager.tryToStartTransOrder;# X8 P* ^( I( l& @; W
                        if @.Destination = void8 ~8 {) ]$ K' H$ P, J4 e
                        then -- no transport order for vehicle @
; E% V7 O! V; E, r# w( |+ V                                @.Destination :=
5 N4 b- G8 K, x9 p8 B  ?                                rgManager.nearestFreeStation(@,track.~);
( B) R6 Z# C- e3 r( ^! s                                newDirection(@);   ! ^6 Y) e. z6 S# R' Y8 t
                                if @.Destination /= void then% e% g/ S, E$ |: {4 n
                                        @.Destination.NumReservation :=- l  X. S! o. L7 \" e5 {0 F9 S
                                        @.Destination.NumReservation + 1;
1 Y6 c& B# o, `7 j/ R                                end;
1 J# u* ^  L0 Z+ o3 ^* g+ o                                @.CurrIcon := "drivingHome";
" F' c' J8 ^5 a# G0 a- z                                @.DrivingHome := true;, r6 P- w) C& d  q! r6 U
                        end;. Q( K+ g, b% {2 s" o* }
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
/ n2 r# n1 Z9 b$ M, m9 L# \/ x/ h0 P                        part := @.transpOrder;. `& g9 J4 }6 q7 O7 D% \
                        part.move(@);-- load part
$ K- h: w& n. l5 c, q) t                        @.CurrIcon := "load";! X( g( P1 V" ~3 m8 y/ D1 e
                        GlobalDistObj := part.globDestination;  M$ d- {8 L' z: d2 U
                        assignLObj := rgmanager.rgAssignL;
' r1 a% O* k3 c" E                        row := assignLObj.getRowNo(GlobalDistObj);% x6 W0 Q& O+ `  l" U
                        if Row = -1 then -- since 70" B6 Y. }+ b3 x( A) i1 D& h
                                if lan=1 then
6 O) l' M$ t( E                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
% e7 y3 v7 y7 t1 G* V; p                                                to_str("in der Andockstation: \"",?.~.name,"\""));
# K+ v* b! N, s' b' q& o& |+ m                                else
/ I' o, c6 I) A5 T2 ^$ I- r                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
! c' U* v" E- P                                                to_str("in docking station: \"",?.~.name,"\""));                                ' M# h% K. Z3 ?+ X
                                end;
' T' P$ L' r' z* y                        else
: A' `( D. M; R% s6 W                                @.Destination := assignLObj[1,row];
5 C2 x: p- O; C$ V5 k+ C) @) T$ r                        end;                       
; k) V" K  S. l+ F+ k                        newDirection(@);: \. R) x* R3 D$ B; ~
                        @.HasOrder := true;2 R4 b" q4 _; ~) C8 m
                end;2 k' y7 v& p6 r' F4 J4 }0 F
        end;
0 B2 N4 v' Y, p, r& |6 J$ O( w: V# l' fend;        -- of the method4 O) H: e. g! ^6 W9 @1 M# o% S: e
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
) l8 N' s2 d( Q. D& J$ Z
( ^3 `' C3 y9 u$ `. W$ j这是AGV_putin中arrive的method。9 M$ s, [9 @; T4 [
/ d& b. B1 F8 @( p) ^+ M  o
当到达物料速度越高时,这个报警更多,8 y% y) J, Q1 x1 J( W
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
- x, K) _0 r2 }程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?! J, y$ R3 [6 X4 n: A$ M+ d( M

' C" i5 k* L$ u/ n. q9 y( W3 ~/ ~另外一个小建议,就是move,所有的move都可以这样  V/ w5 Q5 m0 j! V
if not move() then debug end' u0 N( u! M) p
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
% c0 U& {: v% O2 m* fplant simulation中的free libraries有AGV模板,
( J- }' V$ @' z1 W8 b) p2 G里面也有案例。
; ^' Q0 n) x. w1 N" @4 B- [7 T我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。! U( R1 n; Y% V: T: c( B
4 P( L  h5 X9 B1 m" ~
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
# l* ?* D7 d1 |! Z2 }9 m) l4 L# k6 u; r; n' @
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
: X% J$ F! r4 F这是AGV_putin中arrive的method。3 P4 S* \& X" K4 R7 O" n: @. @
+ `2 u1 b9 O3 O' t6 P
当到达物料速度越高时,这个报警更多,

+ `9 Q. O7 n0 l% U8 D另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-24 02:17 , Processed in 0.015323 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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