设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8239|回复: 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'
& H7 k' z7 j; m! d. @*/' Q* a7 `1 C; F0 B8 o5 u3 }! A' o
is2 Y2 K( d5 I; R6 O; T/ H7 t
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;3 g: r7 \0 p* {) J' R9 Q
do
0 V1 J/ s* T! ^9 Q2 ~1 F: W        Lan := rootfolder.Internal.Tools.AOLlanguage;0 x: Q3 h8 Q) z5 A" Q9 O( s; E
        if current = @.Destination -- else return$ N1 B# S* [/ ?$ u' [. |
        then
4 K, }( T1 U! E  X                @.Destination := void;
; p: _0 J% P1 {3 J- t                if @.occupied then
& o' O% l$ D1 ?9 J) p4 l7 w' G                        part := @.cont;
, D  V2 W4 ?$ y$ s4 Z                        @.transpOrder := void;/ r  M4 \& k) t, p( j4 M& o
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
0 I* q4 z  X/ E0 m5 {                                @,root.eventcontroller.simTime);
5 F7 Q9 ^5 _' e/ k                        @.HasOrder := false;
, F/ `0 d6 }6 T( E/ o5 O; d                        @.DrivingHome := true;
" H  u: V9 p! s: W                        rgManager.tryToStartTransOrder;
2 Z; b* U6 s  m  O" V$ P  G  s                        if @.Destination = void9 W4 T4 Y4 Y5 B- L* C, i  a
                        then -- no transport order for vehicle @
( I  Q; E# r" K# c( Q  d/ s                                @.Destination :=2 d7 f4 L- [! Z9 @8 ^5 Q
                                rgManager.nearestFreeStation(@,track.~);
5 U& i# i) a9 y                                newDirection(@);     E; B, h- _& j
                                if @.Destination /= void then; ^& I) t/ B5 k0 p7 o
                                        @.Destination.NumReservation :=
( G( O0 l6 `4 j+ g5 E3 K. t6 p                                        @.Destination.NumReservation + 1;. q. T) ]1 |* C' l4 w
                                end;
/ i' D9 Y$ a- p/ t# t                                @.CurrIcon := "drivingHome";
) N7 a1 B! s6 I9 H7 z  [3 R3 t                                @.DrivingHome := true;, m. \1 A* [; _3 ]
                        end;
" y2 J- V. v' L2 }: A* T  _  P) \                else -- the vehicle @ is empty, both vehicle and part are in the same dock station- a8 O3 e7 a3 a' K5 E
                        part := @.transpOrder;# V- N$ I" |. h  n. y
                        part.move(@);-- load part
$ I3 E: t( i9 X/ b8 H5 o5 W  N* R$ q                        @.CurrIcon := "load";
4 }4 d7 N2 [$ o" ]& \, p                        GlobalDistObj := part.globDestination;
: e0 w  B# K8 M: n7 J                        assignLObj := rgmanager.rgAssignL;
7 `3 f* K- e; X% y2 K; w- ?& }- p                        row := assignLObj.getRowNo(GlobalDistObj);
" ?  K+ F  A* C7 K, c. v! D                        if Row = -1 then -- since 70
/ s- O/ a+ V) I( Q8 z2 z! O                                if lan=1 then) G& F/ d+ Z9 Y4 k) \8 b: b% o  }5 m
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
* b+ X  o& v+ G4 L                                                to_str("in der Andockstation: \"",?.~.name,"\""));7 L! T' c% W( d, b9 n
                                else8 L. I- n* W/ H* Y- I; ~; {2 h; \
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
' V& U/ F& D1 ~0 R                                                to_str("in docking station: \"",?.~.name,"\""));                                1 T0 `' [8 y5 w
                                end;
4 [" }6 ?* \+ V0 Z8 T                        else
9 u# Z2 T, r: P  _8 L0 s                                @.Destination := assignLObj[1,row];
: p* H* N; `% \" ?+ I$ N2 H                        end;                       
$ T7 R. n, q9 f                        newDirection(@);
* t' ?0 ~' c; G! O1 _# P                        @.HasOrder := true;* y* y3 {9 l! {
                end;
4 q2 j; A/ e/ g: Q: v5 b        end;
* H* `0 b. I( T1 K3 [% Rend;        -- of the method* l  o9 ]- y) v/ @; y
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 2 P% P+ I( m0 ]6 n* J
" |* z2 y& U* Y
这是AGV_putin中arrive的method。" g2 V" N0 u- F8 E

7 {, D# t- n' L- Z当到达物料速度越高时,这个报警更多,
- S( j' h4 J5 A& k# r6 M* V可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。  c9 ?$ C# S) k$ {% n$ i
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?( ^; X6 ^  E5 T0 M' }
3 E8 O& U! e7 K6 D. m' L
另外一个小建议,就是move,所有的move都可以这样
# Q8 G; a( `) @+ Z2 iif not move() then debug end9 z+ H7 f- o5 W+ b+ ^/ V2 }
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
: K) [+ b0 ]1 V1 g. \' e+ pplant simulation中的free libraries有AGV模板,
7 u* r8 N' N1 u2 Y6 X( [里面也有案例。
& X/ v' |) I5 `: m9 J1 |! `我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。% {( J+ j& X: v7 k2 m8 Z! a
% Z; }9 l5 e& i6 B( z8 t. a
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
$ a5 I6 y/ N' f8 E$ b1 z! g% N8 l
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 1 m  b6 m& Y% }9 J3 n' U) p
这是AGV_putin中arrive的method。0 u8 v3 r" l0 e* h5 @4 W3 b; q% Q* \$ J; g
. J5 K# }2 h. h
当到达物料速度越高时,这个报警更多,

. h; R6 V+ `/ z另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-22 17:38 , Processed in 0.025353 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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