设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7435|回复: 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'
. C0 s. J- z8 ~5 q: x*/
* y4 D; e8 t7 O- Mis
9 k! Z# ~$ ?: a        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
0 L6 e! K7 a5 D( {do- z2 T- L- @1 o! c
        Lan := rootfolder.Internal.Tools.AOLlanguage;
3 ~; g% j: v9 r; H; p% ~        if current = @.Destination -- else return
) x( d' P/ }$ {+ N2 M& b        then% T  N8 j5 ~) M3 ^8 c$ [
                @.Destination := void;2 n" d9 _) A5 b, y& L& V9 q
                if @.occupied then/ r+ ]2 j, Q9 q* d7 {* {( l+ E/ `. c
                        part := @.cont;( d* q* `0 D3 v- E, b2 Q) z9 n; q
                        @.transpOrder := void;* D" q+ U  Z* K' J
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
0 P% c4 o. J5 A+ ?3 c6 s5 x                                @,root.eventcontroller.simTime);. ~0 f% F, T" }- S1 u, ^
                        @.HasOrder := false;
5 j4 `, P2 n. t                        @.DrivingHome := true;
- W9 f$ c1 A8 v# H                        rgManager.tryToStartTransOrder;
0 V& d( C5 n0 d- a% X                        if @.Destination = void
8 L: B0 C% Y5 ]+ ]* v  w                        then -- no transport order for vehicle @
4 l- y6 r& t8 z6 ~# r; t2 F                                @.Destination :=
% R9 D2 h5 m+ U1 {1 S. @2 K                                rgManager.nearestFreeStation(@,track.~);
! {8 ?  ?4 Q( k* L                                newDirection(@);   3 ~3 X3 o- Z& O+ J0 L
                                if @.Destination /= void then$ a, m) J5 H/ _3 S" E2 D: T
                                        @.Destination.NumReservation :=
0 i5 B: u1 ]4 Y# p                                        @.Destination.NumReservation + 1;( I2 |6 Y% N9 _, _5 {
                                end;
( H2 F$ J! S8 G6 U) Y                                @.CurrIcon := "drivingHome";# Z  ~2 T& B& A6 n5 R7 F
                                @.DrivingHome := true;! e: C( v4 ?3 l' h
                        end;
4 `* @+ C5 x- j                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
, u9 |$ a& m. E2 ]5 g                        part := @.transpOrder;: D/ B: k+ _. h+ D' L, y) }
                        part.move(@);-- load part+ I) D1 r3 S6 d1 `- q
                        @.CurrIcon := "load";
6 F' p; v; W- R$ \# r' i0 E' V                        GlobalDistObj := part.globDestination;
, G% V' I+ s# X, X                        assignLObj := rgmanager.rgAssignL;
# K1 N7 R  w, z. j* A0 m# Z' l                        row := assignLObj.getRowNo(GlobalDistObj);
9 s7 W* ^" r6 M5 L                        if Row = -1 then -- since 702 K8 ~5 \7 U9 S8 V3 q4 B
                                if lan=1 then
: Q3 _( P8 _  k/ ~1 C2 n                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),% Z5 U" F$ J( c7 i
                                                to_str("in der Andockstation: \"",?.~.name,"\""));7 S- k9 c) H* n
                                else
/ q, S& O/ A! ]5 J3 ^: W                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
& R$ a2 b/ W9 f: L+ P, y" t                                                to_str("in docking station: \"",?.~.name,"\""));                                0 N. c+ ^( i9 c8 q; H
                                end;4 P! F' _) f/ X1 F; W7 P
                        else- q% w1 p2 l- J
                                @.Destination := assignLObj[1,row];2 `+ q: K# w' @, C3 M% [
                        end;                        7 k" M& ]/ n5 _8 j: b3 U
                        newDirection(@);
8 A! J/ H7 V8 \* v; H+ O4 B! b, U                        @.HasOrder := true;
# U  j' K, l9 r+ C& O7 [                end;
9 m% ]+ f$ p% K: ?7 ~& s4 E3 K        end;
- M; Q' |( O' F/ R) q1 Wend;        -- of the method
5 l. j7 F  k0 w+ j
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
7 m; p( @4 {  H/ F6 Y
! o8 z/ A' u& O这是AGV_putin中arrive的method。
  D9 m( q. V9 H: Y* M
2 C& s$ a) i) T1 ]* G$ Z1 l当到达物料速度越高时,这个报警更多,, }# L4 \8 Y% R& f
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。# ?8 x; [4 C( v+ u  K2 W, d
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?1 c7 g/ n/ i( p! R  F( H  A5 g

' Y$ M! Z7 H1 |6 @" z另外一个小建议,就是move,所有的move都可以这样
7 e2 F. i' q$ j: cif not move() then debug end
$ q. e0 h/ r- Y( p0 [9 e8 ^& }0 t这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
1 B8 I: ?, d) Q% W: e7 `plant simulation中的free libraries有AGV模板,6 T% F2 n2 |5 r
里面也有案例。
" ?  b8 E! E  j/ U2 C我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
8 H0 H, d/ G8 l# L5 X2 h- e- j. W9 x. k- j
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 & z5 O! A( e( B$ o8 s0 f

4 E; P4 {0 {6 v. {7 o4 k* N那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 / Y0 ^) z; I1 O1 g
这是AGV_putin中arrive的method。. V# Q9 ?8 [* e7 q) y

, [  Z$ _: B+ |当到达物料速度越高时,这个报警更多,
1 f$ b- b% k3 a- k2 M( G% b" a& f
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-11 07:30 , Processed in 0.021602 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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