设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6001|回复: 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'. K# P- }4 q0 @8 A- i2 y
*/) C" r* }7 b7 T! e! z6 @
is
+ r" T6 C( O7 K6 L& [        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
. f( C+ C3 E. M0 H/ ~$ b+ _2 E( Ndo: D4 k0 Q7 k, T3 @" h0 _) V. P
        Lan := rootfolder.Internal.Tools.AOLlanguage;! J. Q( y: @$ t& z% V1 n9 m- `
        if current = @.Destination -- else return$ K- [5 F8 c( {" v
        then! g# t5 ?* `$ x0 o  W
                @.Destination := void;
8 ^  i+ s$ x) Q! b! Q' `* O                if @.occupied then! x6 ^% z7 F7 W2 C& m0 c
                        part := @.cont;
' N5 N. u- N; H/ c4 s2 ?                        @.transpOrder := void;. p' l! R' G3 n2 U7 O
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,1 r  d8 T& Q5 C& g1 W  y
                                @,root.eventcontroller.simTime);
: ]0 R, Q4 s1 B; X1 ^                        @.HasOrder := false;
& R3 }3 ~* a8 J# n" o3 V                        @.DrivingHome := true;, Q. V9 l* l# ~5 Z
                        rgManager.tryToStartTransOrder;
  S) `7 f! e; c3 ?) U$ q                        if @.Destination = void
8 x* ?0 w- H0 \$ z$ C                        then -- no transport order for vehicle @1 w& U+ N5 s2 b2 A
                                @.Destination :=
7 k/ ^0 G& ?+ q* T                                rgManager.nearestFreeStation(@,track.~);: V5 c5 u- R5 ~+ i0 _. `/ k
                                newDirection(@);   7 B: a0 {6 b0 f1 g* e2 z
                                if @.Destination /= void then7 o( n4 B& ~! D4 Z! E
                                        @.Destination.NumReservation :=: G& \( B/ G+ n* f5 C$ r7 V7 n
                                        @.Destination.NumReservation + 1;
5 e% b+ N4 z5 \" O                                end;
6 `" e) E+ N$ D' }* v                                @.CurrIcon := "drivingHome";5 j1 W" {# H- K  ]
                                @.DrivingHome := true;2 e& l  U9 R' N0 _3 ]( C2 o8 K
                        end;% R, q  X# X$ p; o' m, n
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station' Y8 p4 q! @% T1 `; }
                        part := @.transpOrder;2 ?( @& A6 ~! M/ [6 v. }
                        part.move(@);-- load part4 I( M8 K9 o/ }) ]# A: o$ Z
                        @.CurrIcon := "load";9 x7 w! l+ P3 U! a. E# l
                        GlobalDistObj := part.globDestination;
2 y5 D" F& ]4 j/ T                        assignLObj := rgmanager.rgAssignL;8 o2 Q2 F2 H$ L5 f$ [# R8 X* V
                        row := assignLObj.getRowNo(GlobalDistObj);
9 B7 Q1 i3 D: i% }! L* D                        if Row = -1 then -- since 70
& D, b  [# S- Y5 H  b7 H: o0 g                                if lan=1 then
& {( q5 C* s% _3 i; D$ z+ n6 @3 c                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
6 S# u6 X3 E; V$ t' V4 O                                                to_str("in der Andockstation: \"",?.~.name,"\""));# }/ p! p! i- P+ ]
                                else
' ~) U; r) c5 [- e7 c' r                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),( I& v, Z8 z0 [/ z4 M$ o
                                                to_str("in docking station: \"",?.~.name,"\""));                               
9 ?8 Z5 A7 x, u5 e. S                                end;
7 s9 W% Z2 c0 l6 H  E5 r! C                        else
4 o' M* V4 q+ E& w: M9 C( h                                @.Destination := assignLObj[1,row];
) S  \; u: p$ u; Y                        end;                        # _5 R5 E. B& `$ P9 x
                        newDirection(@);5 [; z# I! F2 i. _. S7 l
                        @.HasOrder := true;
: {0 x. O: v1 d                end;
9 f8 U, p/ j- X2 R1 O1 G* ~) U        end;' u1 {( n* o7 M% D, [: U7 M5 T6 X: ~
end;        -- of the method
" I# P8 Z. C. D9 n' a
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 + e$ ^8 t4 x' [! \- T8 L! B

/ U/ x' E5 O. l* d8 W6 \( B这是AGV_putin中arrive的method。( `" A$ g# g8 I! C
# \0 f+ A/ D( J7 E( @' p0 ^/ S1 w
当到达物料速度越高时,这个报警更多,
/ w% L( Y) x  j$ m$ S, ^- [+ {可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
. i9 O6 o# |4 g9 V1 X程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?8 `, l! \" ^. Y5 S+ p3 D/ h4 y4 h

( Y, \/ S9 ~0 ?- a另外一个小建议,就是move,所有的move都可以这样) V/ v8 V2 F, D3 u/ {; Q( k# w- }
if not move() then debug end# P7 d9 C6 H1 S
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
' E  v( d4 p/ D; b% Vplant simulation中的free libraries有AGV模板,
* |3 b4 ?& S& R7 C' \里面也有案例。
6 H8 ~% ^( c  D4 j9 y我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
! f! s, B& y8 ^6 u3 i$ [) g! D0 [# R) {4 O  O6 u( K
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 * [" t6 Q' @" M+ ~( x: u/ F

: A" ?) R  M% T那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 # w! F* q' u' e0 `, Z
这是AGV_putin中arrive的method。
0 h; a2 i& a8 _9 Y  H0 P4 J4 D- q' ]7 S
当到达物料速度越高时,这个报警更多,
0 l+ x( g& u1 ^
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-12 07:04 , Processed in 0.020328 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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