设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8576|回复: 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', v3 A! Q: z' l  [8 K% ]
*/
. K, E4 K" \; ]3 uis
( t  ^! N" c' w        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
% Q3 F/ C6 H, J! ]$ pdo/ x2 K4 C! M: j, w* h, i; [1 m6 V
        Lan := rootfolder.Internal.Tools.AOLlanguage;
1 U; D- [8 m* d8 p+ a7 @        if current = @.Destination -- else return
; c* l) f+ W, R5 t8 c        then; h( }% R3 }; f" ^3 a
                @.Destination := void;9 T( ]7 |0 i! R
                if @.occupied then5 k! x; }5 k6 K' T- v' _( E  d
                        part := @.cont;8 R+ h7 k2 q9 t$ [8 f8 i
                        @.transpOrder := void;& c: j5 u  Q: o3 j9 y
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,  e$ b4 H0 F$ f5 M
                                @,root.eventcontroller.simTime);% o5 _7 A  Z1 M2 ~/ W3 d0 I
                        @.HasOrder := false;
  F, ^. G  `9 E" p" R                        @.DrivingHome := true;
1 u8 d9 A: ~9 l" m8 K% P* u) S                        rgManager.tryToStartTransOrder;; W/ G9 H  z4 O- d' s/ [
                        if @.Destination = void" V/ c" n- D% T- p* f+ b: ~( f
                        then -- no transport order for vehicle @  O( m; J$ ?- ]( o, a7 I
                                @.Destination :=
4 s6 r4 m+ S" l# s                                rgManager.nearestFreeStation(@,track.~);
5 C' G% @% t8 Z. b4 o                                newDirection(@);   ) c$ X7 L9 \5 @+ k8 t2 D0 h6 s1 t
                                if @.Destination /= void then* R  d% a0 l% D
                                        @.Destination.NumReservation :=
5 m! \. N: C3 ]( h; L8 s( Z2 n1 V9 M                                        @.Destination.NumReservation + 1;: }  l5 S" _! {8 u- o
                                end;
" h% e9 s5 h. M% |; T                                @.CurrIcon := "drivingHome";1 H. o) x/ G, ^$ J
                                @.DrivingHome := true;
; P% N8 t4 n  \8 F+ _                        end;
, L' h$ b, S5 [  T+ \0 \                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
* A; ~2 }' u5 \: |7 }                        part := @.transpOrder;
* q, ~0 S( a( N1 @) f& w8 Y                        part.move(@);-- load part* @0 r8 L. H6 f9 S+ D) s* N
                        @.CurrIcon := "load";. b9 n$ G& H) g/ o- J! H3 |
                        GlobalDistObj := part.globDestination;
; C  q' N6 u9 O* i0 _. B& v3 C                        assignLObj := rgmanager.rgAssignL;
) u1 c% q1 i- g                        row := assignLObj.getRowNo(GlobalDistObj);$ C! R* M* \7 v  _6 l
                        if Row = -1 then -- since 70
0 ~, S1 j* m# k5 F# I3 L/ h                                if lan=1 then* }# U! _) F) E! w2 V
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),% ~& m/ \6 q4 ~: l
                                                to_str("in der Andockstation: \"",?.~.name,"\""));% K) {& q8 W6 b+ e
                                else
' ?/ h- r7 J3 X0 u                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
- B# N- A+ ?7 A: {0 w. U: F+ E5 p                                                to_str("in docking station: \"",?.~.name,"\""));                                3 C+ J( p3 z) }$ r) I! k
                                end;
* }8 N) G& M) p/ H6 }1 [. V                        else, U: Z7 m% I1 r& [) n' q
                                @.Destination := assignLObj[1,row];
3 o0 u) C8 s( ~                        end;                        % H' A& P! ^9 d( _6 ?9 i0 @
                        newDirection(@);9 ?8 _- y! A0 E- D4 J( Z, B+ ~) A9 I
                        @.HasOrder := true;& }6 I7 r% X5 j# j" b8 b
                end;7 m7 |: P5 M" ^& G% k7 e% r: F
        end;
) d, d, H8 z8 mend;        -- of the method" s& M& w5 B* A
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
' k3 s; f, S* `
. c) A! C( h0 p+ _% z这是AGV_putin中arrive的method。' }9 G, |5 G: R4 l! U( S6 S
; L1 _# l$ [* R/ h# [
当到达物料速度越高时,这个报警更多,
! g' X7 {. I) b' \7 {" f6 G) {9 J可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。& W" R$ l" U3 V
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
' b) o: g; X, X, j, W$ b# j, V  l+ @
另外一个小建议,就是move,所有的move都可以这样
+ n6 q+ W& i, l* G0 I7 \. M; @if not move() then debug end
( ]! a* t2 A3 x6 P* K这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
! q6 C4 h2 e5 @9 e5 p6 c) Oplant simulation中的free libraries有AGV模板,9 B; ^  g# D/ o/ w/ R7 ?- d
里面也有案例。) \% s: R2 ?/ x' p/ G, K: L# d% D2 f
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
2 v. a  |! m/ m; Z# w7 V6 L* _) f: G: b: j1 W
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 9 n/ E6 C9 _& I9 A

0 `0 B+ A0 r6 z那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 2 ~# T8 }+ D9 A; c8 f$ P
这是AGV_putin中arrive的method。4 B; w5 I! j( s! d% z4 c

0 ~0 d* a4 g7 L% Q( ^( G9 j当到达物料速度越高时,这个报警更多,
: {/ ~; C( j2 j
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-13 02:29 , Processed in 0.018206 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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