设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7630|回复: 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 v& T/ r; w' P2 a; b. P
*/
# U, t' U- \& ~5 f8 Ois
1 q* P8 h, O9 f7 F, Y3 b        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
# Q, T( S! r: Y  e+ Cdo
' ^* x! _: z5 ?6 ]        Lan := rootfolder.Internal.Tools.AOLlanguage;
3 `7 R3 J  Q& ~% G; M4 H        if current = @.Destination -- else return; ]. \! r( k2 M1 C. M4 M- b1 N
        then
, Z5 v, j$ @6 l  c                @.Destination := void;# z! [$ Y$ S" O  q( Y
                if @.occupied then
$ F+ q* Y) o+ ^7 i  D                        part := @.cont;
  Z. H& V5 v& B1 }& C) |  J                        @.transpOrder := void;
+ ?0 i) Q+ w4 J$ Y' c                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,, B9 K, U+ t! g. E. y5 H
                                @,root.eventcontroller.simTime);9 l: W8 F6 x4 l( p! N
                        @.HasOrder := false;
; R$ r3 H) W5 v* f; X7 `' _# }                        @.DrivingHome := true;
. B$ {3 A* ]! |' {( V. P8 m1 @                        rgManager.tryToStartTransOrder;
  z; \7 v* O) h! O! ?& r                        if @.Destination = void' D3 a" J- D" x) E& Q8 T
                        then -- no transport order for vehicle @* o4 Z: y% u  T# v/ D) q% N
                                @.Destination :=+ Y' B( M( l4 n6 q
                                rgManager.nearestFreeStation(@,track.~);$ r0 p$ Q' L7 z! J  t# G
                                newDirection(@);   8 \: m6 b2 U9 {0 C
                                if @.Destination /= void then
4 R& ]8 O' F& @& o- f                                        @.Destination.NumReservation :=
% u# p4 i" l) w' x9 }7 v) n                                        @.Destination.NumReservation + 1;6 b( G" j  V- [6 v# K1 s
                                end;- G6 d9 H! K# y- `3 x& Y
                                @.CurrIcon := "drivingHome";
. x1 ^8 p6 y0 @4 l) @                                @.DrivingHome := true;
: a- b$ `/ c- G5 z1 ^8 R4 e                        end;
1 O, `' O; D- b5 O8 ]1 l" O* g                else -- the vehicle @ is empty, both vehicle and part are in the same dock station, @/ d7 o1 Y$ E
                        part := @.transpOrder;0 Y" s: |) B2 E
                        part.move(@);-- load part
0 x) a5 I' b2 g' h1 e+ ?: ^                        @.CurrIcon := "load";
  f5 K8 s; l0 k                        GlobalDistObj := part.globDestination;+ n2 {- j- }! ]0 p, k$ H
                        assignLObj := rgmanager.rgAssignL;
3 a) h: X1 s, h, P! I                        row := assignLObj.getRowNo(GlobalDistObj);6 C7 t, O9 u& s0 H5 f% s* T
                        if Row = -1 then -- since 70
& E( k  s1 V9 K$ }0 }" `, Z. k                                if lan=1 then1 r/ G% H  d6 L4 z
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
, w6 g- k  W6 `% E$ d                                                to_str("in der Andockstation: \"",?.~.name,"\""));# {. \! f  X5 Z8 l
                                else/ X% G+ V1 F  E
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
7 Q& h+ d/ A% a9 ^, e" {                                                to_str("in docking station: \"",?.~.name,"\""));                                6 u, a/ V; @7 [  S" E
                                end;  u" m) y7 _$ i" a7 [/ l2 w
                        else% I: K$ ^: p: l9 u  U
                                @.Destination := assignLObj[1,row];
# W* u* m: x  z% ?) }( v7 }                        end;                        + _9 e. l8 ]2 y8 E' O5 P
                        newDirection(@);1 m7 W) D2 g# G) f  ]; w9 C% q
                        @.HasOrder := true;
3 G2 q: S2 f0 r! C( Y: e  h6 ^                end;' R+ @& |6 q% B+ `: U
        end;
) M! B' U2 W( ?1 u/ I1 mend;        -- of the method5 X5 X6 N7 c" T' K3 d6 o
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
& G- v+ L$ L/ S0 I( O6 x, ^/ _+ y
这是AGV_putin中arrive的method。* i6 K4 W6 r: x# ~  D5 N
' o; `! A% I6 Q8 f6 f+ a
当到达物料速度越高时,这个报警更多,
" I- b" u: J& j3 K. L! z- ]/ l2 }$ U可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。2 I5 A  {2 e9 F$ L6 K  B* c
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
; X& j5 R) C- S! e0 G: }" C) ]6 C; d, {- D$ a9 Z
另外一个小建议,就是move,所有的move都可以这样4 ^1 h- y. k2 i+ s' i1 {! }
if not move() then debug end
. K! n& o! ]$ m1 S这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。7 L. i0 A1 c8 g* b
plant simulation中的free libraries有AGV模板,
3 S; s! V+ g+ V2 I% y里面也有案例。5 h2 `5 U) A( ^& o
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。: L. f+ G' H7 n; \* P
& F8 Q/ o' C' a5 _' |
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
3 e. n2 l" T! H( r( k
9 {$ {* j9 W* Z* T8 \7 X那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 / @, M5 V7 l  k/ q
这是AGV_putin中arrive的method。
2 U! d  C, W; N3 q* T" a  ^! I
& c- }* }; h) D2 C6 K, a7 o当到达物料速度越高时,这个报警更多,
- N. w4 d0 d: G/ Z4 b
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-21 04:46 , Processed in 0.016159 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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