设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9273|回复: 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'" c! p5 _1 i; S/ ?* v6 R
*/
# N2 I. Y/ P! P+ n9 Cis
: N+ W  J- u6 O: z        part, GlobalDistObj, assignLObj:object;row,Lan:integer;& E: T9 {  l: n6 ?' W2 P+ \
do
$ g# m: w. K& ~; Y5 V" D        Lan := rootfolder.Internal.Tools.AOLlanguage;: f3 q5 C# n& \
        if current = @.Destination -- else return
$ Z5 U: a* w! N' [! m        then% O7 w5 C% z* `
                @.Destination := void;7 q, ^" B% Q* J& Y6 o
                if @.occupied then2 V- a" m  e  y  \- }
                        part := @.cont;
$ w7 V: `/ b% X7 \4 d/ }1 D                        @.transpOrder := void;
; t0 B! S# y' ]; k# f. M! u                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
4 C9 d) T: M  ]9 h                                @,root.eventcontroller.simTime);
, C9 `1 a- [/ |0 [1 }2 Z+ t                        @.HasOrder := false;# \: @% Z( g% \( x& w7 ~. e
                        @.DrivingHome := true;5 w1 L) k* i5 j) A" S* Q
                        rgManager.tryToStartTransOrder;/ o9 r+ |; |) g' L1 `+ G2 R$ y, J( j
                        if @.Destination = void
( J' T- \7 e$ ]( c# j                        then -- no transport order for vehicle @) a/ k- v% t1 \0 R4 l
                                @.Destination :=
* M6 W/ r0 R1 B4 h9 H0 I$ z                                rgManager.nearestFreeStation(@,track.~);' ?  X0 o0 Y3 |4 x& t& S
                                newDirection(@);   0 I2 M0 u% p' }' N1 K
                                if @.Destination /= void then  F9 ?& _+ W2 q+ s, f
                                        @.Destination.NumReservation :=. u6 G6 R! w, [9 Z
                                        @.Destination.NumReservation + 1;
- x: u! U" Z  L% h$ y# V/ G' R                                end;8 Q3 _  J+ q/ d
                                @.CurrIcon := "drivingHome";: F) |6 x3 L* U7 E
                                @.DrivingHome := true;
7 m0 V5 ]& v) A- K! e  o) g4 m                        end;. A$ p6 A; V+ @" \& q
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
4 |" a, y: ^# d) i  e' W8 u( ~                        part := @.transpOrder;
$ r3 T  H9 |% L% c3 H. L                        part.move(@);-- load part, ~; F& Q8 `- t1 |0 b5 n2 R! P6 N
                        @.CurrIcon := "load";! O3 t2 s2 z& f) q8 x
                        GlobalDistObj := part.globDestination;
+ \1 _4 b3 n! ?                        assignLObj := rgmanager.rgAssignL;
( t- x5 k' W$ j; D, g                        row := assignLObj.getRowNo(GlobalDistObj);1 D' A: O$ d7 H# T
                        if Row = -1 then -- since 70
: M! [& |) M2 Q& S2 @" L                                if lan=1 then
5 E& `7 _5 X; R' E# K9 Z: K. q0 y                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
2 F. O' V  `5 y& s0 N                                                to_str("in der Andockstation: \"",?.~.name,"\""));% ^9 }' y& W* B2 `  L9 ~
                                else
. u8 w! [: ]4 q4 H/ \" R9 k2 N                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),6 C5 V' `( ?! o# e) f! W
                                                to_str("in docking station: \"",?.~.name,"\""));                               
; W& V3 b" T2 B" K                                end;
+ ]6 F& ~5 X5 t$ H2 ?2 g2 n. G" j                        else
+ L3 b7 ~" K; i, \8 ^                                @.Destination := assignLObj[1,row];
7 l, b- _6 c+ J                        end;                        7 g: z6 {2 i/ e
                        newDirection(@);5 r  U2 f; L0 @4 o( ?' C% O9 @
                        @.HasOrder := true;$ v! o& L- v8 D( d+ h% ]
                end;
* A0 n* G. u) U# `. B& \; }# a        end;
) n# S. P( E' C3 ?end;        -- of the method
* C: x4 N) ?' I8 Z/ N" L3 _
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ' h' u1 p) y: ]" j$ M

6 z1 U/ g* z& v; E: j- l6 O这是AGV_putin中arrive的method。' \, |9 w: B1 x7 g. n/ Q/ K
$ A# ^5 _* s8 c8 m( s9 l
当到达物料速度越高时,这个报警更多,
2 P" k: L+ c  _8 ], `" m" s/ I可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
  Q1 h6 Z' M  \3 [4 g4 \) Q$ c程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
1 _/ S% k5 i+ Z3 C  Y* p6 ~5 W
( f# N" s& C( E% ~& ~! Q) k4 @, b. q% p另外一个小建议,就是move,所有的move都可以这样$ f$ k3 w/ j0 w% L5 g( B6 {( M
if not move() then debug end
4 m% ?' I) s; }1 s% W! j) G+ f3 N这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。" c; X' P: R: i3 g" C( V; z
plant simulation中的free libraries有AGV模板,
# k8 U/ l4 g# M1 Z3 s里面也有案例。, ^( K$ `$ i0 `0 T) V) Y( U
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
/ Y& R, I" k8 Y* m6 D& q) q- K+ j# `5 a
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 ' I: }# T+ D2 e9 ~( c( F/ ^
# T. D+ J/ l8 i, t* J$ c
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 8 c) R( k+ \% n  q
这是AGV_putin中arrive的method。
1 O$ ]7 J, e( ~! B6 G" d1 ^# G
3 o& |# ]2 Y  y# Z( K0 v) |当到达物料速度越高时,这个报警更多,

* k# F; Q6 F# }1 X% P另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-22 08:37 , Processed in 0.016835 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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