设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6391|回复: 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'
% C2 s$ D1 v2 o5 O! }0 v*/( T# r, h* O% t( q* [, S
is. G) z, O1 s: t* S; `' l
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;1 x& B$ q2 i, D8 F2 u( ^& q: I
do- s1 N4 p4 L5 Y
        Lan := rootfolder.Internal.Tools.AOLlanguage;
, m' O) l- R! @$ c, k        if current = @.Destination -- else return6 g& N* x% f, B6 J) q
        then
8 J  ^1 a! ]$ v9 y# H  R                @.Destination := void;
' {8 p9 \5 o; M9 t                if @.occupied then' Q" g: g0 y) `: Z: M
                        part := @.cont;
- C7 s5 k: c& D4 r: P$ N# ~                        @.transpOrder := void;
& u: j# c+ P7 O+ Q                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,! a0 U& I9 D8 G
                                @,root.eventcontroller.simTime);& ^- m, l; B1 @0 }; o
                        @.HasOrder := false;# ?5 E7 W0 n7 p9 W2 v. V0 x
                        @.DrivingHome := true;! J0 Y' a- C" S9 }; j6 p" L: W
                        rgManager.tryToStartTransOrder;% y, k/ _; K# ]! [
                        if @.Destination = void
6 d- x: Y0 d6 T$ V5 R8 }" ^                        then -- no transport order for vehicle @
+ `: S; }! k# _6 a                                @.Destination :=
7 E, I" V  n  d8 G- ]% Y0 r                                rgManager.nearestFreeStation(@,track.~);: b$ e! I  |5 j0 D3 o3 \" \5 Q
                                newDirection(@);   & w7 p" a. K6 N8 o! ^, i* S, q
                                if @.Destination /= void then4 o( e) S3 Z) d* N5 e8 Y, b
                                        @.Destination.NumReservation :=) H) V/ a# N2 }7 d/ A$ z
                                        @.Destination.NumReservation + 1;
7 n8 }6 D8 P5 H3 ~                                end;
, t4 W- p/ s+ n2 j                                @.CurrIcon := "drivingHome";6 ^2 \4 B& }, u1 Q2 F& i  Y3 s
                                @.DrivingHome := true;1 N7 c, w% f+ z* _! }) ~' }4 U
                        end;
1 e9 D: C! [( n5 B! m2 Y                else -- the vehicle @ is empty, both vehicle and part are in the same dock station4 p0 k% K: `/ D2 c; k% g' O
                        part := @.transpOrder;, w8 k9 @8 \0 D7 e" O4 O
                        part.move(@);-- load part
( E4 }7 ^1 t3 G/ `                        @.CurrIcon := "load";
1 D2 ~# h2 U) W7 @/ S9 B3 M                        GlobalDistObj := part.globDestination;
, o3 [+ Z$ I6 w+ @8 V                        assignLObj := rgmanager.rgAssignL;. u9 Y" `- K6 T! _
                        row := assignLObj.getRowNo(GlobalDistObj);
5 B! u) {- v" I# `, w7 |                        if Row = -1 then -- since 70
+ m/ e9 r3 Q+ x' O! ^                                if lan=1 then, {7 b- m$ a) l6 I* m" _2 t
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
5 \1 a+ R! C6 Z1 y                                                to_str("in der Andockstation: \"",?.~.name,"\""));) |5 o8 O# `3 ?
                                else- k% ^( e1 P" ^9 A7 f+ `
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),; ]9 u$ Y9 n) ?+ A
                                                to_str("in docking station: \"",?.~.name,"\""));                                % ~" T# p0 y0 ^7 \4 w1 l
                                end;1 P9 `  z# s$ [$ G  i; _  `  u9 W
                        else  _. d. w" u! l5 i: U7 O& X
                                @.Destination := assignLObj[1,row];
: }  O) L. j. x/ H: T! T                        end;                       
. X9 u" I* C, J: H( {( L0 o3 _* F/ D                        newDirection(@);
3 H0 A% O, u) e/ a                        @.HasOrder := true;
- w8 Z' W# h4 a. B* Y                end;
1 Q0 v! s* H/ T4 z9 }        end;, X) \! ^$ ~# i
end;        -- of the method
& y2 {' X5 G4 h
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
# |- V* Q2 w: W% z7 U+ P/ D0 c$ E2 m: F4 n
这是AGV_putin中arrive的method。9 ~  V0 D- B" x* A# H2 f% D6 ^) W( [
/ @8 ~+ R" E4 ^) k5 K2 U
当到达物料速度越高时,这个报警更多,- [( ~4 X: i: |, e5 O
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。6 N1 T8 ^$ K, }8 Y
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
! B* p, {* H. c
- A" y- e5 y2 b' n另外一个小建议,就是move,所有的move都可以这样$ }+ h) Q7 F! k" r) B* V, N2 U
if not move() then debug end
& `) \2 N9 C! {, |0 V5 c; t1 E5 a7 \. P这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。8 J8 }, J1 T4 i3 e
plant simulation中的free libraries有AGV模板,6 ]1 y# s1 v* e: s1 f2 X: o
里面也有案例。
7 }0 w& K+ l/ U) F我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。( r* U! R6 \' e! _% R
' x5 K: z3 {" {; x% b* y
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
2 E9 |: e" d, m9 |
  ~$ v) A( `2 l, b- x) p% ]( |1 a3 x那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
7 y# p% R. j) d, @9 Q6 s+ R这是AGV_putin中arrive的method。
. s) |- f) m  _  p  z3 c5 M5 U1 e8 B0 M
当到达物料速度越高时,这个报警更多,

/ I+ q# j1 Q3 `: v) m' _另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-3 20:54 , Processed in 0.026185 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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