设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5444|回复: 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'
( {$ D7 H/ m# A*/: Z2 R9 ?( a8 Q9 D1 r5 \
is
) y6 i/ ~$ e% @: Y/ M6 M        part, GlobalDistObj, assignLObj:object;row,Lan:integer;' C4 ?% i  `0 _
do
4 u6 s, U. R2 y1 B' H- D: A* ~+ t        Lan := rootfolder.Internal.Tools.AOLlanguage;* ~' k8 Z6 X3 s2 h
        if current = @.Destination -- else return/ ^: j1 l- Z" G0 x! u
        then
1 F. [9 Q! g2 h2 ^' m# R                @.Destination := void;1 \! g& L8 u. E* _3 h6 r" g9 k
                if @.occupied then
6 K7 S0 I2 i2 ?& _$ m# E8 f0 p                        part := @.cont;2 K0 P! N+ B  q- z' j5 H
                        @.transpOrder := void;* J; o4 |, I0 w' T" Z  \7 ]
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
* ^# m7 ?$ I! L/ ?                                @,root.eventcontroller.simTime);0 V' ?( i% X" }) f4 N% D
                        @.HasOrder := false;* m, t0 P9 Q6 Z# K  x
                        @.DrivingHome := true;$ ^8 @( g  i' m& f) E
                        rgManager.tryToStartTransOrder;
- i) O# g0 ^8 a3 _" y                        if @.Destination = void1 ^! G" X$ w$ t! W6 |
                        then -- no transport order for vehicle @( _+ T' D- B* A. T
                                @.Destination :=. a; v2 b7 }# v/ o$ |. u( U$ |
                                rgManager.nearestFreeStation(@,track.~);) X' w" Q0 o5 q: I$ O
                                newDirection(@);   
4 K' H: S# x  G2 U                                if @.Destination /= void then1 Z" p7 v* `( \: O8 g& B2 ^; e
                                        @.Destination.NumReservation :=& }9 Y' e, n7 X: T3 ?4 O2 A
                                        @.Destination.NumReservation + 1;! Z+ B& e+ _5 C+ p- U
                                end;" b2 C% ]! `0 s6 A$ L  C
                                @.CurrIcon := "drivingHome";
! [$ Y, t6 S1 f* P. @9 v6 U/ A" N$ X                                @.DrivingHome := true;
+ F+ {, s, N* l7 T0 N                        end;
- y8 p3 [& A" J                else -- the vehicle @ is empty, both vehicle and part are in the same dock station  l, K1 t" m' N$ M. V8 g; ~
                        part := @.transpOrder;! @8 N; v% C( C9 i* `% Y
                        part.move(@);-- load part+ U6 e! [: _% b6 G& T8 p- Z7 d
                        @.CurrIcon := "load";
9 e/ E3 o0 U" W  t                        GlobalDistObj := part.globDestination;2 K$ h6 I; R  R; B, B
                        assignLObj := rgmanager.rgAssignL;
* N/ I* Z+ g' C# P                        row := assignLObj.getRowNo(GlobalDistObj);" K2 M. Z" Z/ ~5 M0 ?1 k: I3 B" g
                        if Row = -1 then -- since 70, x  P7 s! [) a) o/ y* L
                                if lan=1 then
6 m5 g' A0 q% D* Q* d                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),0 p/ v* e; h6 ~4 N' x
                                                to_str("in der Andockstation: \"",?.~.name,"\""));. J7 V3 C$ _3 J, D9 B- ~
                                else3 I6 }2 U* ]8 u. Q
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
. @/ S2 h: f) y7 {                                                to_str("in docking station: \"",?.~.name,"\""));                               
9 G5 T, L# W2 j+ h; J6 O" x0 C                                end;2 f$ k0 }9 X& [: s6 {% c" u
                        else
: w9 A- R* N  _& @0 ~8 L                                @.Destination := assignLObj[1,row];
6 ?: `3 C" h$ l! \0 R1 n                        end;                        0 U* E. w. a: e4 \& n
                        newDirection(@);3 {; l* h2 s$ e! {( g
                        @.HasOrder := true;/ O4 p4 l- g7 [# j( O9 W
                end;+ b0 I2 H3 j( c; T2 f0 y
        end;
8 c% a6 v3 _2 \* e# J: Yend;        -- of the method
/ ?- J2 T6 k2 V/ N, m9 D
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
( W" l2 j( H6 K- b5 O. `* a9 }5 t- y2 _0 u: z* S* B; O9 N
这是AGV_putin中arrive的method。+ R8 ?+ ^% Y- X7 q2 G" G# d& S
" v! \, s$ e( p
当到达物料速度越高时,这个报警更多,5 q  y1 n& Y3 o& f* X" S) F! `
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
3 m+ s. \0 X) E' @程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?- ^& a5 o6 `# @3 o. |4 l6 Q

8 x( ?2 K! F3 R, N3 y3 A另外一个小建议,就是move,所有的move都可以这样
) \3 a. o+ F# t; Y% Zif not move() then debug end
) V3 c: i0 j5 C% q4 ]5 l这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
; y. `  E2 ~" }7 `& K" j) Dplant simulation中的free libraries有AGV模板,3 _8 x0 s  W/ c" }' l: f" ^( w1 l! B
里面也有案例。
2 f8 }4 i1 X* M* K  _& I我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。7 q+ E  J" g, D5 K0 t2 E8 z

: d+ z; S4 K5 C1 p我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 & m7 T/ W7 ^* ~# U6 z
' F% x; j3 v* n3 k5 z+ M
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 " A  Q- o- K* \3 F* ?: t
这是AGV_putin中arrive的method。
  S, L: A- W; e  L) C( i& \
1 N: k9 Z# n* z& u5 S$ t. f' J当到达物料速度越高时,这个报警更多,

" Z) R# ~9 \1 P2 r7 m6 Q另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-11-24 10:42 , Processed in 0.018618 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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