设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6404|回复: 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', u6 x5 n1 n1 F! d$ U/ C1 N
*/
: @4 M3 z1 ^% f8 c8 ?; ]% Kis
# P4 ]+ a. w( \/ A        part, GlobalDistObj, assignLObj:object;row,Lan:integer;0 h0 Z% B# v, s
do
/ ^* E3 i6 D$ R# `& y$ o% ]: W, k        Lan := rootfolder.Internal.Tools.AOLlanguage;
& V" S- |) c2 U# R6 t2 o        if current = @.Destination -- else return1 D6 G/ I  H8 |3 v" V! C% N3 |) d6 ^
        then: [- k* m' ]$ S, h
                @.Destination := void;- W7 y, [. h8 }
                if @.occupied then
- q5 g7 J2 B% b7 d# ~4 A                        part := @.cont;
1 [1 Y- Z4 l5 ~9 w+ A                        @.transpOrder := void;
" Y  {  T  O. e9 G8 @0 F# L                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
9 E6 o; t2 X* j- k; a$ y" S9 T  P                                @,root.eventcontroller.simTime);
/ j/ s! s9 k% o" \: b8 t                        @.HasOrder := false;
: q" V7 R( {& m% {                        @.DrivingHome := true;7 U3 G2 L+ `3 f0 X# y
                        rgManager.tryToStartTransOrder;
3 [& ^3 F: C$ B/ ~1 f6 T                        if @.Destination = void4 w; @' J1 H$ V1 C% i7 G
                        then -- no transport order for vehicle @6 `# u, v& ]5 e; l* s
                                @.Destination :=
  `2 i: T+ K# F: @: Y/ z1 g                                rgManager.nearestFreeStation(@,track.~);
6 E# C* S/ u! W8 d2 U3 d                                newDirection(@);   
& U% O2 s. G" K* o4 m4 S                                if @.Destination /= void then
9 l0 g8 r7 Y- c, X                                        @.Destination.NumReservation :=( o9 y6 }' W1 Z* g
                                        @.Destination.NumReservation + 1;$ }! N" v# o& j0 t) j- h
                                end;8 D1 N$ d2 {# B; o) e0 X
                                @.CurrIcon := "drivingHome";
! o3 u. r6 P4 c6 V6 `) j8 s, E, R% @                                @.DrivingHome := true;2 T( S, \8 `/ {! x* }" `
                        end;! X. u3 |. }. K
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
8 J# @# i* Q9 H+ {3 i* M( N                        part := @.transpOrder;
# X- g+ R# x# i5 P. f& R; L( h                        part.move(@);-- load part& s3 u. [* p( ~( S
                        @.CurrIcon := "load";
' O7 z+ s) \/ J; V. e* }' S                        GlobalDistObj := part.globDestination;& `/ d' t  O4 {5 ]
                        assignLObj := rgmanager.rgAssignL;
$ `  V8 x7 r) }) u' h                        row := assignLObj.getRowNo(GlobalDistObj);
6 r! R5 Q& Z2 G" f& `                        if Row = -1 then -- since 70' }/ E# d- M8 x" T( ^& K; Z
                                if lan=1 then
" E* y# O. w4 D4 A0 I6 r, [+ }8 \                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
4 @4 x# _$ Z" K0 a                                                to_str("in der Andockstation: \"",?.~.name,"\""));9 Y, M7 L0 U3 u8 w% m( B+ u7 B$ U
                                else# [" L# Z( W- N) F* U
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),1 ?: Y2 r8 s- @4 _: R& G
                                                to_str("in docking station: \"",?.~.name,"\""));                                ' W; T1 @/ T+ }7 |; a; W
                                end;# x- o* K) q2 }' E  V9 q7 R, |8 _
                        else/ f" C# t! S' O3 E3 [( N5 l* D: c
                                @.Destination := assignLObj[1,row];
$ `( W5 U7 n: N3 A: }                        end;                       
8 @) G/ G# F4 |+ H                        newDirection(@);( a8 C! P* L. w' c4 y+ q. b- T
                        @.HasOrder := true;
" ~. \4 ^+ a) W- d4 V1 e' U                end;
4 b  {* ]; t! H* e: H( p        end;: R+ T  M! y2 F6 \1 T
end;        -- of the method6 D8 y  Q# F5 r9 }& A/ n% T. F$ x
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 4 ~+ {: e3 K+ ~
5 V  K# i! U6 J4 r  R6 ]- O+ m
这是AGV_putin中arrive的method。! L$ o1 W. c. A) f( S3 S$ ~, G
# |8 T8 o3 A, Z3 f5 m' P& ?
当到达物料速度越高时,这个报警更多,* c+ E! v, z9 E* n7 ?& T. u
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。" ^* l$ k1 [8 S' L: }3 T$ N( I, @
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
# T8 V' r$ l. H. f( L$ g( q
3 V, [6 C3 S9 f/ s另外一个小建议,就是move,所有的move都可以这样
7 d& t& G; H0 M6 B% p/ `# b7 Cif not move() then debug end
: \8 t, P) `$ J, q/ K1 {( A这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
0 c+ c) X) q% Q8 ?' r7 O2 t: nplant simulation中的free libraries有AGV模板,2 v! O/ F  p  [3 M3 _
里面也有案例。1 t3 }" E" s! j, Z
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。* e# b2 S% Q( W' E

2 Q5 p9 ]9 j& ]我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
) [* _2 p% N7 H  h8 F) s7 F1 n- R, `6 z
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
, Q, ]! d, z! o) H- g" u, p. I& R$ }这是AGV_putin中arrive的method。
  v2 u, z7 x) a3 J1 w5 O. J8 q
& p( I4 E- W6 N# c! E& K/ m4 M  L当到达物料速度越高时,这个报警更多,

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

本版积分规则

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

GMT+8, 2026-2-4 21:09 , Processed in 0.022766 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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