设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5637|回复: 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'
; S0 ?9 `7 `7 K: j$ L*/
4 H* [4 Q7 I+ `! ]- P# tis) Z* x& [: V; z1 \' Y6 y
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;2 D1 I; K$ Q; F+ d" d7 Q9 y
do0 }( P4 q5 `% z; J1 {- l7 o2 x3 Z
        Lan := rootfolder.Internal.Tools.AOLlanguage;) @/ B$ v. }% @1 d
        if current = @.Destination -- else return
* `) L5 L* f. W4 T% z2 F        then
) P5 |/ n# F; v# l( f0 k                @.Destination := void;6 e5 V( j0 a% [  o
                if @.occupied then
4 b7 x/ V) ]7 B2 m+ P8 n                        part := @.cont;" \2 r% W, }& i3 e
                        @.transpOrder := void;3 q( w( @1 g+ H- T. }' ^
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,* l& S  H# s' }% ^; b6 `: m
                                @,root.eventcontroller.simTime);+ y& c/ O0 \3 S) A' M6 [
                        @.HasOrder := false;
: V7 _7 R3 s( Z2 `2 e* o                        @.DrivingHome := true;
; B; I0 T' o" k" {2 g1 ?9 h                        rgManager.tryToStartTransOrder;
  z  X9 a) Y0 ^+ d9 S                        if @.Destination = void- i5 `8 g' [) s2 C0 R0 l5 Q
                        then -- no transport order for vehicle @9 Z% M) k3 M2 s- _+ `$ r
                                @.Destination :=% p7 R4 K7 ^. r! W. M9 G
                                rgManager.nearestFreeStation(@,track.~);- P8 R% h9 O2 }
                                newDirection(@);   9 p' B* c/ m7 V- H( S
                                if @.Destination /= void then
- l( C! r, t4 m$ W8 ~                                        @.Destination.NumReservation :=
# ]! T. T$ v7 K  V* _8 U5 B- L                                        @.Destination.NumReservation + 1;
% a. @2 s8 ?5 |: \1 |                                end;
& i1 s* B& b9 u* K" O) P8 ?! l* \                                @.CurrIcon := "drivingHome";5 U! N1 M, W  Q* A5 j
                                @.DrivingHome := true;- {, m" K1 d2 O- E
                        end;
' i( e& r1 x% G                else -- the vehicle @ is empty, both vehicle and part are in the same dock station* r: o: o  c) r
                        part := @.transpOrder;
# ]- n6 S' n* G! ?                        part.move(@);-- load part3 w1 n7 n5 g# Z
                        @.CurrIcon := "load";$ @1 z& p" F9 D. W5 t( O
                        GlobalDistObj := part.globDestination;$ {5 ]6 {! a4 ]7 d
                        assignLObj := rgmanager.rgAssignL;5 Y+ e. z$ h* p8 J2 h
                        row := assignLObj.getRowNo(GlobalDistObj);
5 V0 y1 I/ \! [, N8 _+ c2 Y% Y                        if Row = -1 then -- since 70+ g1 _% _! j- ]$ R- r6 I% @
                                if lan=1 then
: O2 U& p; t. A0 p" q                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
4 X- U* [0 a/ J7 c0 S                                                to_str("in der Andockstation: \"",?.~.name,"\""));: R% M* |7 Q% ?& f& ~
                                else
6 Y' E1 N% P- h' i# I" L* ]9 ~* f                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),7 ^* a) Q5 L$ V$ ]( U
                                                to_str("in docking station: \"",?.~.name,"\""));                               
/ S+ P# ~4 K9 l7 l) w                                end;
8 ?- w4 Z% G2 s0 Y                        else' ?  [% @0 {; l! \8 R/ K3 e7 p
                                @.Destination := assignLObj[1,row];+ `4 M) s. V1 J7 l9 t+ U  M
                        end;                        + T( Z3 X7 }* {. Q& p$ v! ^0 ^' J
                        newDirection(@);% k: M, F* A+ R2 x2 _9 [* P
                        @.HasOrder := true;
; g! o' V' J1 A0 n" W; j                end;( t: @6 s9 m! G6 N4 ], K$ U
        end;2 c; a4 e* v7 [. P5 ]
end;        -- of the method
4 F0 ^3 _0 n7 M3 R/ W* n' f
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 4 |' O) k* Q& ]  y2 g% I
+ H- U. O# Z. q1 l! q7 F
这是AGV_putin中arrive的method。
- T$ L6 `$ S6 O: _1 I6 {1 b5 c+ F; o
0 O; N  ]2 A# _$ _4 K+ n当到达物料速度越高时,这个报警更多,
+ j1 W5 @& V% J8 o0 P可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。' n' O8 ~4 P9 `% u  R
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?1 Y$ o- m& ^  N5 c0 @/ ]

' q/ l  Q( n" f0 ]9 u6 a. b另外一个小建议,就是move,所有的move都可以这样0 u6 e7 r  n, K0 P1 V4 D! A
if not move() then debug end
! _0 i  B! E' ?, V4 ?这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。1 d% s( r0 q  p0 `  O# j' W
plant simulation中的free libraries有AGV模板,* j3 n3 V% a- h& t
里面也有案例。
" l1 m) Y( |8 X& P# Z我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。5 L4 w% H( G1 w+ Z- T

4 r$ i0 C0 e8 [. |我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
" B1 Q/ ]! {4 u% A* g
, Y, \$ B4 f- Z1 r& f那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
/ p8 |& m! S  F% I8 x  H这是AGV_putin中arrive的method。$ P# |+ e- E( x/ e

  o! w5 s" K+ k" {- z' ^当到达物料速度越高时,这个报警更多,

$ M! I" q+ E( `" s7 A7 p. `0 k另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2025-12-10 18:56 , Processed in 0.017504 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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