设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7287|回复: 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'( f' D4 Q# C& v
*/' \  R" n- J, l1 t- k
is
8 L$ E. O4 J: g) D5 V        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
" m+ P" K8 l& H; d) t$ n2 E0 |do8 ^, J5 P' F, O, k2 O  n
        Lan := rootfolder.Internal.Tools.AOLlanguage;! C! _9 }. @& x6 f5 S& F. {
        if current = @.Destination -- else return
5 ]1 g: p' v* E+ C; G$ d        then
1 @2 r4 {4 u( b/ |- f  q! f' `, h                @.Destination := void;$ Z9 s0 k2 h, h+ ?8 z" H9 u# p9 M
                if @.occupied then4 c" K  N' Q2 x
                        part := @.cont;
$ j+ w! u  X. H% S7 `$ N- b                        @.transpOrder := void;: k- O1 W# v; n( Q2 A. y
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
8 }4 G* l( M9 w! M                                @,root.eventcontroller.simTime);
% s; l/ i# F7 J0 ]3 D0 ~# [5 U                        @.HasOrder := false;; k7 b* l7 g# r( x. S$ c( c  ^; G& _% X
                        @.DrivingHome := true;7 b# n/ r: y% b
                        rgManager.tryToStartTransOrder;
* f' d  X5 |: |$ r& R                        if @.Destination = void% p7 C5 w% h* |$ [+ Z
                        then -- no transport order for vehicle @
; X% ~6 K" ~. a: t7 z# T# a  h! t4 @                                @.Destination :=
) P. h! P* \* l$ Q! W                                rgManager.nearestFreeStation(@,track.~);0 y# `) e2 X8 ~; `
                                newDirection(@);   
& a' O4 x1 @5 x/ s# Q+ T5 u" _$ j, x                                if @.Destination /= void then0 {1 N0 _5 i8 T9 Q' p6 |, [" g: y
                                        @.Destination.NumReservation :=% P% R0 D$ D& S0 X: s' F% |; N4 m  }
                                        @.Destination.NumReservation + 1;
" b$ v3 W" a) f" Y% D  G. x                                end;
$ ]+ Y  v, Z( g2 m3 o2 f. f; @                                @.CurrIcon := "drivingHome";
7 O, Y. c2 S. Z# Z3 c; _  O                                @.DrivingHome := true;* u5 w: p8 X) \
                        end;
! n  j% r# M- m& N  x                else -- the vehicle @ is empty, both vehicle and part are in the same dock station, \/ R- X2 j2 ]4 f! D
                        part := @.transpOrder;
" r/ d8 {! r+ H/ [  m                        part.move(@);-- load part# L2 ?( W8 ?; L# A& C: H4 T
                        @.CurrIcon := "load";/ Q0 @, s4 o6 b: F; X3 }; ~
                        GlobalDistObj := part.globDestination;
: K# _) U  p& K: i5 g/ n                        assignLObj := rgmanager.rgAssignL;
" K+ }+ G8 y+ d8 n. m                        row := assignLObj.getRowNo(GlobalDistObj);( ^5 M* u  X6 e
                        if Row = -1 then -- since 70
1 \0 w, P0 H- f0 d/ w7 g" H                                if lan=1 then
8 G- J  E/ m3 c8 P! s                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),  t' j; S1 [; z3 d7 X) E
                                                to_str("in der Andockstation: \"",?.~.name,"\""));+ b: n3 d8 y* `; z( C
                                else7 E9 D7 F8 h+ ?* m" J$ T
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),- ?$ G5 V) b9 h) y4 \( f- r+ b5 P
                                                to_str("in docking station: \"",?.~.name,"\""));                               
/ v, g: V6 |2 ?) o                                end;: j4 i1 |% a& K7 b2 K9 L
                        else' ?! |5 y, s3 _$ M. Z5 |
                                @.Destination := assignLObj[1,row];  N+ Z' p1 U: V. a* r6 z
                        end;                       
; K, d4 z# V- v* `2 S5 v3 v& J                        newDirection(@);
- k+ Z/ U, B* D                        @.HasOrder := true;
7 R6 n6 u1 ?$ n, p/ c2 a                end;$ Y; k. W2 c& B6 C% n
        end;2 ?4 s/ r4 K0 o' D% K! o% T
end;        -- of the method
5 e9 c0 T* y, l; T# f4 I6 u
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
. N& i/ ~  u8 e- {; X0 u( ^
+ Q/ `( R  k/ `' C8 v这是AGV_putin中arrive的method。  B0 y% p7 Y) i' h
4 ^! N' ?1 t! j' F* D
当到达物料速度越高时,这个报警更多,
$ B* C( t9 q; ?. w可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。5 \9 [# R+ _4 ]. X  k
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
3 a( a% p! c* o( a! S$ x4 x) V0 r/ k6 b+ W+ P6 H9 S
另外一个小建议,就是move,所有的move都可以这样* r% X, H& J: G  ]# n+ V
if not move() then debug end4 b+ }0 @. I( Y
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
$ l7 M& E9 J7 l/ [4 m0 eplant simulation中的free libraries有AGV模板,
: r9 Y0 s, H* l里面也有案例。
; r; t% v, Z7 Y, O& D我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。2 s  ?& n( m) J
9 l, l; E9 n! v. A8 ^
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 2 J5 \! o2 C& s

4 K+ P  O4 X, t- N+ G  d5 d0 [- C, ^那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 4 t  }$ L7 f( s1 T* O
这是AGV_putin中arrive的method。
! a( s8 {& r+ Y! B& W
, \, C7 c; _& Y  ?) @7 \当到达物料速度越高时,这个报警更多,
4 y. P, c  H: A1 n: C
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-1 22:53 , Processed in 0.020087 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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