设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8627|回复: 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'* c% }- _' h4 U, q! m% H
*/$ l! L& S$ i. S0 K
is
$ S$ V5 A  W7 a/ E" {  E" w2 I0 c" O+ t        part, GlobalDistObj, assignLObj:object;row,Lan:integer;9 e0 C1 o% R" Y7 P, ]
do
1 x& s& H. j- W        Lan := rootfolder.Internal.Tools.AOLlanguage;( s4 ^9 k6 P6 g
        if current = @.Destination -- else return  p- k5 ^, V4 V5 K4 z
        then
* E) z& X' U( t3 N! y% e6 c                @.Destination := void;
2 c( x3 ?4 l  X# I8 |5 C. [                if @.occupied then
, F4 w1 `! w1 C2 [. X                        part := @.cont;5 X/ u, q! R8 M
                        @.transpOrder := void;
) v; B' ?' b/ M, Q1 x! K                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
6 L3 t- f# w1 i, Y                                @,root.eventcontroller.simTime);. `5 G2 X/ _2 d1 ^; T* |
                        @.HasOrder := false;" h  q! g) S" W/ P% k" o
                        @.DrivingHome := true;
' ~) ?" u$ _. G$ H7 L0 G                        rgManager.tryToStartTransOrder;
5 J/ J; P8 u8 B8 {  j                        if @.Destination = void$ q) Z. r1 G5 [! D. n
                        then -- no transport order for vehicle @; @3 y$ F0 C8 F1 M
                                @.Destination :=6 c/ G" D( z9 n
                                rgManager.nearestFreeStation(@,track.~);
$ Q8 {" Q  q% d# r+ i( ~                                newDirection(@);   0 r3 O- z  u% y% K
                                if @.Destination /= void then
1 V* r$ t; |. b: G8 a                                        @.Destination.NumReservation :=
# m# ~3 y" c, D4 T% q                                        @.Destination.NumReservation + 1;
/ H7 D4 m: E& F; Z  O6 t3 q                                end;
" Y' g0 ]' Y, ]. ~                                @.CurrIcon := "drivingHome";
) z9 q' q$ d5 k- W. a" e* u4 p                                @.DrivingHome := true;
$ ^% ?5 s6 A3 J( f5 E$ }                        end;# P) L' L& z! \* @, e: H
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
- T/ k. E* i5 T  M% n# k                        part := @.transpOrder;
: |  I- M; F  [( ]- A, l: P9 j                        part.move(@);-- load part
) o+ x) ~  @( w2 [                        @.CurrIcon := "load";5 T$ c/ V1 @  t! T
                        GlobalDistObj := part.globDestination;
! l1 \8 Y; Q: y  W; Y                        assignLObj := rgmanager.rgAssignL;3 _# F% z/ X+ u; l. }1 L7 G0 z( Z
                        row := assignLObj.getRowNo(GlobalDistObj);; O3 `6 R' j! E7 v, F# l
                        if Row = -1 then -- since 70
; ^' _; P% u. X' ]0 u                                if lan=1 then  {2 Q# ]3 r9 j) o
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),- D3 r$ T9 {) s" x/ R
                                                to_str("in der Andockstation: \"",?.~.name,"\""));8 r; l7 e+ P& [# \, C
                                else2 d* o7 e% b, ], @
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),; Z8 l* }0 l+ O* U
                                                to_str("in docking station: \"",?.~.name,"\""));                                + _1 l7 ]+ M8 m
                                end;
5 J4 j+ n/ l8 R0 w: N# r1 n2 O                        else
( W9 j# c9 Z! f1 z* L" m0 F                                @.Destination := assignLObj[1,row];
& v; m$ C) h' f                        end;                       
5 w  o0 ^0 T2 j) |                        newDirection(@);
" E9 S' C7 n. Y+ `2 M) _* B                        @.HasOrder := true;
+ d1 p: h' j" ~5 h$ [0 {$ {                end;: e3 v6 E6 u1 ]  R# E
        end;5 B& F& ]) E/ s
end;        -- of the method& v7 b/ y# G! T2 a) o* V. A
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 " U1 F1 g! w) a1 D2 E0 N& r
4 o' Q: I# ]! q9 v& M6 _9 M$ I8 {
这是AGV_putin中arrive的method。
* q( D) z# U  L' N# _3 \6 N1 K( M. D4 [. F' g
当到达物料速度越高时,这个报警更多,
5 p( J0 D( K) X6 ~! T可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。  p6 V' u% ~1 h; [# K2 Y6 x
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
$ L7 E6 D9 D7 Y$ \; b* k
# X6 T, w6 @  U1 g, l' Q- \) X另外一个小建议,就是move,所有的move都可以这样
: |" ]% i- b' R: ~+ Lif not move() then debug end
4 W4 m7 A" s9 X这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
. I& o; u, r9 M6 m# p* qplant simulation中的free libraries有AGV模板,+ E' V5 p# ~) T
里面也有案例。! Y( w  M4 S) }7 Y
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
5 F) Z+ F# r. i
5 }+ p2 ~) Y( G: [! C  @3 m1 w我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
% k8 C0 T8 D; p) B. n+ j: m0 h  b9 M% g% C! I
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 * v9 [9 ^7 h) p' W& I
这是AGV_putin中arrive的method。
- r& i+ s( B" s5 N
4 u7 h) a; X8 f6 }% X, v; J. D0 z当到达物料速度越高时,这个报警更多,

/ U% m, q/ g! X* l  x另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-16 20:06 , Processed in 0.014644 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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