设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9813|回复: 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'
  U$ u& S1 l8 _4 u; s$ G  ]*/5 ?" m. C  x+ A# U9 X% {
is2 p; b9 E( ?+ [* D% F, d" x
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
4 C9 y. |1 `( w5 Cdo/ K0 P) d  J8 o8 a, s5 W% |
        Lan := rootfolder.Internal.Tools.AOLlanguage;
7 q& J0 `! U$ s/ F# }, l. w3 ?! S4 M        if current = @.Destination -- else return
3 b) F9 p! c+ i  r        then& q) Z& O) P  x
                @.Destination := void;
& M# l; g/ Z! i( R* e, B                if @.occupied then+ \0 b" C3 |9 i3 ~1 C( ^4 k
                        part := @.cont;7 f% j3 _0 H$ D6 C' l
                        @.transpOrder := void;
7 E* B$ l9 W! J" d4 D4 n# Z# M  u$ \9 u                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
; ]) v! g* a% N9 N: k1 q                                @,root.eventcontroller.simTime);5 y0 Y' D: t2 ^5 y; _& t' {. C
                        @.HasOrder := false;! q+ W- g9 D5 V/ ]' W
                        @.DrivingHome := true;
# X# N' I0 \4 ?! M! l2 o                        rgManager.tryToStartTransOrder;. J3 y' l; m. ?$ \
                        if @.Destination = void
6 E. d  i' h2 n: _) J/ a                        then -- no transport order for vehicle @
: S7 p& W6 M8 K                                @.Destination :=
, g, |5 ?# }6 S* y" g0 p5 F! A                                rgManager.nearestFreeStation(@,track.~);
$ e, O0 q" Q$ ]3 S  b8 U- w/ s                                newDirection(@);   6 g2 S! N( T# k+ x/ t  S- U
                                if @.Destination /= void then
* N6 P" }$ v6 j4 {' _                                        @.Destination.NumReservation :=9 d7 t- x6 E# I( Y# t
                                        @.Destination.NumReservation + 1;* L! F: r- p' I' O" f1 b
                                end;9 s- ]4 W8 L- z& X6 p
                                @.CurrIcon := "drivingHome";
) t8 Q" W5 L1 w4 C                                @.DrivingHome := true;8 K, b( F' s% H; I
                        end;+ J3 M/ x2 w1 ]* b2 i
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station9 j, \9 s* @4 w' m' F8 E
                        part := @.transpOrder;- q! M$ s1 W. A, T  m# t
                        part.move(@);-- load part
+ v" `. W  Y5 ~% c                        @.CurrIcon := "load";
/ ~# ]3 p, e4 F' U                        GlobalDistObj := part.globDestination;
- E8 t# _% _7 E8 x# d/ s                        assignLObj := rgmanager.rgAssignL;6 ]' O9 b* s; l3 \8 V9 ?, P" s
                        row := assignLObj.getRowNo(GlobalDistObj);
3 {& p1 @) E- Y+ B# s: h3 q  Z0 d                        if Row = -1 then -- since 70% [1 f+ l: q6 X
                                if lan=1 then
+ _+ q2 D- n2 l3 W, h+ j                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\"")," P1 Z' u+ t% @5 E: U; @# v* E4 z
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
9 L, L6 I% d6 S                                else
. m5 c; T' K$ O                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),$ Z2 E+ W$ T' w. ~0 M
                                                to_str("in docking station: \"",?.~.name,"\""));                               
! I' _8 _4 Z) @; s; o9 Y                                end;
7 T: y2 N/ ^  V4 Q                        else
3 D2 H4 r0 v. w. }                                @.Destination := assignLObj[1,row];% K; K; q8 p- x0 A$ R
                        end;                        + u* v0 L: x. E' O: [7 X
                        newDirection(@);# W4 u1 _# g, R
                        @.HasOrder := true;
2 R: h- H  |9 J5 K5 H                end;. |' d- I  k5 q, P7 W2 r$ \) _
        end;
1 R1 |8 S8 N. r$ Y1 y' v: ~end;        -- of the method1 l" P! ~- N/ g) ^( w
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
1 R2 A) p( z1 Z" X3 |! G, `
/ O2 f: |. v( l3 i* y6 W这是AGV_putin中arrive的method。
, B" a9 G+ b. K  C( c5 |, M- p$ `# l# K' w+ D/ b5 y4 U
当到达物料速度越高时,这个报警更多,% L' A2 g' G- A4 s
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
; X8 d( j% p- ~- U' V9 Y3 {程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?1 a: g1 F) N3 O0 S* p. ?
; J2 O$ T" |+ g/ a
另外一个小建议,就是move,所有的move都可以这样' C. J- W8 E8 G3 [3 p; i3 j
if not move() then debug end
, f9 P1 Y, ]+ K' R3 H+ O这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。8 n- F- ]( c9 ]8 a) J0 l; h/ Z
plant simulation中的free libraries有AGV模板,4 k: o: b( A' B% O8 R, d$ F; J$ d
里面也有案例。
/ F0 H: |. ~# O  S我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
' `- F4 [3 \! i; _8 X# q0 t1 d* l
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
# @0 B) O8 s% ]" [" }! p
# C: U' m. g' Z. F! p# l1 q那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
  ]' m9 H% M) g. t; V3 K6 y4 E这是AGV_putin中arrive的method。
$ e2 F6 J4 X9 ]2 E/ x
2 U  W! W, `$ i* E- r+ q( o当到达物料速度越高时,这个报警更多,
% t; ?  p2 E) E8 x7 s
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-26 22:26 , Processed in 0.017158 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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