设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6908|回复: 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 a" `" E1 u+ Y4 N
*/+ \0 F0 Q$ ^8 M+ Z% ^+ V. I$ v6 \9 ^
is# i$ \# F) O* F. M  U' Q% m
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;, b  ~3 k, ?2 f/ L) a8 q0 f
do
! p& k# z; r1 N" e0 B, l        Lan := rootfolder.Internal.Tools.AOLlanguage;  `- t* h' q- k* Z# g7 D7 U  j6 C
        if current = @.Destination -- else return  R& U' c9 j# Y. f
        then( p& L9 ]: o* [5 b5 I0 {
                @.Destination := void;0 \& E  o, D. [) o9 z
                if @.occupied then% D* z: ?( w1 D* e' N% K6 c$ Z  u; A
                        part := @.cont;
& w* F4 t5 }$ s; I: J                        @.transpOrder := void;4 A. H6 N1 y3 q8 h
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
  ^7 _3 z. D2 x6 A, V                                @,root.eventcontroller.simTime);
/ o" D$ D* z! N" V+ P                        @.HasOrder := false;
1 `$ q& |& X  \! L* w                        @.DrivingHome := true;
+ n- S5 ]1 C$ R3 s3 K$ h                        rgManager.tryToStartTransOrder;
* y3 N: A" _3 k                        if @.Destination = void
' }7 K+ B% K- Q0 j$ H& i4 B7 r+ Q                        then -- no transport order for vehicle @
( e0 T6 ]2 Q& I" u                                @.Destination :=
+ w( G% L) c/ c% L                                rgManager.nearestFreeStation(@,track.~);
6 y9 E7 A  k/ {) X9 U. K                                newDirection(@);   + ~( [& ?3 u$ G/ ?0 B
                                if @.Destination /= void then4 g8 l. {. q" G* V8 a+ b% {
                                        @.Destination.NumReservation :=- [5 N7 U( t; q3 _5 Y% O
                                        @.Destination.NumReservation + 1;9 B% ]% m. ~; \1 q" v) t
                                end;
  f8 i  n& x6 Y0 s! \% W: s                                @.CurrIcon := "drivingHome";7 A5 A8 F# G6 A; k; q3 C+ Q
                                @.DrivingHome := true;) f* t- X. Z! Z. X8 Z# g, d
                        end;
+ s$ v' }# S; w                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
6 ~3 `3 d/ m8 z$ S                        part := @.transpOrder;
/ i. o$ C2 b  V                        part.move(@);-- load part
4 [$ p% G0 B) a6 O( c5 T% u- @                        @.CurrIcon := "load";) ^. ^$ A" {4 A  F3 f
                        GlobalDistObj := part.globDestination;& d4 Z4 X+ G# d9 }- |
                        assignLObj := rgmanager.rgAssignL;
" W8 L4 G# l! f                        row := assignLObj.getRowNo(GlobalDistObj);( Y) u5 _2 y. O) N9 b
                        if Row = -1 then -- since 70
1 [4 y9 @: L& z1 H                                if lan=1 then
0 @5 j/ x5 r' g6 m0 |1 }3 e/ H                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
6 |6 c- s: F8 \3 _: B7 b# m0 B1 L                                                to_str("in der Andockstation: \"",?.~.name,"\""));+ ]1 o+ F" V( T5 C$ [# a4 o; i1 T9 [8 E
                                else
$ r6 W+ U: V: n, d2 m                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),# q* k" Z- @: l2 _2 e& J2 V' Z
                                                to_str("in docking station: \"",?.~.name,"\""));                                ; m0 H4 D1 |" a
                                end;
, c* e( Y% f! m' O                        else
% u! V$ c5 Z8 Q- }                                @.Destination := assignLObj[1,row];
: X: ^0 z% y+ n4 V/ z7 X                        end;                       
5 T. e% O+ V6 ~7 Y8 i' o# R; k                        newDirection(@);
. j& P; r% W# I7 m  J$ E* s                        @.HasOrder := true;: Z% F. i5 K& Q& e* c3 S, ~
                end;
1 y' r2 m! b- O# ^7 W' N; X4 O        end;
7 K* f3 x. n- Vend;        -- of the method
. t% \8 v% i8 j8 T
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
/ ^1 p/ H+ F( K# [5 O
9 }% i* w2 g; S0 B! X这是AGV_putin中arrive的method。8 B; D- b1 B1 ]- L" y* J- Z4 ~

  F# }# R: @" t, O8 ^' k- d6 m当到达物料速度越高时,这个报警更多,
) q& b) p9 v  m9 X可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。6 Z, j% y& u( P1 |/ D8 y+ x; _/ o
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?) |4 \- z5 j3 c# R7 c0 }, i- v

) j* b$ Q/ h3 j! j' W1 Z" c另外一个小建议,就是move,所有的move都可以这样. O: z- g, ?. Z' _( X7 p) y" p
if not move() then debug end
9 W+ e+ I; u: Q8 A; L这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
! h; w/ q+ a3 O$ ^! p- lplant simulation中的free libraries有AGV模板,; Y: k0 p" n& D6 S) B$ G; b: I2 d
里面也有案例。
3 N% M) P; i0 A* @) K+ J! G4 \我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
4 u6 O! _: j& }, d
  `8 L7 E; b& B+ l; {$ X; Z我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
$ n9 o/ Z/ ?- C% z, Q. {
4 z" p9 M  w8 ?1 [8 ?那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 $ o0 y& Y8 O9 M& e: H) Z0 F4 f' Z
这是AGV_putin中arrive的method。
2 b% g2 |+ J! ]: p: s* g
4 F. o: d6 _4 @3 }7 o) E当到达物料速度越高时,这个报警更多,
5 c' r# D+ g; Q# I
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-3-6 05:28 , Processed in 0.021751 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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