设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5638|回复: 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'; x$ N0 A% S# }2 Y
*/
# Z8 Q. F7 k( E+ {: dis
5 K0 |8 g- w) S3 S1 r4 ^4 s+ ^3 [        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
, X5 i/ _5 l, a! xdo) o' Q; u1 k+ s) _5 u# n
        Lan := rootfolder.Internal.Tools.AOLlanguage;: u2 Z$ C6 W! [' x. u# F
        if current = @.Destination -- else return
, ^- h5 L8 U3 w& l  R: e9 ]7 i5 L        then% C# Z0 o$ C+ J6 z
                @.Destination := void;
5 m6 B, ]9 Q8 {$ g' W1 {                if @.occupied then
5 R* E8 r* }3 `                        part := @.cont;
' v6 S/ u% u( ]4 v$ ^# W+ S                        @.transpOrder := void;
% [9 i6 r: _8 ?% d: e  |5 e9 _                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,& ^1 l/ h& M) v
                                @,root.eventcontroller.simTime);
/ v! f* S' i  c4 y$ E" I. s                        @.HasOrder := false;5 u- w9 M/ ~% b: H' {* F0 C5 k
                        @.DrivingHome := true;
: K( g  z# k, s& n, p! I4 d                        rgManager.tryToStartTransOrder;
! U6 Z5 [) f8 Q' k/ {1 I                        if @.Destination = void
! O0 U( [: m  ^2 x0 l9 {- J                        then -- no transport order for vehicle @
" z, T+ |- z; @; O# ~3 U; ~/ c                                @.Destination :=
# _! j" _& a% Q6 V# B                                rgManager.nearestFreeStation(@,track.~);4 w& q. Z9 c. i+ M5 F
                                newDirection(@);   , [2 Y$ P# O6 q6 ~( `
                                if @.Destination /= void then
6 U# q8 X2 Z- I& t1 O                                        @.Destination.NumReservation :=# _* i# |, h( N0 c7 t
                                        @.Destination.NumReservation + 1;
1 n, t& _) H9 S* @( |                                end;
' v; s4 \# h- B/ x) I) i9 x0 o                                @.CurrIcon := "drivingHome";5 C9 E5 G( {4 d$ h; y
                                @.DrivingHome := true;- w. P: z- v5 n" h: G
                        end;
  ^, `! A7 W4 E( |/ ~& `0 `. k; v                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
" \* u" k' L; C, \2 r                        part := @.transpOrder;/ }  i$ o1 M8 k: z3 K
                        part.move(@);-- load part
1 \  [. p  o% A2 k; v                        @.CurrIcon := "load";
3 x$ C( L8 z& R+ ]* M+ t                        GlobalDistObj := part.globDestination;
0 }6 R; M- `3 E- m                        assignLObj := rgmanager.rgAssignL;
4 ?$ h$ X: B0 @. ^4 {6 o- R                        row := assignLObj.getRowNo(GlobalDistObj);! b; W% w! \  M
                        if Row = -1 then -- since 704 e/ `1 Q( z& X# Q
                                if lan=1 then
: q9 d% l2 K0 n  d; v                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
" x5 e3 H; l- Z. J- p                                                to_str("in der Andockstation: \"",?.~.name,"\""));  D% ]% o  C/ }; p* f/ W% a2 \
                                else' L& J& S8 K0 ]- U
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),, D* A" ~2 Q9 _7 x9 N% r, C, ~
                                                to_str("in docking station: \"",?.~.name,"\""));                               
4 d3 }" [0 x$ m6 @* V0 e+ j& z9 |                                end;
9 @5 p6 [# E* L                        else
; M) }; H- x0 j* N- U. \9 X; Y                                @.Destination := assignLObj[1,row];
& C1 [+ G6 r* k( ~                        end;                        ( y  d9 K8 ]. D& o. V% ]
                        newDirection(@);* Z& |9 r4 i. q) q7 b2 C, V9 e
                        @.HasOrder := true;9 y! o8 I  ^/ }2 \8 K
                end;
' w$ i# q* l& t, G        end;
7 Y9 w) i9 |7 {6 Z- Jend;        -- of the method# V# Z; t, L- y# D' |; ], r
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ! B, L: j% q2 i3 J

/ ?4 B6 ], }3 _  {, o! ~5 [! O这是AGV_putin中arrive的method。
+ u* \% ]0 j' P* H6 F' o5 G& X: w. B" V" X. K/ T
当到达物料速度越高时,这个报警更多,
! c2 W  |2 d6 m可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
* d" _8 [% \: L. ?: I% K程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?8 k3 B% F6 l0 e

+ M" ?  Q& `/ r# p另外一个小建议,就是move,所有的move都可以这样
( z, u6 b/ g" `: [) E8 Tif not move() then debug end( t* H+ g  Q! p! E1 v: G8 O
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。' v  J# [* X" n! J+ a
plant simulation中的free libraries有AGV模板,$ c+ E% k8 v7 [* a
里面也有案例。
& G3 t/ b  x8 G! u1 }我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
" R! y- r; t. l. X3 N$ |( g
$ H7 K% y0 ^$ ]1 t! Y我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
% o4 I" e, ~) I( H! u' t: T* K4 }8 }% ~; M
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
$ I& i. l4 Z. V" \+ B2 r7 U3 c$ `这是AGV_putin中arrive的method。' _% f9 ?5 K/ W2 T
# B; A/ W( J$ j; b9 X5 c$ o
当到达物料速度越高时,这个报警更多,
  D  E- p. `, Y# m) b. l+ m, c
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-12-10 19:14 , Processed in 0.040226 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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