设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6479|回复: 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'
  D+ Z7 C3 |+ {. `1 u3 T' }*/
7 [" X: C. d) O/ Y" h1 ^is' P4 E8 @+ ]* `, C" ]
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
% O' [5 w1 u5 a% h' I  ?do) o' J/ M9 P& M" o' V" N9 _6 m* g
        Lan := rootfolder.Internal.Tools.AOLlanguage;
3 R5 u" n1 v% ?% G! v1 c6 x$ Y9 {8 ^4 d5 L        if current = @.Destination -- else return4 L" }" h) C2 N6 |
        then
6 \4 J+ I" d. V& Y! P                @.Destination := void;
2 T4 g5 A$ a. ]                if @.occupied then2 M- u  m8 h  C
                        part := @.cont;
$ p6 x; d  Q! y/ T                        @.transpOrder := void;
4 H; E0 w( O; K                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,- f1 B- R. N2 U2 n
                                @,root.eventcontroller.simTime);, M% S7 [$ c5 w- @3 U
                        @.HasOrder := false;
. \: M3 C6 ]* j6 M- ^+ ?9 A                        @.DrivingHome := true;
' m$ a% ^, c$ F% Q6 w  m                        rgManager.tryToStartTransOrder;
4 h2 U7 c+ q& I; z                        if @.Destination = void
" S* ]+ T, G; h/ O5 i! z' s0 t                        then -- no transport order for vehicle @2 P. L: c  _3 h" A2 J
                                @.Destination :=& p% [) t6 u6 R6 O2 P. O
                                rgManager.nearestFreeStation(@,track.~);; a+ G5 @2 C8 t2 D1 }0 f
                                newDirection(@);   ( _& P& ?, P$ d4 u5 P. X
                                if @.Destination /= void then
1 ]5 \% E- z; G6 M$ ~7 H                                        @.Destination.NumReservation :=
* d4 ?( k3 D" F# F                                        @.Destination.NumReservation + 1;' l/ P( z. q# S+ N- [5 L. Q
                                end;) }$ P; Z. _& x8 P+ Q( Z2 f
                                @.CurrIcon := "drivingHome";
7 z. V2 ^' X  M" Y/ V, X1 T                                @.DrivingHome := true;0 g- I, C! P$ E# ?
                        end;' h* P- B7 M. d/ E- z
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
0 M3 z* Y" t& C                        part := @.transpOrder;
* _) `) i  J' }. ]# D                        part.move(@);-- load part( z' R" u. n6 C
                        @.CurrIcon := "load";
2 B0 q, v# ]3 b( m                        GlobalDistObj := part.globDestination;8 Z8 |; t4 q* L) b  |' F6 Q" b
                        assignLObj := rgmanager.rgAssignL;
1 ?  A2 V' a, A$ [6 \$ V: i                        row := assignLObj.getRowNo(GlobalDistObj);
: c' W$ P6 E* M6 \$ C" V- k                        if Row = -1 then -- since 707 K' [" D$ g& {, Z- Q
                                if lan=1 then
  E. j5 e. i1 R0 G                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
9 I8 ~% F8 w. ^8 E3 l3 d+ ?  g3 f                                                to_str("in der Andockstation: \"",?.~.name,"\""));6 z. \6 q$ N, U7 H$ \/ ^
                                else7 P* a; K- g& @& _. }- d6 Z. [* n
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
) ]. h3 U* |4 K$ T; _: j                                                to_str("in docking station: \"",?.~.name,"\""));                                5 f$ N+ y$ k  W2 `" A7 M8 |
                                end;5 Q9 ?. f% P* a1 e' D
                        else- I- E4 }7 Z2 p
                                @.Destination := assignLObj[1,row];& J- @; ~; G) R# V  p4 }4 ^  m
                        end;                       
$ L! d0 S3 o# d% C                        newDirection(@);
4 P# h4 ?( h- @9 \; A                        @.HasOrder := true;
, @& l/ o. F0 q                end;
' \; v* X6 k+ v! a* A" {- C3 k        end;4 Z. [$ j4 p! B: W2 U4 u( }
end;        -- of the method1 A1 x( l7 P/ J- ]
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
  A% U% _& G& a1 z: E2 \# _2 U! v
8 e$ p" x/ J" t/ W* }* Q, c; e这是AGV_putin中arrive的method。( u4 v; x8 r& e( h9 X' q3 g$ S

+ T( [9 O0 e8 \# Q9 Q$ }当到达物料速度越高时,这个报警更多,+ [1 Y+ }1 C1 F3 R5 x9 d# `" l
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。6 G2 _1 V3 `! H& @9 T" _
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?4 l# |: h4 Z7 B0 J7 |9 ]$ f' O
. p$ m2 _: g2 c- {" w, c
另外一个小建议,就是move,所有的move都可以这样
3 @* {$ x6 s( N: I- P1 dif not move() then debug end- v$ {1 W8 Z, Y$ w
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
$ r  x' c, f9 I* E. {# Iplant simulation中的free libraries有AGV模板,
; o4 h& ]( K6 A7 |9 o! ^里面也有案例。4 z* ~/ _: c- _8 J, h0 Z. W1 `
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
" `- L5 Z! H" q! w# p( l5 m1 u0 ]7 K$ L: Q3 m$ r
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
- ]7 Q+ {, A$ p( {; B/ N: ]  D+ c! [7 ^
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
! {9 k( L+ e/ W( v& z这是AGV_putin中arrive的method。* b* m% P2 {$ w! b, n9 u
3 E" f* o0 d0 O
当到达物料速度越高时,这个报警更多,
1 k: F4 K4 \/ v1 X5 X
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-9 05:44 , Processed in 0.020794 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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