设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9140|回复: 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'0 S, T% I: D+ M; Q" k: Y
*/! W$ k$ P1 w5 v+ S# j( c1 Y
is6 V" G; x6 k% d1 ^* [/ V
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;8 I9 _. A+ Y3 J% Y9 R; D6 x
do
5 C8 b: @0 O1 y" F  f        Lan := rootfolder.Internal.Tools.AOLlanguage;, M% v2 P+ l% k& D: A
        if current = @.Destination -- else return( Y" T$ T! x) f2 ^6 x- |/ L
        then
2 z% h$ C: d% V; q. S0 y: E                @.Destination := void;
3 b& f$ X: B; a7 t9 n6 K/ D                if @.occupied then
# M' J0 ~. M. {! e! R# V5 n5 V3 P                        part := @.cont;
7 y1 G0 d* w& V& Z) {  X4 Y                        @.transpOrder := void;5 F- w9 ]8 ?( h' Z& V3 R
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,3 Y; L- c! ]& {
                                @,root.eventcontroller.simTime);0 w3 k+ [( n  C* ?$ U
                        @.HasOrder := false;5 s. R. U  w, A
                        @.DrivingHome := true;
/ r: d  M. y1 `( z" p- V' x$ i                        rgManager.tryToStartTransOrder;8 b8 g- x8 F4 x
                        if @.Destination = void
  y4 v1 k3 h. }" C+ w+ D+ W                        then -- no transport order for vehicle @
! N% [/ o1 G/ l! Z, v) [  G                                @.Destination :=
, q, k6 y; ?& j                                rgManager.nearestFreeStation(@,track.~);) ?$ K" f* k- B# _& M
                                newDirection(@);   
1 N' t, q5 `9 w2 N$ z; m                                if @.Destination /= void then
( ]" I  L7 a0 j, a8 U; K                                        @.Destination.NumReservation :=
+ f, h% [- \/ p9 U                                        @.Destination.NumReservation + 1;
5 g1 i: A- M/ [1 P                                end;/ b9 t% Z5 d- l$ p1 j
                                @.CurrIcon := "drivingHome";3 e/ i. \/ D$ l4 D: m
                                @.DrivingHome := true;
( J0 X! {4 i7 I# _" E                        end;
& D' r1 f/ }/ n                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
, f' F: p  O, g                        part := @.transpOrder;5 D2 w$ d# o9 T/ \( ^( h( y& U
                        part.move(@);-- load part+ E& A* i6 ?) M* k. ~: Q3 L6 C" s
                        @.CurrIcon := "load";- y/ n$ \# J% p* J- N
                        GlobalDistObj := part.globDestination;
5 T; w9 L& ]2 @4 ^, `. H& I% y) [                        assignLObj := rgmanager.rgAssignL;( n0 W; j& A. y) ^
                        row := assignLObj.getRowNo(GlobalDistObj);
, t! U% Q, \6 w0 N  s$ d8 F                        if Row = -1 then -- since 70& r4 t- X; O" J  ]4 h
                                if lan=1 then
% ^5 K  D5 ?3 {* n: Q/ V                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),4 |' }* u: l4 K0 N
                                                to_str("in der Andockstation: \"",?.~.name,"\""));" U7 b1 g' r2 B+ I
                                else
1 `% C: G, \" @( Y6 z1 O: _                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),8 p0 U7 N1 ]' Y
                                                to_str("in docking station: \"",?.~.name,"\""));                               
( s7 A5 S; D2 i                                end;, R3 x* @( G- O% {5 a
                        else0 k- }1 f+ a6 K/ J
                                @.Destination := assignLObj[1,row];; C7 R* }; V$ R
                        end;                       
$ G% Y  V; H1 W* p6 D                        newDirection(@);
( [- a+ Q3 R8 j( q' y                        @.HasOrder := true;
# ^4 V$ N8 ~4 w! A" @# ?                end;  {6 S, E2 a% F
        end;
" V; ]3 J' M  T, P: b+ z( ]end;        -- of the method
$ N! i) u3 g+ p- ~
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
9 B4 i4 I# T  H% y. w# W. ~3 {* Z+ d7 g
这是AGV_putin中arrive的method。
, l( P: a. S8 D4 t+ r2 g/ X/ Y1 k: h) k. h0 w6 ]
当到达物料速度越高时,这个报警更多,* N0 U' _# j- j& ]
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
5 p$ m; o) z# L* T% ?) J程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?" M7 E+ W/ _8 b  j

* `) s; ~: n; F& X+ U' x另外一个小建议,就是move,所有的move都可以这样# P# H+ U; y& ]+ x( H6 Z
if not move() then debug end, k/ A7 G3 c( G1 `# R4 j/ Q! z% v
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
- O+ n' s6 W9 I' q7 S9 oplant simulation中的free libraries有AGV模板,
0 o" d4 f: n4 Q6 m7 t里面也有案例。
% t; ?3 w, J5 j3 c7 W( o我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
8 W* ?2 t* _% ^. d+ r
# j$ R/ v0 c: X, c* ^. ], S我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
: [# c+ P# Y# _& p) |: I- Z2 E8 |& h5 Q" F% V1 }# j- g
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 8 p% W* q& t' S0 |8 q; q* o$ ?
这是AGV_putin中arrive的method。
% c0 O4 p$ s& i' L) E0 ]
! ]5 u  U9 X$ y2 o, {) N当到达物料速度越高时,这个报警更多,

3 l" e6 n1 s! s3 J& l- ~4 y另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-16 04:18 , Processed in 0.017918 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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