设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9613|回复: 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'6 o/ ?* U, z, E& g( t
*/
, R1 D3 _3 ]( q( f/ n- a) T8 u# Tis
; d, u( \% |- ^2 M* B$ {        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
# e- ]* b4 v$ `" w$ y0 F3 C9 R# Qdo- {- l% o' G$ [
        Lan := rootfolder.Internal.Tools.AOLlanguage;
& D2 F- O% R- @        if current = @.Destination -- else return5 b& s! O$ ?8 u+ o
        then
% g4 e! ^/ @1 g% N" ^) [3 S. S                @.Destination := void;- L; r  L1 Q. v. i) |- I% F
                if @.occupied then' p% k2 H1 i6 j# c! L5 f4 E
                        part := @.cont;9 S3 s: a; f# F4 m% G8 U7 E* F4 H
                        @.transpOrder := void;
% \4 a& d1 R4 g0 Q# H- x                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,' Y; H2 g* K3 ^" s
                                @,root.eventcontroller.simTime);4 H# {* c9 {& F% ~5 b
                        @.HasOrder := false;
# k& l( r3 }  J* i! Q                        @.DrivingHome := true;
5 l) R* e6 ?1 G) z) \0 Q                        rgManager.tryToStartTransOrder;
9 [; c+ M. F, J# l                        if @.Destination = void
$ E2 l7 s  x; c1 ]$ `% p                        then -- no transport order for vehicle @
- @* q/ i. R/ M* J  Y; ^8 m                                @.Destination :=
* r4 t. s  D9 b6 h% k                                rgManager.nearestFreeStation(@,track.~);+ C2 v; o/ W+ c
                                newDirection(@);   
) [0 C4 f- S7 `' n& P2 a                                if @.Destination /= void then5 ?% J$ M  w. _! j. `+ C. ^3 c
                                        @.Destination.NumReservation :=' `: t+ |4 V2 q* S6 Q) K: i
                                        @.Destination.NumReservation + 1;" O7 Y% m9 I  V' d0 O8 ^) w; `' Z% d
                                end;$ H( `* j0 H  X; W# i8 s& i! y8 ]4 t
                                @.CurrIcon := "drivingHome";/ g4 b' Z" @. j% U3 F, o5 [
                                @.DrivingHome := true;
. j' N( e* n: l5 t                        end;& N9 m+ g4 Y; E! G& @  c* x$ I# H
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station7 i; k) Y0 ?! [4 ]( s9 R- s- ^
                        part := @.transpOrder;. }0 _7 m: Y! ~
                        part.move(@);-- load part( Z1 ?1 X) v- b7 a5 k. l
                        @.CurrIcon := "load";
& P/ l: p  C0 d, c; _- s) I& D                        GlobalDistObj := part.globDestination;
" L1 v5 v3 e6 ^3 h                        assignLObj := rgmanager.rgAssignL;
6 r2 c- V( Z! o* t9 w4 N. W! z                        row := assignLObj.getRowNo(GlobalDistObj);
7 P  O% e1 g( i; A0 Q                        if Row = -1 then -- since 70- G% u& X. h- ?# q2 W! y0 m
                                if lan=1 then  m8 U" e2 N8 V% x6 T
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),3 r' ~! T6 v% K3 _2 N7 {0 ~1 z
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
! Q3 o7 a' _: c                                else
/ e% K4 X% D* g9 b' p7 X* I* ~                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),: B  V+ t& h$ D! C
                                                to_str("in docking station: \"",?.~.name,"\""));                               
* v8 t! Y1 I) z% [$ m" P                                end;8 y$ `' [9 e3 K9 w8 [
                        else' f* s) @# D) |. n8 _
                                @.Destination := assignLObj[1,row];; C# b9 e1 M# o6 o) h8 X
                        end;                        0 s( x1 ?3 r+ d
                        newDirection(@);
) G3 J: m( c3 L; W5 ~! g; K4 }, p                        @.HasOrder := true;
8 Y3 @  U2 n+ {: J' h                end;; m0 d! E3 `# l, z
        end;
1 H' G8 i8 T2 C* hend;        -- of the method  _: Q' ]: J$ G1 z; l8 a1 x7 d, r
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
8 P- _4 D7 H3 H! v
' Q7 ~+ B5 y$ l% o- ^. d2 ^/ c这是AGV_putin中arrive的method。' g( U1 x8 Z$ ^9 ?) x0 p3 A  V

+ D, p2 l% |) ~2 b$ D" F: `当到达物料速度越高时,这个报警更多," r+ r: _: K$ C. D' c# C1 U; y$ y
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
& d% w  |& v/ [! p0 O* L. S程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
- c. ^& S7 @) \/ z( `1 h" `& ?% S5 N( F9 t5 Q, t% ~
另外一个小建议,就是move,所有的move都可以这样9 a: H% B" p% D3 w7 Z% @7 A
if not move() then debug end4 l+ C- E5 n! ~$ _
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。+ \/ E+ q: b7 [" O$ `
plant simulation中的free libraries有AGV模板,9 D6 D: M& z7 _3 {4 {
里面也有案例。
- M; q# e# t$ h7 M9 n我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。1 Y$ D/ p8 ?. f5 c

: f% R- m2 k3 y我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
, F2 J9 H- |0 F) ]2 [7 }! n/ B/ ]! |0 ?, Y
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
; T4 ^3 S) i' d, |这是AGV_putin中arrive的method。2 r1 c1 l% W( Z/ O  H
" V4 O; ~- `+ m+ x5 k" f
当到达物料速度越高时,这个报警更多,
8 l) u7 A3 W; E5 g2 F
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-11 19:45 , Processed in 0.020339 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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