设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8495|回复: 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'
) a0 T& x& ?8 [/ @7 N*/: I9 |, Z8 r- G; _. E- _& d- n; f
is7 V/ a* U& b, W$ H; O$ m
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;/ M  A# y* Q, z4 }* j
do
, Y( l8 `* V1 B  P5 _7 n6 {" ^        Lan := rootfolder.Internal.Tools.AOLlanguage;
8 ^8 b! c6 d, z; ^! s        if current = @.Destination -- else return
, Y: ], ]" D: H+ i        then
' `4 }/ c1 {* b/ c6 t7 k                @.Destination := void;# v6 j* @& `$ B: ~$ D; B
                if @.occupied then
6 [+ }/ _3 s9 F                        part := @.cont;
; u% T: O5 q; S" I$ U! q1 }                        @.transpOrder := void;1 v* P/ Y, f3 v7 M; I
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
& d% {2 N& e2 J                                @,root.eventcontroller.simTime);6 K+ j; H; {3 S  ^1 h9 u/ L
                        @.HasOrder := false;* \( b6 x3 \, x# K
                        @.DrivingHome := true;9 A$ z$ ]; \, v7 [+ y
                        rgManager.tryToStartTransOrder;
7 \. @8 \# |, b1 Q7 l                        if @.Destination = void) D: K2 B2 ?  I/ S5 _
                        then -- no transport order for vehicle @" G# G$ S6 o7 _1 P% J
                                @.Destination :=8 w1 }% q# W( o4 \( h2 Z
                                rgManager.nearestFreeStation(@,track.~);" l  n; |) j, j  [; ^  Q
                                newDirection(@);   
. z+ k5 Y* E8 C! n: g5 {6 _2 ~                                if @.Destination /= void then; z9 e* b7 Y6 Q% Q4 k; h/ q
                                        @.Destination.NumReservation :=, Q, T3 @( }! A! P/ B! S4 j
                                        @.Destination.NumReservation + 1;
% w, g1 l/ _9 A1 t$ w0 U- |9 g                                end;: q5 {$ k# g& D! R' ]( B6 m
                                @.CurrIcon := "drivingHome";
- o& V( {0 [* r. n! c                                @.DrivingHome := true;3 o& t- K9 O6 r) V
                        end;: l4 }! h$ {; N- g
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station' p+ ^" p% {8 m( J$ Y8 Q
                        part := @.transpOrder;
( \5 K, \' p4 n" _                        part.move(@);-- load part. _% b" j- _( v& z1 q
                        @.CurrIcon := "load";
8 S% @1 a5 u. z  ?5 F                        GlobalDistObj := part.globDestination;/ m" i% W) W8 q. {
                        assignLObj := rgmanager.rgAssignL;0 q9 ], A& d" z+ c% Q
                        row := assignLObj.getRowNo(GlobalDistObj);; Q7 V: I; M% L0 z, W* \0 _. N
                        if Row = -1 then -- since 70
: p1 G: W2 M/ `                                if lan=1 then8 {2 Q9 J* O5 T5 k" o8 R" p
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
) n0 {" @$ D8 I, h4 g. f  v2 V& E! |                                                to_str("in der Andockstation: \"",?.~.name,"\""));- i! d, [9 a, ~7 ?
                                else
$ z3 Q# i* N0 W                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
) U2 z: `& G( I( J( b                                                to_str("in docking station: \"",?.~.name,"\""));                                3 z$ U9 q+ g* A( o# l
                                end;
: z0 _8 L, Z/ ?- O  S. Y                        else
- C( R1 r5 g$ C) I! d                                @.Destination := assignLObj[1,row];
$ R/ y* T! o" O! H& y                        end;                        # K7 j6 a, S# _
                        newDirection(@);3 ?  P) K% K( ]2 w3 G0 f5 i2 q
                        @.HasOrder := true;
% o5 L, K3 ]1 S  x2 I" z                end;( m+ V1 K3 _2 D* ~( A; [. E
        end;
. h" P* Q& E, ~5 tend;        -- of the method# r9 i6 [9 E9 C; H9 Z  a
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
* @8 o7 g4 f# I( _6 q
& [. l! G  V4 H4 C0 Q5 I这是AGV_putin中arrive的method。' u' F! C2 g# B7 c# Y  F( D

) z7 c; J8 P4 ?: Y. z4 e# K当到达物料速度越高时,这个报警更多,& e; f4 O5 }' N8 Y& l
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。$ k7 c$ X! U+ G+ G$ z( i
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
, `. `* L3 k0 F9 `$ q' Q- \, B) r' h% w5 c' J0 H% `
另外一个小建议,就是move,所有的move都可以这样# o& [3 m6 \! U$ ?9 ^. T2 }/ B5 S6 ~! K
if not move() then debug end1 v8 z$ @9 J& D+ B+ u; K, Y
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。* @4 O0 D+ A2 n" t9 d
plant simulation中的free libraries有AGV模板,
- E: a7 s& i- z0 y里面也有案例。
: R: q5 T- W( B* ^" S% E我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。7 Z& d" y" X) o/ u: t) U3 ~- p; k

: W; I# e+ Y( J0 c" q3 C7 \我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
9 s: O7 N- \5 e" c6 V/ n
, U0 V% h' [1 r5 C) \那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 7 f$ I2 i( G0 l
这是AGV_putin中arrive的method。
6 \; t  V; q# e% H4 c) X
! L; R, {" b. \/ a- S: W! o当到达物料速度越高时,这个报警更多,

# C) p) e; ^3 M# U: {) {另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-7 12:34 , Processed in 0.014315 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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