设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7793|回复: 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'
6 h# u0 ?/ k" {# d% |* F1 v*/+ X1 n/ E* `! T' x5 c+ ~
is
$ l0 \- _! K, k! Z        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
/ |4 V; ]) i4 ido
9 s, [3 ~' L) L3 J        Lan := rootfolder.Internal.Tools.AOLlanguage;
' c1 ]2 L% L) W  D/ s        if current = @.Destination -- else return
8 Y. W) Q: Z/ y2 u+ m# m        then3 c- a# d% a+ p  u, I/ F0 X
                @.Destination := void;
* b* S# r# n# |3 c* [2 d                if @.occupied then2 b- h7 ]* x! a) `4 V: @6 W3 {
                        part := @.cont;
3 ^: g5 }9 v+ {                        @.transpOrder := void;" E  R' y2 O" z0 L- V0 V
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,* h) M! [+ G0 o3 X: M
                                @,root.eventcontroller.simTime);
" V6 G& N# U% E9 _  L; O                        @.HasOrder := false;! E+ _; a  p  \, Z8 j/ [
                        @.DrivingHome := true;0 c  l2 ~9 D" g" A
                        rgManager.tryToStartTransOrder;; e; Q+ k7 r) S' m/ ^
                        if @.Destination = void  c7 l' o0 A7 o- N9 i
                        then -- no transport order for vehicle @' [- }! |! s2 c' _& z
                                @.Destination :=
$ Y1 k1 n# r. B( K                                rgManager.nearestFreeStation(@,track.~);
8 e' q- a8 {# |$ ]; K                                newDirection(@);   
) ]3 k+ ^) C  ~                                if @.Destination /= void then
) Z. i3 P% ^7 p) s. ]2 R% J; j                                        @.Destination.NumReservation :=5 R: l6 n9 C2 P1 Q2 p" N
                                        @.Destination.NumReservation + 1;; {7 B: [: A- m9 P0 a
                                end;
8 d5 J: W5 w* l                                @.CurrIcon := "drivingHome";8 i5 f/ A2 i) R4 X4 z$ T
                                @.DrivingHome := true;; }% V" y" ~" h* C: D4 k
                        end;  d( \5 [9 g! D" d; m
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station, d5 b- \  A4 t! L) G7 p3 z
                        part := @.transpOrder;
$ }- w8 n4 P7 `7 P                        part.move(@);-- load part
; E- Y4 r$ S% S6 q                        @.CurrIcon := "load";
7 r! M1 g3 U0 `9 K. Z; W, m& L                        GlobalDistObj := part.globDestination;
0 c( @3 S/ u, l( Z8 \* `                        assignLObj := rgmanager.rgAssignL;
+ _9 J) s, s" l6 k- K: p4 T3 M                        row := assignLObj.getRowNo(GlobalDistObj);" c$ ]1 T# _6 U1 T
                        if Row = -1 then -- since 701 y4 ], }. k0 E/ Z! K" b! p
                                if lan=1 then
7 B1 |, Q5 K% h1 K& R                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),. Y: r; O" G# n
                                                to_str("in der Andockstation: \"",?.~.name,"\""));1 e6 d. }2 N5 G+ K
                                else2 W5 v" C6 y5 A7 }% V8 q
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),- d3 }4 m! J, ~) L" v
                                                to_str("in docking station: \"",?.~.name,"\""));                                + y% E1 p3 n- h9 u8 Q" I" x
                                end;0 Z4 B8 `5 S% E' Y9 J8 Z3 J
                        else2 g, l# l: D, [" I
                                @.Destination := assignLObj[1,row];
) s  J2 [- Y0 J9 |  k. _! m$ |/ t                        end;                       
* I. w! ]8 z2 l; F1 X! Y2 y# a! K                        newDirection(@);7 ^: ]  q) i# ^2 H
                        @.HasOrder := true;' f/ q+ X" j; H3 u4 Z
                end;& i6 G% \+ }8 o9 h6 V8 n
        end;2 n3 [6 c1 o! q2 }' P# G( c* G
end;        -- of the method# q8 H1 d9 \4 E0 O  c$ `2 _
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
0 Z. G& P! V" w( J& p0 R9 M4 x$ t4 w2 ^* E# h% v  A
这是AGV_putin中arrive的method。+ l# E1 r" l9 j$ ?5 T

, C8 }' S- V) _' o& j当到达物料速度越高时,这个报警更多," i' W- e1 d. M% Q. O4 U1 T4 l
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
3 j+ k8 o  E, q程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?+ ?; K9 x* t% O- R: o% Z/ `+ `0 u
# ~/ n4 d6 p9 V4 |
另外一个小建议,就是move,所有的move都可以这样
( ^/ _; P/ @; X' B% _5 {if not move() then debug end
9 R% [) U0 f6 b+ d2 L! g5 N这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
! X6 J2 a3 e$ c- c( {plant simulation中的free libraries有AGV模板,  |; u/ a6 o  L. }
里面也有案例。
9 {* `4 T9 ?( r) ~我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
2 W7 y8 k  h) l5 n% y$ J2 T% w
# B% `1 }: r# T& Z( K我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
' u+ p) Z: f3 @  y* s# k
: B- V* |+ e  f1 L8 y  B# e那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 3 g8 m* Z; K, K  g- J' t
这是AGV_putin中arrive的method。  Z* e: X5 {, W# Y6 [6 f
4 Z9 u; p$ m/ _. C* X5 l
当到达物料速度越高时,这个报警更多,

5 p) S, A6 a1 @2 Q; E6 n另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-29 13:52 , Processed in 0.020353 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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