设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 4981|回复: 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'
: v/ o8 |0 C  o# S# p) {, v*/6 r  M3 v7 F5 n8 s. W% \
is3 t0 Z. m3 D; y/ O" i" S
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;- j! c  z+ a: [$ M) F0 ?, Z) \% k1 ?
do1 y0 a" \$ n+ E) ?3 O  {: G( ^/ w- B
        Lan := rootfolder.Internal.Tools.AOLlanguage;' T8 d6 _8 [3 \3 Y% f5 I
        if current = @.Destination -- else return
3 m# V) x# M7 P& G9 d        then
5 Z/ d6 F1 w+ e( |' c$ |                @.Destination := void;
4 V# Y$ M6 C  ]                if @.occupied then. R  B2 M% G6 e2 b6 [2 z
                        part := @.cont;7 U0 ]) {- r, P! Z- P
                        @.transpOrder := void;
$ I; G& C3 g* T1 ~0 }                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,1 U9 f6 u' e1 N" v
                                @,root.eventcontroller.simTime);
/ H7 m- ~/ r" W                        @.HasOrder := false;
* I  g# _9 e9 x# u0 g2 Z                        @.DrivingHome := true;
' q! P* l  V) H                        rgManager.tryToStartTransOrder;
0 I. ]. ~5 c& {) p5 r) d8 @; M7 ?6 J                        if @.Destination = void2 r' s. m4 e$ [( T. H
                        then -- no transport order for vehicle @
% N: c/ l0 h' O1 Y                                @.Destination :=1 a% F- G/ |: J. H: |# I
                                rgManager.nearestFreeStation(@,track.~);
4 l# \; b1 R4 q! L                                newDirection(@);   . L: Z: S% L" T; x! y
                                if @.Destination /= void then
9 x( d+ S6 T& p% O$ M                                        @.Destination.NumReservation :=
) e8 A# t7 u7 U6 {& o6 \) J                                        @.Destination.NumReservation + 1;: ?: ?9 C. [5 V& L" a3 C
                                end;  n. V  J1 N: j/ ]
                                @.CurrIcon := "drivingHome";
$ b8 M; u! T+ {0 e8 O- ?+ ?$ ~# A                                @.DrivingHome := true;4 {9 z9 v* O9 x
                        end;
0 F( [* y/ l3 d1 X: s: Q* u4 F                else -- the vehicle @ is empty, both vehicle and part are in the same dock station; b7 E. q) [: [2 G8 A& J7 f: e
                        part := @.transpOrder;2 b) E$ U. u: S: x. t
                        part.move(@);-- load part
, }' q, ^, D  Z! p/ c  Z: h2 R                        @.CurrIcon := "load";' e) y( }5 v9 V5 ^3 c
                        GlobalDistObj := part.globDestination;
8 z0 Z5 E/ b0 i' l# j1 ~                        assignLObj := rgmanager.rgAssignL;* B7 ?5 E$ p* R- _/ L
                        row := assignLObj.getRowNo(GlobalDistObj);
1 }/ M4 k+ H4 j/ s* V3 i                        if Row = -1 then -- since 707 a" [3 d, S, J$ `, k
                                if lan=1 then
1 w8 x  r1 X  I4 g. N                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),6 u2 n; w( `; m% l( E4 H0 K
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
( k/ s0 |8 Z$ u, H7 o. N0 ?                                else7 i: H/ N& N% _# ?! T
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
9 t# z/ Y4 u; _4 i3 Q                                                to_str("in docking station: \"",?.~.name,"\""));                               
7 Y. U. ^( o* o" F                                end;
' R, ?: h, a8 L0 V# {3 r                        else/ c$ k" D! T, m* Y6 z$ \1 u$ t
                                @.Destination := assignLObj[1,row];
2 h6 f% J7 L# H6 `: g% }& z- `. G                        end;                        1 y/ F# u& u6 C# o& P7 b
                        newDirection(@);1 B: N# q, h* p- S
                        @.HasOrder := true;
0 b0 N/ @# r2 z                end;) ^0 m+ f9 d4 h; h! n) A: V% L
        end;
) E+ }) }& d; tend;        -- of the method# x9 E8 u7 @0 t' ^# G% ]6 `" f8 L
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ' S; X5 B* M  S2 U

) }& }) L$ }/ G) a) {这是AGV_putin中arrive的method。. Y  l( T! u7 I0 d5 z0 a
  \6 W+ {6 H. S$ d2 |
当到达物料速度越高时,这个报警更多,
; }! x1 x! Z3 y! b0 J* E可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。. q4 p0 k# ?7 [8 p
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
6 ]6 I7 o3 N( f; ~" y' q1 H9 n! d6 X: h% Y2 p6 n. y$ k  z
另外一个小建议,就是move,所有的move都可以这样
+ z) F2 N% t% mif not move() then debug end- d) S, }2 T3 C: N
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。6 m' B: T7 K3 n
plant simulation中的free libraries有AGV模板,; M2 X8 Z7 g$ B- W& n! e
里面也有案例。( Q/ G$ s0 D1 x: B( L
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
$ d+ V. ~% l- ~# l$ P
( c) I8 k* P4 ~$ h! b我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
, t9 K3 Z9 _5 ~  |9 b8 y  T: `
! @; g/ h+ U3 Y! c! X& h- S2 `那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
6 @: o0 x6 s% a5 C& ]# e+ O- y* n# j这是AGV_putin中arrive的method。2 ]$ r* `3 d$ q' P
, J9 K1 r1 z3 g$ o3 U% q0 u
当到达物料速度越高时,这个报警更多,

: z: R/ r9 U0 i" L0 k# o' A另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-9-18 21:18 , Processed in 0.023192 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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