设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9817|回复: 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', H- Z/ |6 f5 u2 K8 ~$ ]9 q
*/
  s. o6 Z' r! P7 |0 J# ^  nis2 |. X5 _: i6 S9 u, J
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;& d( P  x: ]- U
do
6 P9 ]  A6 |# V6 `        Lan := rootfolder.Internal.Tools.AOLlanguage;
  q9 ^' y) z: |* f5 @; k$ t6 s        if current = @.Destination -- else return* _' b! ~' t/ |
        then: u# T9 Z* j, w/ h6 @( h
                @.Destination := void;' m3 Y5 K& Q9 B+ g7 S$ D0 E4 s6 w/ y
                if @.occupied then  A% i0 i% R0 B4 K* `, ?9 ^5 ]
                        part := @.cont;
, v& x* y- g9 \: p3 x                        @.transpOrder := void;, D5 ?! b6 M0 N! }8 a/ m; [2 d" g
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,/ p9 ^4 K1 F+ R, f+ M5 H6 ]/ U! d' Z$ p
                                @,root.eventcontroller.simTime);7 H6 M* B  E# j, M: i6 j5 R
                        @.HasOrder := false;
; C% B# R, Z+ t                        @.DrivingHome := true;; z  |( d8 t4 a. s+ l
                        rgManager.tryToStartTransOrder;
/ w/ _9 b' ]2 R& C% ~! c# V0 Z                        if @.Destination = void
7 Z+ b/ @( o8 A# M; X                        then -- no transport order for vehicle @/ t. }& Y7 J, [; \( @8 r9 P! n
                                @.Destination :=
, V3 P+ I. b7 N                                rgManager.nearestFreeStation(@,track.~);# i/ g1 l+ m9 n
                                newDirection(@);   5 z8 |6 s7 [' e1 g4 v
                                if @.Destination /= void then
& r3 S' D4 h5 u. W                                        @.Destination.NumReservation :=
9 f! o4 j) k) K+ ~+ }. s) a( [* R                                        @.Destination.NumReservation + 1;
3 L$ r0 v- f/ F& E                                end;6 \; A6 G+ a3 u8 i
                                @.CurrIcon := "drivingHome";3 p3 X# p2 V# j
                                @.DrivingHome := true;
: i" h& {# ]5 W0 [; K. ?                        end;
; l! v! o4 q. w7 g6 U, ~2 O                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
  |  d' L+ H( x                        part := @.transpOrder;
  T: S/ l, D2 V- j- l9 ~2 W: E3 l7 r                        part.move(@);-- load part7 E2 S9 s+ s5 |; e
                        @.CurrIcon := "load";
6 i" a. {1 d) |6 R" d6 h& s                        GlobalDistObj := part.globDestination;  Z6 B' F7 R6 u( j
                        assignLObj := rgmanager.rgAssignL;
3 m" \0 m* w& ~8 z- q                        row := assignLObj.getRowNo(GlobalDistObj);& }! i3 ?4 q% u5 E
                        if Row = -1 then -- since 70
( B" D$ {% ]& K$ K9 e3 j/ ^                                if lan=1 then
% n' |  p6 o8 V  Z# ~                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
- W5 @3 |* S4 {                                                to_str("in der Andockstation: \"",?.~.name,"\""));8 S4 b2 L, z' i' E
                                else; d6 K4 c! ]; u( P+ |4 O1 N8 @
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
1 A( R- }. t8 K; R7 Y                                                to_str("in docking station: \"",?.~.name,"\""));                               
9 o+ g* F# c1 y" D# ^                                end;
5 T9 \6 `2 |, P. v                        else2 l+ C3 D! c# X. E1 f6 B3 D
                                @.Destination := assignLObj[1,row];
0 x* E$ [* B) e) S- e                        end;                        / K5 G  K% a" v& s
                        newDirection(@);
$ [8 G* j- h5 C1 Z: a5 ?0 T' |                        @.HasOrder := true;
0 B) a9 K0 b% V                end;
+ s3 s5 C& m% _5 z' l        end;
. Q$ N5 y9 ~  R9 }# a" ~end;        -- of the method% c5 p/ t! J; D* _: D6 p9 Q, Q7 Q
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 # e5 B7 A( k! f$ |( m6 c
  K# w) q+ ?4 F
这是AGV_putin中arrive的method。% k# {* Z% H3 g2 H8 {

7 r, p8 m% N+ Z0 h7 l# z7 h9 l当到达物料速度越高时,这个报警更多,
( D; y/ S; f+ F  I$ n9 e可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。  @$ A) m) t1 G. P
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
- {/ H: A2 G6 B( U* y# c2 {  m3 Y8 i' u* U+ A& ~4 |
另外一个小建议,就是move,所有的move都可以这样
; m3 A% x# P# e* W1 a; Rif not move() then debug end
) D" [9 P6 }' W这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。. {; u* O' ~" {; g4 m
plant simulation中的free libraries有AGV模板,8 M. i2 d, {" I& j
里面也有案例。9 Z9 V! |1 ]: n" V! K" A6 K3 C7 v/ ?
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。' D5 h( n; S# S* I

8 }( i- k( u. h) U3 N我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 # x" H0 ^6 ]5 q) l0 S5 K0 |

' j* n7 L/ @2 u0 o那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
0 |. L6 O  ]2 \; K这是AGV_putin中arrive的method。
7 ~; d6 O1 x+ ?) Z) O: V. T6 j  Y7 }0 a  c/ X
当到达物料速度越高时,这个报警更多,
5 y* _$ h. D1 ]* A( L
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-27 05:21 , Processed in 0.023702 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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