设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6934|回复: 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'
8 m0 c- \5 ~! I: d. w- r9 X1 ~* I*/3 c, A& [7 V; ^
is1 R$ M; H( Z& H9 a: X5 m+ A
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;* m6 r3 C: t. Z0 B
do
# r" @# F$ g; v8 q/ r        Lan := rootfolder.Internal.Tools.AOLlanguage;
# x' o- H4 R- @( n7 J) ~* W; K+ s2 j9 f        if current = @.Destination -- else return( C5 o$ c9 Y& ?1 Z
        then
5 ]$ ]  j7 F. h. H- ]+ Q  T                @.Destination := void;
3 N( e6 F8 Y, Q# i                if @.occupied then1 A: |5 A' w3 Q* p' d6 W
                        part := @.cont;3 [2 k! ^& t  M2 {& A8 q; K
                        @.transpOrder := void;! {$ a8 O- q. }) o0 T0 z+ ?
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,6 L- d9 l; A! J' s: \; ~
                                @,root.eventcontroller.simTime);
% V' z' b( c9 N5 y- f9 U! Q6 M                        @.HasOrder := false;
4 T# s7 u9 X8 m% j  Y# r. i                        @.DrivingHome := true;
) B5 j; u- i6 G- m& A                        rgManager.tryToStartTransOrder;; ]9 D) I0 L3 Q$ S, a
                        if @.Destination = void
! i, P3 I3 Y1 C) O0 ~) A                        then -- no transport order for vehicle @
" }/ \" n* I1 ^                                @.Destination :=
8 |; G) i% e4 O) j7 X" y( y. {9 _2 H" W  Z                                rgManager.nearestFreeStation(@,track.~);4 l: Y- m+ o3 p1 _  y! X
                                newDirection(@);   0 R' A5 ]/ n: B
                                if @.Destination /= void then* ?! M  n% G) g+ r
                                        @.Destination.NumReservation :=% d: s  Y( `, v. ~7 R4 n
                                        @.Destination.NumReservation + 1;
- `2 r0 d( W( d                                end;' v! l7 S, f/ ]8 ~) y+ f" p$ X" I
                                @.CurrIcon := "drivingHome";6 V& }4 q) z: b; j5 t
                                @.DrivingHome := true;
0 O1 X- H% ^1 J                        end;3 e4 X% c4 {6 A
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station# }& W: L* f& E0 d0 O/ r
                        part := @.transpOrder;
" Y6 I( J1 ?- |3 }  T) k( {/ Q                        part.move(@);-- load part  U3 M6 d" A% L9 v
                        @.CurrIcon := "load";0 V% N- U! T9 i( ~2 f4 |5 x
                        GlobalDistObj := part.globDestination;
  `+ S8 `- m0 V& \- W0 L, Y                        assignLObj := rgmanager.rgAssignL;/ U- Z2 \$ H7 Q$ R) H; ?
                        row := assignLObj.getRowNo(GlobalDistObj);
( h9 k0 e% U4 f* L9 X4 ]: o                        if Row = -1 then -- since 705 _/ V" {$ h, l  J/ m+ z
                                if lan=1 then- v6 n: T4 ~) v5 a8 h
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),; o% o; T0 S  s6 q5 X
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
! J$ r( X3 ~) o0 C2 t9 _                                else. J* G: p$ o( @8 v
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
5 |3 h) L: N2 _% Q& q2 h                                                to_str("in docking station: \"",?.~.name,"\""));                               
" z  ~2 ]( l- M' t: s" M, j                                end;
1 o7 [6 M% ~* U- ?6 B                        else+ s( y: c$ q6 h# Z
                                @.Destination := assignLObj[1,row];
) k6 a5 k5 B  v2 Q7 q                        end;                        - Y$ i( R& o  x. N; `
                        newDirection(@);
7 G5 t2 h" _' z' p5 b; K+ n                        @.HasOrder := true;% P) Z& j# e2 p& j# }7 t
                end;
: Z' M7 g1 L( F3 g* J! o        end;
( _5 D3 U0 M$ M. G6 w+ x1 cend;        -- of the method
" [' ~9 h! X1 v
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
. @2 Y- }) m1 q) f$ L( Z$ |4 L. N  z8 \+ V
这是AGV_putin中arrive的method。
0 \7 D. a/ c2 x; d2 ]7 ]
! K$ r1 p4 s6 L" `当到达物料速度越高时,这个报警更多,
$ n5 E, t& i5 y1 T& d可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
9 S5 V' k4 o# h8 `程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?3 H, _8 t6 s( N# K, `( j

6 n( z$ ?9 S) V/ c  k# k7 u另外一个小建议,就是move,所有的move都可以这样" ^! f& \! ^( U- f+ I# h6 ]
if not move() then debug end
6 d5 h# ]8 c: ]0 K0 U% l这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。+ a" s9 U* C. T( M7 W8 B
plant simulation中的free libraries有AGV模板,3 G5 X3 {4 A( m4 c* _
里面也有案例。
9 O' @; M0 M0 i# }+ `我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。2 j2 ?: a) t. B; t
" R% U- }* K+ C
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
9 i5 ~9 p: o9 v8 v$ J# M4 d
) [) `. r2 v5 X( ^( j那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 4 c1 z4 P. s8 w
这是AGV_putin中arrive的method。
) D! w3 g7 m# x* k
* {; o6 S* t. V5 N' _当到达物料速度越高时,这个报警更多,

! s' `! k1 ^5 Q; F( r# z* z. t3 s另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-7 11:59 , Processed in 0.014728 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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