设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9353|回复: 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'
# U) @, H" X: W* F" P5 U*/1 o% U. \& }0 o; X( D1 M
is# ^/ Y, G5 J9 v! ~
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
9 ]6 S7 F5 D. [! ndo
: l" v6 l* K9 W/ a6 h; T! P        Lan := rootfolder.Internal.Tools.AOLlanguage;% b6 c4 d- X7 U  A: C
        if current = @.Destination -- else return+ F9 V& C4 m! {5 q5 y
        then% t2 f0 t1 `* @; w4 i% I, T
                @.Destination := void;- @9 o4 ?3 _/ V
                if @.occupied then
$ }* M# w& R) m# Z  G. b& x                        part := @.cont;
' J: ~, M6 }: D( T2 U" _                        @.transpOrder := void;. o6 F3 I5 {5 z# }( Q  p/ n
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
) ?, V$ d0 l: T+ J6 q% b$ k                                @,root.eventcontroller.simTime);
! }+ I7 o6 r; E) \! L: ^3 \0 g                        @.HasOrder := false;
9 Z5 c3 D0 D3 d7 i7 l                        @.DrivingHome := true;
7 l3 ?/ l0 x) G" e; a# V! u                        rgManager.tryToStartTransOrder;
- t' `+ O2 \0 [                        if @.Destination = void* P2 y' ?* B8 q/ [; F8 d$ ?
                        then -- no transport order for vehicle @
- U. i! e# @8 K0 j                                @.Destination :=
5 S* o. E9 A9 ^                                rgManager.nearestFreeStation(@,track.~);
* i. ~8 t$ S5 n* \1 f  {8 k/ P                                newDirection(@);   
; S- T) B. w0 Y# H                                if @.Destination /= void then( n" e+ U8 s/ ?' U3 Z
                                        @.Destination.NumReservation :=
4 d2 ]/ a1 {3 K/ {" n/ T                                        @.Destination.NumReservation + 1;
+ p6 l, X# `, b2 U1 `4 F  G, M                                end;
9 z; `" }4 n$ F+ n4 A                                @.CurrIcon := "drivingHome";6 g7 m2 p% F0 z. W
                                @.DrivingHome := true;
$ s) c9 y9 s' r+ o                        end;4 x  c2 x; f4 j; F8 X3 C
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
% }0 D8 F. d/ n                        part := @.transpOrder;
; k. t& [" m" ^& l                        part.move(@);-- load part" O/ J: Y: i; S5 A0 Y
                        @.CurrIcon := "load";
9 r& ^# x3 s& E, V/ j6 z- D                        GlobalDistObj := part.globDestination;. I! p$ [  B$ r4 K1 q
                        assignLObj := rgmanager.rgAssignL;
6 `8 W4 c: x. m& t                        row := assignLObj.getRowNo(GlobalDistObj);( _. g* [! Z, F) r- W) f/ I
                        if Row = -1 then -- since 70+ X% Q* u' z( [
                                if lan=1 then. i( D' w" N# S6 \) V$ z' D
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
" i/ t+ u# ?" R1 X7 u7 S% ~2 s                                                to_str("in der Andockstation: \"",?.~.name,"\""));- _- S# [) b1 y1 H: r' v) S: X
                                else
0 V$ A( S/ N+ m  b4 Y5 e; H; k                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),1 H% q3 b# j" v3 e- z( p
                                                to_str("in docking station: \"",?.~.name,"\""));                               
3 ~+ u3 e# r  ^3 m; l                                end;% ]3 J+ T+ [* F3 t
                        else
; a" c: y' ]! e                                @.Destination := assignLObj[1,row];% c* Z# E* Q, m9 L  A, t
                        end;                        7 I, p, R5 Z+ L
                        newDirection(@);- [4 Q. c( V* l, _/ Q
                        @.HasOrder := true;
+ Z, s/ a9 b9 e$ F% a3 c7 m+ ?0 r# j                end;/ r- [  a. r" [3 \3 N$ l
        end;# x5 F5 X5 {5 J# B
end;        -- of the method
2 J! q1 O  k( o9 k* k
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 + V: a- ]3 Q1 c
& l. Z$ r+ ~" a7 z1 L- h
这是AGV_putin中arrive的method。) z8 t6 f/ v8 S4 c7 W
, g! R5 [- V9 Y3 n, f
当到达物料速度越高时,这个报警更多,
1 w$ }& r" b, ?5 [- ~可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
+ b) A+ T0 r& o程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?/ I5 X/ L5 E1 v% p# J/ m& G5 R
% I4 P$ w" n; D/ L0 [0 w- i6 b
另外一个小建议,就是move,所有的move都可以这样
' K2 u, y9 h- ^" c% Y* Zif not move() then debug end+ i4 R: s1 b, K( \+ |9 ^- E8 Y& B; b
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。4 K1 i) O$ P& _
plant simulation中的free libraries有AGV模板,
+ P5 M' h' e! H1 D1 Y里面也有案例。) K0 Z7 Z, g- n; G; D
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
# I( L6 J5 r, X5 \+ j) d  K7 g  u3 S' [
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 9 z3 i) d" L6 M2 g
, F. A# u) r6 a  j& J
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 4 _! X8 O8 B8 m( R2 b
这是AGV_putin中arrive的method。5 h3 G0 V& f3 [% M, j1 ]9 @: `
) A/ V# ~; ?' J1 k9 X6 s( M' V2 k
当到达物料速度越高时,这个报警更多,

5 w& p' k/ i  m! ^, X: ]$ i另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-27 08:11 , Processed in 0.017772 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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