设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7988|回复: 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'
1 R. t% H( T, {7 B/ M; g4 k5 J' a*/; G2 O0 I& S  F8 x8 ~
is
' ?% c  B# L. b& Y' y' D& A        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
( e1 c% [: `( P5 k6 s1 Zdo
1 y$ m, t. @8 D! x# l        Lan := rootfolder.Internal.Tools.AOLlanguage;
1 p4 I3 `) j6 {  v& o" c$ m+ j        if current = @.Destination -- else return+ ^; t3 P% D$ o$ j8 _6 `7 e" J
        then
6 v: v- {, u2 O* y                @.Destination := void;
2 P7 j4 y% V5 a5 s7 @! G3 U" M( J                if @.occupied then
8 u" m2 {. O; y2 M7 d- l                        part := @.cont;  Q! H( D" Z* `8 O  u  f9 o4 p+ n
                        @.transpOrder := void;
  N& R% |! v/ E) x# Y2 i4 U                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,4 G6 l& }! t; L
                                @,root.eventcontroller.simTime);
/ h  v+ {- b- m5 c                        @.HasOrder := false;
# j# v2 `+ c: ~9 B) a/ w                        @.DrivingHome := true;6 z* W' W7 S5 r  \: W9 \, s
                        rgManager.tryToStartTransOrder;
% n3 X' g+ Y( Y* z5 u# l1 x                        if @.Destination = void2 O3 Y, M" |2 G- I( O3 @$ a( c
                        then -- no transport order for vehicle @
: D+ F& X1 y1 J3 M- q. W                                @.Destination :=1 \# F1 d- y7 f& I6 q: Q& t
                                rgManager.nearestFreeStation(@,track.~);9 m; ~8 q: B9 A" O; c
                                newDirection(@);   
" ~3 {$ }0 _' u8 \5 `" `% y                                if @.Destination /= void then7 v2 a7 [+ u- K$ v8 Z- H
                                        @.Destination.NumReservation :=8 C; m! ]% c) u4 F+ J# t
                                        @.Destination.NumReservation + 1;3 B2 ]' K" o6 s1 [1 j1 y& B
                                end;) O/ S2 S5 K% {
                                @.CurrIcon := "drivingHome";+ R6 Z; |: J* D8 n
                                @.DrivingHome := true;
$ e1 e. G9 f6 e/ o) Q4 t; b                        end;
3 T9 [' X$ {0 h8 j6 j) v6 @' S                else -- the vehicle @ is empty, both vehicle and part are in the same dock station! n9 x% J# ]- m; [' V$ E
                        part := @.transpOrder;! u7 Z; f, D* b8 i& a
                        part.move(@);-- load part7 K. a. Y0 D5 a- V. h( P) y) h
                        @.CurrIcon := "load";* l1 [5 K' m  _2 R9 A% m
                        GlobalDistObj := part.globDestination;5 H* M( |- w0 |# o" G
                        assignLObj := rgmanager.rgAssignL;  f/ U# t$ ^% L0 M
                        row := assignLObj.getRowNo(GlobalDistObj);6 c! ^9 s) g: K1 k9 Y9 j
                        if Row = -1 then -- since 70
. S" q0 x$ E  l! ~                                if lan=1 then
- i5 `' u1 L4 e' N# e$ R6 Z- e                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),( q. a/ s: A9 A  h
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
( F( r: k0 h  r' b4 E6 y                                else& N6 L# Q$ |, b# k/ C9 P' e
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
2 q; c% u8 w- F# D) O3 [# ]                                                to_str("in docking station: \"",?.~.name,"\""));                               
9 f4 b  s5 C7 P, |6 D" O                                end;3 i& D  K% S! K" D; K
                        else
. z' b2 z4 }: [5 g+ \                                @.Destination := assignLObj[1,row];
$ ?# t" i$ [: G3 _$ }                        end;                          l9 F/ i6 I& D# D
                        newDirection(@);
1 c8 y& ?  [6 I/ W5 }                        @.HasOrder := true;
3 _3 q' r+ X7 y# a; p) \                end;6 m! R: p. N" W$ F3 H0 O& x
        end;
( K6 I3 v, P  Oend;        -- of the method
) \% l" J, d3 n: W& |& ^, @5 t, }
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
4 w9 ]6 }. M. h
3 t3 ]8 H3 D! n: e# l这是AGV_putin中arrive的method。
: t# z* J3 g/ J2 h0 a: ~/ ?+ x) G. G" H! k3 F7 d2 x  L- s
当到达物料速度越高时,这个报警更多,
' z+ e' W' C: |' k- v* I' G! z! j可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
3 a1 O7 [' s, `) H2 U) N程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
# ~% q7 [4 @+ s
$ b2 k8 T9 o9 F  O3 }. ?另外一个小建议,就是move,所有的move都可以这样* V' C7 ?# W# F- `
if not move() then debug end+ M+ b3 N6 s  ]4 ^8 J! s
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
2 N; T7 J8 I; L) C7 Jplant simulation中的free libraries有AGV模板,9 e9 B  A4 w' d* ]
里面也有案例。
; w- m- ^' q/ p, P. g. @( L& N: G我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。9 l! V% ]% ?7 @
) O- c' B6 F" i4 m; N7 ^" ^/ p
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ! J9 _+ y# i  n' u8 ?9 G
) V9 O7 s% j! n' ]6 Y
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08   {" H7 L5 h" U- C1 d  ^! W5 p
这是AGV_putin中arrive的method。
! |1 q9 M1 u/ U. p0 l6 O$ f* ~5 {/ a
当到达物料速度越高时,这个报警更多,
+ r- D) g/ e5 q: B5 Y
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-9 10:05 , Processed in 0.018650 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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