设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8631|回复: 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'
( `+ h) P5 W$ e9 i( U*/& H$ i' `; n- Z( G, ?6 S1 g- P
is/ k4 l; I5 j2 Z( h' E- x- {
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
5 O- J- `8 s; v: U6 n8 D1 ldo5 D6 b7 R8 Q& Z1 H) k( P8 Z
        Lan := rootfolder.Internal.Tools.AOLlanguage;( H9 |! m& Y# c- r
        if current = @.Destination -- else return
& y  |2 p2 J1 q        then
# ^4 [- @# ~& {( [" E* D" q! V                @.Destination := void;: b# U3 v& A6 `* H
                if @.occupied then6 P# J7 X- \% h/ f6 `: N& S
                        part := @.cont;" n+ S6 ^! ^! A# M
                        @.transpOrder := void;* v  Q# y, O2 V/ p
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,& q1 P: O/ @8 L  p: v
                                @,root.eventcontroller.simTime);7 O' e7 j% [* u& {8 Z; q
                        @.HasOrder := false;
6 X9 t# x( A6 O5 d4 i% S; O                        @.DrivingHome := true;
- ~9 U' U- O/ H4 V% G3 p                        rgManager.tryToStartTransOrder;
' u) q: Q; M- S( @0 K  t6 o                        if @.Destination = void) C7 j- f- h# H+ Q# p) c2 e6 X7 T4 q
                        then -- no transport order for vehicle @3 F6 G! `, r' g8 v) a' D
                                @.Destination :=2 d- D; o1 {( u: }/ X" T' ?% X
                                rgManager.nearestFreeStation(@,track.~);
+ D8 }$ J: R/ ]: K                                newDirection(@);   
5 w5 A$ P- S) X! p7 u                                if @.Destination /= void then# p( T; `4 r  h6 S% a" \1 l2 {- d' O
                                        @.Destination.NumReservation :=
. ^! C3 X7 P- M# R4 i* O                                        @.Destination.NumReservation + 1;! [1 ^  d, Y+ O6 ~9 a" E2 D5 w
                                end;
$ |2 h) A$ p& ~0 _2 E9 D                                @.CurrIcon := "drivingHome";0 ^1 `( ]* v( Z& g4 S! q' M! S
                                @.DrivingHome := true;. ^3 R  {% D- M  }3 {- M
                        end;
: p# Z0 H% o9 V                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
$ a/ \/ \! N2 L( }. W1 Y                        part := @.transpOrder;
$ [5 t) u: V4 Y# [, q$ l                        part.move(@);-- load part
- n) u$ f; F" l" s# C/ ~" D7 \                        @.CurrIcon := "load";
. u4 z$ y& S9 [! [                        GlobalDistObj := part.globDestination;
7 ^1 ?, |0 ?2 `+ O( M, l6 h                        assignLObj := rgmanager.rgAssignL;
5 p' q* ~" m& V                        row := assignLObj.getRowNo(GlobalDistObj);
4 w( I3 o) ]5 Q! K, A                        if Row = -1 then -- since 70
8 U; B1 Z/ ~6 w8 A. l1 @# i                                if lan=1 then" U! Q3 v, r( a$ l( G4 J
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),1 C4 o- n% q( o5 B/ V9 X) [; x
                                                to_str("in der Andockstation: \"",?.~.name,"\""));' @! r0 C5 ]& H8 a3 m
                                else' F% A0 A( D/ a' x4 L6 b
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\"")," r0 q: u2 g* f. B+ D
                                                to_str("in docking station: \"",?.~.name,"\""));                                1 I; b, x  j3 R5 B  q! S
                                end;
) @" }9 X" Q: n                        else, l, N  T8 D0 x# b$ T# }. Q$ q  u5 H
                                @.Destination := assignLObj[1,row];
! [  J1 E7 }2 E                        end;                        1 S5 T6 s1 l) n7 X/ L# \: x  E0 B
                        newDirection(@);+ Z, R9 ^2 Q: w! b$ E
                        @.HasOrder := true;
0 @9 L/ O! N, M1 T                end;
3 B9 Y. K, \* o        end;1 u% E( V% s* ?2 v
end;        -- of the method* E, o0 f& ?0 p1 u' r; B
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 # S% ?# Y6 U/ T6 R# m
# w" Y% X! c# E6 S0 e6 Q
这是AGV_putin中arrive的method。
- K# y6 C* M/ g
) z; I8 I% n0 l/ [5 C当到达物料速度越高时,这个报警更多,; i/ P% z' |  U
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。- A( W7 m  B) Z* z; m
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?- d, G" p' `- K
* J) G) q% v5 E! |0 n
另外一个小建议,就是move,所有的move都可以这样! f6 J" M  A1 }1 V1 M7 l9 t
if not move() then debug end2 w9 S$ C+ _; O4 P! B1 V$ {) o
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
+ s! f4 t( F8 zplant simulation中的free libraries有AGV模板,
$ ]8 J3 i/ u  @% E" d. W里面也有案例。
( T- {2 @' T* k6 x6 G" {0 L' {我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。( B$ l2 m8 T* P
  @5 ~; y' b6 B, s
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 3 T1 F* e) S* ?4 Z# j: \, w

" Z* B( n2 b4 F  c1 E, w) @7 i那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
; [+ j! I8 F8 s& ?9 L7 A1 j这是AGV_putin中arrive的method。
6 I) Z' B. L; y9 ?% H8 Z+ c# `' \( N  \; s0 B
当到达物料速度越高时,这个报警更多,
  X* ]4 U( k+ U* c
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-17 02:23 , Processed in 0.020088 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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