设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7087|回复: 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'
8 D# M9 c5 D/ G* Y. P4 A& z*/
- `1 W8 k; G4 H, Y! [) ois6 \+ W9 |5 ^3 T$ ~9 P
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
# a' ~5 k! x/ ~& Z# Zdo( X2 ^4 Y  W0 y5 M
        Lan := rootfolder.Internal.Tools.AOLlanguage;. m6 L$ O2 `& {, K  E4 e
        if current = @.Destination -- else return4 P' a. b4 ?( B& V  R, c
        then6 ^8 p( }4 R! v1 d5 t
                @.Destination := void;
  r3 v3 C$ s! E+ V                if @.occupied then
9 I- z6 i4 R. r& @& n2 @4 Z& p                        part := @.cont;
! i4 b+ I+ O0 T( Y  `                        @.transpOrder := void;
. p3 K6 `  P) T8 P- S4 K                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,5 x- N  H4 z; ]% E& W) h. }- H
                                @,root.eventcontroller.simTime);
+ F* E7 L$ |( R: Y. ~' G                        @.HasOrder := false;
' S+ y3 I+ _/ ^                        @.DrivingHome := true;
; U7 R: t# v& E$ w                        rgManager.tryToStartTransOrder;
0 e$ k1 B3 {- @                        if @.Destination = void
% E4 h% f2 k: {0 A3 ?/ S4 j                        then -- no transport order for vehicle @
$ V7 z# ?, Q, a& O4 ?                                @.Destination :=
) ]/ D- w. z. c" M                                rgManager.nearestFreeStation(@,track.~);
1 p( F& |! |. G( i; n5 I3 I% d                                newDirection(@);   
% A5 K1 s/ |# h0 |9 F* I( ~0 k' ?                                if @.Destination /= void then
9 B" j1 c' W9 E6 X  }7 `0 Q                                        @.Destination.NumReservation :=: \. r5 A, s  i8 j9 A( d
                                        @.Destination.NumReservation + 1;0 P) u# E5 w$ Y* S" R! J4 J
                                end;' M" z/ I+ u/ F" I) _
                                @.CurrIcon := "drivingHome";
  t1 b8 B1 F+ K% i& J+ t5 m1 p8 o                                @.DrivingHome := true;! v0 T' |" b* J, P
                        end;
4 O/ O: M+ \- V. f                else -- the vehicle @ is empty, both vehicle and part are in the same dock station2 \4 s( W7 l- b) \# n  P
                        part := @.transpOrder;
5 j5 A6 Y6 B$ o$ Z! |5 b# x$ S: x                        part.move(@);-- load part. l: f: m& t! |. }4 _' {
                        @.CurrIcon := "load";
* j) ~" {% x* j$ i& Q  d                        GlobalDistObj := part.globDestination;
$ \. f+ Y5 l' R) A$ k5 c                        assignLObj := rgmanager.rgAssignL;" Y2 Y9 K/ c4 X7 M
                        row := assignLObj.getRowNo(GlobalDistObj);6 g3 Y/ b# x) C) A- l: f
                        if Row = -1 then -- since 70
- I7 \6 v1 N( w7 _3 A1 y* Y& @                                if lan=1 then5 z- r2 ^, I9 @/ W6 V) C& T
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),7 n2 e! h9 _+ V/ {: l* G. v
                                                to_str("in der Andockstation: \"",?.~.name,"\""));4 O3 ]- z1 v9 _( l
                                else: p8 P: r6 S1 @) C( y+ Q
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),( w* ?+ R6 o& k4 T3 ]& D3 s* j4 `
                                                to_str("in docking station: \"",?.~.name,"\""));                                2 @$ N& K% i, Q5 u' g- ~
                                end;
+ I  f' S+ r. H7 ^2 V% |                        else! V- W% s$ @4 e) ~9 B
                                @.Destination := assignLObj[1,row];
7 e0 w- ^  q' H! }1 Z                        end;                       
/ |, k% s( ^7 p. a                        newDirection(@);
9 j/ b& ?7 ?, d3 |: z8 Y- V                        @.HasOrder := true;; G% t" e4 E6 s; R* N
                end;2 f* M- Z/ J! E  \
        end;' U2 ^# f1 g$ m* w( s7 D: ^
end;        -- of the method
" |- }, T5 S5 l" |6 x$ x9 {7 Z
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
: \* H6 q! n4 U; G5 Z4 L
. E0 `; G8 N7 L  ]6 }6 m这是AGV_putin中arrive的method。. U; C" x( i3 m7 c

$ F( ~1 U. `+ t( r; E& {7 ?. W当到达物料速度越高时,这个报警更多,
  |: C* b9 x6 N可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
3 z! j" f& }$ B4 i程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
5 G; [" R$ }0 t& X& p& E+ @0 P" ^3 y
另外一个小建议,就是move,所有的move都可以这样4 r. ?, m8 s- [/ k& G
if not move() then debug end
/ B6 ~% f3 X5 N这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
$ S$ j' I% G) c3 g* Iplant simulation中的free libraries有AGV模板,
, Z# V9 c. [2 O里面也有案例。% c6 z  u0 z) q# M
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。% ~, x" j6 p* ?* X5 M$ E  Y% z% f
6 T0 D, D0 ~7 @
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
$ G! r. f' i, E: s7 ~( r( i, H9 T+ E% h
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
+ h4 F$ w4 g! h# j# r4 Q6 k$ G这是AGV_putin中arrive的method。
$ l; P; ]) [/ @5 O
8 p3 \# x( A' i: ^) A4 A当到达物料速度越高时,这个报警更多,

* w/ M! t0 g3 `& l; H6 X2 Q$ k5 [$ Y另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-16 05:02 , Processed in 0.017709 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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