设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8685|回复: 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'( _8 k: [, ^/ {+ b
*/
9 ^& M7 E4 K4 E  A' \8 M* V: _is8 z: W; R8 d, h2 n/ c7 O  @, U4 L
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;; k& t. U! ?2 z5 l; x0 {/ B6 w  r
do; B& ]& J! k; }8 @8 B8 ~
        Lan := rootfolder.Internal.Tools.AOLlanguage;, C$ S, U5 q" P7 M5 p* g
        if current = @.Destination -- else return
* r9 q8 H( g- V) t6 W* u        then
2 M/ t6 l( L% I                @.Destination := void;+ N6 y; [$ f, Z/ F9 {6 c
                if @.occupied then
1 a% [9 _/ ~# z7 P5 w                        part := @.cont;
' N* C  p* w2 |4 l+ ]6 ^                        @.transpOrder := void;# Y9 i4 ~" X0 f; U: k
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
8 U( N: D- P0 ^$ B' s& i                                @,root.eventcontroller.simTime);* c4 R8 a- L1 p5 ], b0 Q8 F; U8 a
                        @.HasOrder := false;% k1 z3 A& i1 H5 y$ c
                        @.DrivingHome := true;+ k3 v$ H2 v& }5 l! G  R( L
                        rgManager.tryToStartTransOrder;- W! f  [, M8 M5 n( Q! |
                        if @.Destination = void
# ?: F* w/ N6 Q* j8 [# R. q                        then -- no transport order for vehicle @9 @! l; R' Q  z3 ~
                                @.Destination :=# F' h- \: I. A4 i
                                rgManager.nearestFreeStation(@,track.~);
9 H, T: w" l4 E% |5 W                                newDirection(@);   
" s9 p5 h% `! M                                if @.Destination /= void then* S/ F4 B8 b& x& G9 `/ u
                                        @.Destination.NumReservation :=0 K1 S5 A8 o. \! j% P
                                        @.Destination.NumReservation + 1;3 j* \0 s1 @$ M" P* B. C* T
                                end;. \1 ^; v& u* b' [% q
                                @.CurrIcon := "drivingHome";& Y& F$ C2 n5 G
                                @.DrivingHome := true;
. W) ?' Z6 I" l0 S- N. z                        end;
9 @& P/ R5 ]9 `! f0 U                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
' n' C, C0 F# b, I1 ^                        part := @.transpOrder;8 G3 J3 V  b! G' n
                        part.move(@);-- load part
0 ^/ w: k3 ?0 m" r* G$ f                        @.CurrIcon := "load";/ `" G& T2 W6 P( B3 T) A2 d: L
                        GlobalDistObj := part.globDestination;
* M# S& [' L8 F: L' R. Z2 b                        assignLObj := rgmanager.rgAssignL;5 }) n! `3 l* l; f
                        row := assignLObj.getRowNo(GlobalDistObj);
5 I3 s/ q- C. C                        if Row = -1 then -- since 707 t  P2 h1 x8 B7 ]
                                if lan=1 then! Z: h6 n( Z; L6 p! y) F
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),. t' y3 H1 u2 Q" }7 T7 f
                                                to_str("in der Andockstation: \"",?.~.name,"\""));5 W3 J8 `7 C+ c
                                else
9 V/ m; s1 k+ ^" }                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),0 z4 f; u1 X6 q4 l& n0 \* b
                                                to_str("in docking station: \"",?.~.name,"\""));                                ' d# b4 M9 Y7 l9 P, E
                                end;
0 {; {3 f2 ~- ^( M                        else
& m1 U  h2 z% i9 }2 L9 F* |& v                                @.Destination := assignLObj[1,row];+ X, D& X1 N, P* X/ i
                        end;                       
* H3 {, u% ^- l! T5 C$ e/ D/ l7 P                        newDirection(@);
; R! n- R- h1 Q# @                        @.HasOrder := true;
" X% N# r' D* z; @: l1 O/ R                end;
6 a4 M2 b1 @4 C5 Z, W5 e        end;
) G/ n- b) ?1 }' j. {" I! x( Tend;        -- of the method
4 ^- C+ w% ]% O' o% H
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 # g& p) h/ `% \, i
% T3 n( W3 s( q+ D
这是AGV_putin中arrive的method。" P- J, \& A* T7 S0 |  C& E2 d

1 D: g7 D# v: t% K当到达物料速度越高时,这个报警更多,  Y- v0 Q( W* A% R  A: S
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。2 O% @& P# h; z4 i% @% j, R
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
$ I$ y2 u/ F6 R5 d* Z7 P& U$ c* `; C3 d5 B( f, ~# a4 v9 g6 ^
另外一个小建议,就是move,所有的move都可以这样+ V5 d# O( _0 [8 m
if not move() then debug end, C" X. o) Y+ u
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
, G. s; s0 K8 h2 lplant simulation中的free libraries有AGV模板,
' u9 ^& a8 q( L! B2 l里面也有案例。& L- |; ]9 K6 X) {8 e. o6 c0 V7 N
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
# V6 C# ]* a7 P9 g# \3 F' _6 A1 S$ {) B+ q1 @2 A8 s
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 . k3 Q* F* Q) S2 b9 X; A  `& A) A! ~

0 |6 ^; {9 A# a% v那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
; K8 i( z% M0 \' T2 V( o; D0 P这是AGV_putin中arrive的method。. K$ }/ L8 i' S% ?! n4 g- f
- R# @6 p9 ~7 B
当到达物料速度越高时,这个报警更多,
7 L' D  i6 Q" w; i( Z
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-20 07:42 , Processed in 0.014140 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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