设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6491|回复: 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'9 ]5 f1 h9 ~' J5 }' |9 K# N/ j2 z
*/
& I+ E. F9 R, L! H$ J- g# ?8 Wis' c  Q8 i2 H' I' v/ s
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
9 M7 P: E( {. a4 [do
8 Q5 K! \6 F2 B% m; t! B        Lan := rootfolder.Internal.Tools.AOLlanguage;
( a, o; N( \0 c' C. s* L        if current = @.Destination -- else return+ C- t9 M# A: K, p" k9 ]
        then
4 ]$ V( H8 X% C                @.Destination := void;* T6 J5 d: k- Q6 M8 j+ f$ j
                if @.occupied then* y0 @3 `& c- p  ?
                        part := @.cont;5 x6 q# [* p  S" N% _, u
                        @.transpOrder := void;
9 K% J/ h- w1 v1 w. p/ `- M                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,- C' W& B) s# M+ X3 q+ f' P) ^
                                @,root.eventcontroller.simTime);7 ]; }$ o) d( K& I
                        @.HasOrder := false;
3 ?' ^0 g4 b. D. s                        @.DrivingHome := true;
1 U& s7 w* l  C                        rgManager.tryToStartTransOrder;  b" ?* S  q5 I' ~7 d, x$ U
                        if @.Destination = void
' _0 {6 x: M% F3 U+ K7 h                        then -- no transport order for vehicle @
$ c7 Y. z! ?9 i' T/ A4 E                                @.Destination :=/ h& s. F* O$ T  E
                                rgManager.nearestFreeStation(@,track.~);
. [4 w! I% W% n- c% M                                newDirection(@);   3 E0 [# V& w. u6 a) c9 E8 Q! B+ k
                                if @.Destination /= void then3 o. G4 Y# @; @: z
                                        @.Destination.NumReservation :=2 h7 N4 Q# P" D
                                        @.Destination.NumReservation + 1;
* e: @- [1 P) l" M                                end;
# r" ~2 q! P- A9 Q                                @.CurrIcon := "drivingHome";
1 D' l- H: [4 B+ q) e4 V                                @.DrivingHome := true;0 k  g. W7 ?5 [; ?
                        end;7 W# M! x% R$ }: v, N
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station9 A1 t5 b8 L+ E. N$ i5 A1 N0 |6 [# V
                        part := @.transpOrder;! H4 ]  e$ ?2 n9 n. Q) }- k; g1 z
                        part.move(@);-- load part
* ^- v: L: B2 h4 e* C) q                        @.CurrIcon := "load";
  ?: V+ g1 ?, G4 t                        GlobalDistObj := part.globDestination;
& x2 O% [* }1 s8 P7 y% O  N% I                        assignLObj := rgmanager.rgAssignL;
3 h8 Y1 Y  A0 {. J5 m+ e" A8 ]2 f1 X                        row := assignLObj.getRowNo(GlobalDistObj);
/ c* F4 `8 Q- E                        if Row = -1 then -- since 70. L& e8 Q% ?5 o4 A
                                if lan=1 then* J1 d7 O1 G; M& C: r! c% t
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),2 x& V$ B- p4 \; ~8 Q+ E/ B
                                                to_str("in der Andockstation: \"",?.~.name,"\""));8 A! n& u* d$ v4 @
                                else
8 t) Y: B: m" z8 x( C" |                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),6 j# Z, q" i- v; S( i1 G# m0 }1 H
                                                to_str("in docking station: \"",?.~.name,"\""));                               
8 B# d/ G$ M! ~8 g/ c                                end;4 l+ |! u, ]" |1 K
                        else- ~! A- @5 `" P% r
                                @.Destination := assignLObj[1,row];
+ s6 o# I5 F, M4 S  F  o                        end;                        4 }1 W3 j( B) L* A+ V  E
                        newDirection(@);
8 S. h6 W' H7 c0 V  g                        @.HasOrder := true;7 ~4 C* x2 p7 I' l
                end;
' G- d# j$ t+ Y/ n        end;
1 a0 v: u4 P; j& Uend;        -- of the method
* n& h9 G  g/ o+ I3 n
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
! |$ z) v' I. M: k7 W, H) p8 P  H% V+ J+ p( }3 p7 d" M5 \* O
这是AGV_putin中arrive的method。
* I" w0 V  Z& s( T
  h  ^- k( B; `4 C! p2 c# V当到达物料速度越高时,这个报警更多,
  |+ g3 P7 E9 W- {1 T可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。* }0 V/ Q1 S. }; U: F
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
( t- Z; E! M  x) h# `8 I
. S* X4 B+ F7 g. A另外一个小建议,就是move,所有的move都可以这样  d+ }0 {" a$ [% a7 k( m7 D: q2 {
if not move() then debug end
" |$ {% ?3 p. b8 P" @, \这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。2 J. f7 E5 k) G9 V. x
plant simulation中的free libraries有AGV模板,3 q; v5 i- r, D# N) C
里面也有案例。
1 _5 ^( q; ]! a" `5 b' H我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
( Z9 _1 c# N; R' g" @% F! A/ ^/ p' u. q% V- s7 U
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
1 l6 c1 F% }* u
* |* e9 x& B, }8 _. u# q那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 2 I# `! U: c0 V6 V! `
这是AGV_putin中arrive的method。
) v3 i) ^0 ?2 m  K5 k0 K2 R/ X3 z# h. G# }3 ]
当到达物料速度越高时,这个报警更多,
& ~/ c2 [* }' g) j: I2 r1 s( R
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-9 12:56 , Processed in 0.024028 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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