设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8683|回复: 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'
  r0 b; q9 R2 y*/
# S1 z1 r0 f4 }* k: J( Zis
( c0 N: t* ^7 _  K* u" S- k. q# G( j        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
) `1 x: \8 B5 J9 T* odo
; ^+ z5 [4 i! q4 J6 w7 O        Lan := rootfolder.Internal.Tools.AOLlanguage;$ R- I  Y- h( B: b' ?" O2 C2 e* k1 |
        if current = @.Destination -- else return/ @/ s: m. U; n% j$ B& M
        then
0 x" Y4 p: F1 F                @.Destination := void;  N- c9 W$ x, o+ R
                if @.occupied then
6 I; R5 D" q  ?; C; Z; D/ q) A                        part := @.cont;
& t% V' v* H+ ^) v                        @.transpOrder := void;8 \3 B! F' g4 N/ D* {
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
" O% ]% p) e; d/ V! q                                @,root.eventcontroller.simTime);. W$ ~( _5 s) I$ \  Z4 X4 |; M
                        @.HasOrder := false;  A3 C* o" }4 K1 }1 B2 V, J
                        @.DrivingHome := true;
# l' y' _7 E* {) i                        rgManager.tryToStartTransOrder;
& F6 J# @1 {+ N, |, i                        if @.Destination = void
+ |* I1 @, D( c2 T                        then -- no transport order for vehicle @0 A6 @2 a1 h7 ^. _# Z4 u
                                @.Destination :=
9 M1 N$ I* }" F6 |8 L                                rgManager.nearestFreeStation(@,track.~);: s$ `6 C( q6 ?# Z, ~" ?$ [
                                newDirection(@);   
' C* e5 H$ s3 r7 ^                                if @.Destination /= void then
7 s% {; U: j8 N                                        @.Destination.NumReservation :=
2 P9 J  [! Z# Z# \. {+ d                                        @.Destination.NumReservation + 1;
0 v7 g' z+ U# t; @, l                                end;) J3 W3 E! _# \3 g9 U
                                @.CurrIcon := "drivingHome";8 B! z3 o+ I# I$ W3 L4 D
                                @.DrivingHome := true;4 Z2 I9 S" O" \: ^9 W2 l
                        end;
; l! c% Q. i0 Z1 n8 H                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
6 P# |/ K/ I/ c3 q                        part := @.transpOrder;$ |) a, b3 j2 t
                        part.move(@);-- load part
4 H# ~/ F3 f1 f& g* b6 i6 d8 w+ ?, }                        @.CurrIcon := "load";; V; ?( t0 j2 }/ g+ Q" I
                        GlobalDistObj := part.globDestination;) E$ n" m! }, F* o4 ?+ @1 A) Y
                        assignLObj := rgmanager.rgAssignL;
$ @% S$ t) y! A8 L                        row := assignLObj.getRowNo(GlobalDistObj);
3 _  o  E; v  B; x                        if Row = -1 then -- since 70! V" Y+ _* q0 [
                                if lan=1 then
$ }- h% e" @0 o* A                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\"")," s( b* C8 ]: c5 R6 p7 z) f% J
                                                to_str("in der Andockstation: \"",?.~.name,"\""));+ A1 g' A% P7 ^/ P. `2 K9 B
                                else7 e6 n: W9 z7 G* S$ K# f  E. J
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),& ]" ~  L2 i9 k$ A* c  g
                                                to_str("in docking station: \"",?.~.name,"\""));                                : ~5 U# f; y: j! i% D
                                end;
" N1 i. i0 n; u% e                        else$ q: Z! \- K/ n: d2 B* K! c
                                @.Destination := assignLObj[1,row];
. M, t0 x( {1 K4 f% i. h5 _                        end;                        7 Y, R2 U; T7 `. D; Q" w7 @& J5 k1 m
                        newDirection(@);
5 l4 g$ N2 O" z0 \/ p                        @.HasOrder := true;
# J8 y, c/ k2 x, w6 F+ S2 Q/ b                end;
  I" k+ k* h# R7 F( f        end;! ^8 L. C- t: c% x
end;        -- of the method
, h% K. g: H  b4 U& m" A. s/ |4 c* `
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
7 s7 F; a4 N" }. W7 h9 Q% T5 {/ J" d5 U( Y4 Y2 n
这是AGV_putin中arrive的method。7 `: A6 V# _/ [8 L

4 R8 B' c  @. \当到达物料速度越高时,这个报警更多,; _+ v  W& @4 w- p
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。, H, c* F* F3 K( F: R; a
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?% G3 Z8 \) d7 F+ y1 |. _8 m3 D$ U
, \9 d9 y. u% z" [
另外一个小建议,就是move,所有的move都可以这样9 b' Q  Z( z& a- t
if not move() then debug end" Z. z7 F( R4 b: l" e9 G
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
- x/ ]2 w; i( e0 M4 J% x( v5 f* Uplant simulation中的free libraries有AGV模板,6 T) J) S) q" D9 o
里面也有案例。
; C8 e' s% r2 h' b我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
* o- r9 ?3 d* ~7 a) x# f+ U2 l) y0 w" G, [% r* ^5 @- a. ]4 y& c* \3 M
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
. H4 o( `) p( N& O4 ?1 d
; D/ K0 j; l# k8 {那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ) k8 s: K/ S0 Z
这是AGV_putin中arrive的method。
5 O" K7 V/ w! V4 c/ V4 H4 |- C4 U3 H4 h/ ~  }
当到达物料速度越高时,这个报警更多,

" L* b1 }# {' t另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-20 02:08 , Processed in 0.017211 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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