设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7480|回复: 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 e0 m( F9 o7 C" C8 E) ?0 J- `*/
. ?- L% ?' E" W5 u  I5 {5 R/ fis
( s1 Y! M; R! x6 {8 y* A        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
7 r  `1 u2 d( b' O8 V* F0 p' P( pdo
9 e- V% O. L- |6 I' B4 V6 C. v) b        Lan := rootfolder.Internal.Tools.AOLlanguage;* f9 x+ K. z  S  j# [! b% R7 @
        if current = @.Destination -- else return
- ^$ E! P/ c1 }# \' [: F/ p6 m* i        then
+ @+ h! l1 D6 z                @.Destination := void;+ O5 C- k2 u' i/ @' w) w1 C
                if @.occupied then- X6 a& t% K( c1 ]& {5 }& F
                        part := @.cont;
" r( H  R: N$ f/ P9 O                        @.transpOrder := void;
/ }/ U' z( N1 n% c2 W                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
( w* b$ C& \" y4 ?. r                                @,root.eventcontroller.simTime);
. b# @$ [  f, l; C4 c                        @.HasOrder := false;3 g  Z  z, O5 c+ _8 G
                        @.DrivingHome := true;* a$ _$ O% K; S. V' g7 @& X5 k/ L
                        rgManager.tryToStartTransOrder;  w; e6 |7 l' o
                        if @.Destination = void* R& f. D" t  }5 P& E0 D* i
                        then -- no transport order for vehicle @: e2 [8 c- {' r+ g
                                @.Destination :=
& p/ j* H8 T$ d* J+ U$ ?: d- B                                rgManager.nearestFreeStation(@,track.~);
  Z/ P, e5 ^  G) J' q                                newDirection(@);   
# i% t% ^2 ^/ a                                if @.Destination /= void then2 o" q! W" h( O. t5 Y
                                        @.Destination.NumReservation :=' `- j# W; Q' x1 J: L+ D
                                        @.Destination.NumReservation + 1;! `' [+ X7 a- A
                                end;1 ]! r4 y1 I! }& X
                                @.CurrIcon := "drivingHome";, U  b0 }' D/ O3 A$ V; S% O, d7 E
                                @.DrivingHome := true;
) Z, T# `9 U" A- h" h4 c1 I                        end;) j& z, i  P9 w+ _
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station* q1 H7 d/ l4 i3 ^
                        part := @.transpOrder;/ g' I: m  Q+ a
                        part.move(@);-- load part2 t, I( u6 v1 T+ v2 J& v% d5 G
                        @.CurrIcon := "load";2 a8 S2 I/ \1 s' v& }
                        GlobalDistObj := part.globDestination;
* x! \; [2 S: b: A; a                        assignLObj := rgmanager.rgAssignL;
$ q! h6 P* L- x! F                        row := assignLObj.getRowNo(GlobalDistObj);- j! d# w+ g0 Z& k' L7 y
                        if Row = -1 then -- since 70
3 F; v' D' F- _* n0 {                                if lan=1 then8 C; g: C- X2 S8 p
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
/ d' L& K/ A2 O                                                to_str("in der Andockstation: \"",?.~.name,"\""));8 e# H" V/ U+ f& C
                                else- L8 p, c, N) K7 `' u/ ]9 ?
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),, P5 g5 a4 t1 z! |- F
                                                to_str("in docking station: \"",?.~.name,"\""));                               
  O' G1 Z; Y/ L- V, c, @4 B                                end;6 a& N! z! F. q
                        else6 k" `! z9 h9 u5 {8 B
                                @.Destination := assignLObj[1,row];
+ D2 `: J' ]! z; \' Y' ~                        end;                       
" `  n  k) U8 ?/ {: `                        newDirection(@);& ~& p# A) h: H5 c- f) m7 q  R! f* A
                        @.HasOrder := true;, |0 }# G  c+ ~+ V% p% f1 H
                end;
4 l1 o# Y4 u' a+ B( w$ N' D( r        end;
7 _9 h" d3 ?, E( I" M$ Yend;        -- of the method
$ k2 y' u1 G' m( p* I
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
: s" t4 [" C9 y0 F9 @; J9 a% F& r& {- K5 _( p
这是AGV_putin中arrive的method。% d+ i6 }  J. a2 y( D* d
( D3 N4 f/ T, p4 c
当到达物料速度越高时,这个报警更多,$ {# G  T' t* D
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
& s# S! G8 f' }8 S- [4 }程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?5 m) H6 [# m4 o

9 j$ k0 B) _2 z" _另外一个小建议,就是move,所有的move都可以这样6 `2 i# O% d) |" O1 x6 x, W
if not move() then debug end( A' i1 Z% \3 a" y' ]# ^7 G0 X3 Z
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。% V9 x3 S0 v( j# A5 M8 c3 H
plant simulation中的free libraries有AGV模板,
6 r' G$ R- y% E7 c9 o' N1 Y里面也有案例。- Y8 b; [; Y$ g" m9 w+ V
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
' r/ }9 ?# I7 l. ?8 i/ ]8 R- z- k/ `7 h6 D4 u- a6 @% s2 B' ~$ w
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 # c6 W; T0 J; Q  r
: H7 L$ `/ W/ m& z* E. P* G$ Q! V
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08   u& e% y# a! [  k6 Y+ m: V) |0 O0 z
这是AGV_putin中arrive的method。
6 p5 W: Q- }0 w' T, u- g" Q
6 A& R- N0 l6 E, [; }0 ]2 g! c当到达物料速度越高时,这个报警更多,

, l6 q6 f; R) s9 ^) F+ ]另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-13 22:54 , Processed in 0.017388 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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