设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8912|回复: 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'
! O4 ?% }& G$ b* `$ U. }*/2 ?! y8 }( n( Z0 Z8 k; k" K0 _
is+ Q. x/ e% b) J" B' ?8 b3 ]
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
& o  j% Y1 c8 Z7 U  ^" o* ]. w2 Wdo
# ^6 B# ~0 Q& b- P+ S5 L9 z$ X        Lan := rootfolder.Internal.Tools.AOLlanguage;# V) E* ^& r, `# X! X  x- o
        if current = @.Destination -- else return  W. G6 O% i7 W  E" z
        then
- d2 t& g) ?( n  B: |" N( C  e                @.Destination := void;
8 F) u: p. n$ q9 R+ V! L3 b. d                if @.occupied then
1 q+ G  `5 ~' R! ^# j' q8 ^                        part := @.cont;
- B. L: R# F3 P- \- k( }1 D9 V                        @.transpOrder := void;
5 R+ H" b) B0 g                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
9 D% D4 v' o3 v$ P7 E+ w" m. p                                @,root.eventcontroller.simTime);
3 Z# X( b" j5 y, U) i- n0 H                        @.HasOrder := false;
8 ?+ M. w" g$ ~( X$ W& X& Z                        @.DrivingHome := true;
5 K9 {2 l: G8 h+ P2 G5 d) m$ x+ A                        rgManager.tryToStartTransOrder;4 x% v% G! f9 I3 S# [; q# w* q) o6 O
                        if @.Destination = void2 u- A2 @2 F* o) W# P! E; x! j
                        then -- no transport order for vehicle @) x9 [" Z' P# a) l" j! e( c3 k
                                @.Destination :=
- d9 h1 {' M+ g& j1 L) u                                rgManager.nearestFreeStation(@,track.~);$ M5 w' S0 |! `1 ]: ^& `, ^7 u
                                newDirection(@);   8 O$ A4 \/ t: k
                                if @.Destination /= void then
0 ]  s7 ^; _2 k( n* |7 k8 E                                        @.Destination.NumReservation :=
" }! l  X+ z% J  M; y: @                                        @.Destination.NumReservation + 1;
* F8 @( q* [4 E! ]4 O1 D) t                                end;! s4 T3 W+ j/ x
                                @.CurrIcon := "drivingHome";9 @5 q, I; K" D$ G4 i2 m% B
                                @.DrivingHome := true;
0 [. x1 ]: Y" Y$ e% H                        end;5 e0 r5 ^3 i' \9 n1 x1 m
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station& T* S# P: w. B4 [0 W
                        part := @.transpOrder;
5 d: \+ Q& a9 R( M. }                        part.move(@);-- load part7 s- D2 ?7 l. N; F4 x. [
                        @.CurrIcon := "load";: W! B2 a; w" V7 z7 m2 A
                        GlobalDistObj := part.globDestination;0 a9 X7 ^- W6 X2 t1 m! w( U
                        assignLObj := rgmanager.rgAssignL;
( R: L9 Y5 ]1 g                        row := assignLObj.getRowNo(GlobalDistObj);7 F! Y0 l4 z% Q
                        if Row = -1 then -- since 70* c* G9 U1 w5 _" j( O$ z+ Z
                                if lan=1 then  B1 }; {: P$ N" `
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),! v2 z  x% G( S# d# d- L
                                                to_str("in der Andockstation: \"",?.~.name,"\""));" q$ c' a3 S4 t
                                else
+ G2 z8 z4 u! x5 \# i2 Z4 k" z                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
  O; \* Q0 ?! {) i2 v+ O( ^  \9 r                                                to_str("in docking station: \"",?.~.name,"\""));                                4 D4 H0 v0 w8 l. d0 Q
                                end;
" x8 U; O" L, ?/ D                        else! G, d" f% N9 A3 b, a5 M5 T$ a, E
                                @.Destination := assignLObj[1,row];
0 X2 P+ s0 }" P) L* j                        end;                        ; I' v& S' M5 E3 V0 _
                        newDirection(@);
) e+ M4 _* ]* f, P; f: i1 Z/ o                        @.HasOrder := true;; G% r* Q) p3 P3 @  Y5 v0 {- k
                end;( Z/ v; \: e. T% I/ v) C9 L7 K
        end;
) K; {) v5 z: ?5 Q  nend;        -- of the method7 h5 J( y2 Q! @# ~) \9 [( I9 d, t  Q
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 , }9 P' ?: p  ~  d6 B6 ^

. d, u4 M* b4 a: h# W这是AGV_putin中arrive的method。8 y0 g" l8 |) R6 n* d7 P
$ |8 X2 S8 i& @
当到达物料速度越高时,这个报警更多,
& e- {' c0 Z3 v5 M$ ]' P9 ^. v8 w可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。6 _0 h& U' M) V- A
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
7 }# `7 L7 K) Q6 u' d
  K+ b$ H. D7 ?# y' {2 n6 \另外一个小建议,就是move,所有的move都可以这样
9 h6 L; j( W1 h9 @# a' q& Sif not move() then debug end
; M+ E6 O8 a: ^. k% }- {这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。( M( D7 E" q, ?0 F% w* m
plant simulation中的free libraries有AGV模板,( N0 C* r( x1 ^* O# M3 j
里面也有案例。4 t4 \- K2 H7 |1 y
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
- |& y' f4 S! j/ Z3 x- u! r1 \  E! Y; G7 F
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
$ S% D$ P9 P' x* J! A# W, c: m% f) [0 I. ^9 Y5 F" D9 e& j
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08   P: ~, M7 g# O( U$ ^: j: g$ u
这是AGV_putin中arrive的method。3 H1 L( y( T# c
8 b% {& E2 l6 Q' `& B. N& S2 J
当到达物料速度越高时,这个报警更多,

# ~9 [2 A, U7 }) C4 ]3 P- K! ]另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-4 01:19 , Processed in 0.024105 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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