设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8843|回复: 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'5 d8 d1 U+ e6 J% T
*/3 h/ R& Z: L6 f/ g. N
is7 R% n- h# S2 T
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;( Z& ?# D* G; N, l, Y
do
( L1 ~- [, u) E        Lan := rootfolder.Internal.Tools.AOLlanguage;6 G# M; v8 g5 z
        if current = @.Destination -- else return8 d" k  F, H# x) }8 S5 Q
        then% c0 L0 V3 h, ^* [  [+ O
                @.Destination := void;
# X5 }8 J0 G# Y' d4 S                if @.occupied then
4 q1 ]( x7 s: r                        part := @.cont;8 u9 M5 `0 T. c' Y4 s* ^
                        @.transpOrder := void;# w) n+ }, E# s- G5 b7 d
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
4 U' N1 F8 }* @% }                                @,root.eventcontroller.simTime);7 ], d1 n$ J3 v* ^1 E
                        @.HasOrder := false;
1 P; O; v' M8 [# H! }! H/ O6 {+ {                        @.DrivingHome := true;& Q: g& L* {6 \; R6 s7 C4 x2 p/ o. f
                        rgManager.tryToStartTransOrder;
. }+ n% l% m% Y% V; T                        if @.Destination = void
7 J3 [: j4 q. d! S  r9 m/ J* M                        then -- no transport order for vehicle @
- O3 _) j+ A4 P$ T                                @.Destination :=- G# W; y7 d. C
                                rgManager.nearestFreeStation(@,track.~);# O: p. Q- \' G8 R! w
                                newDirection(@);   
* u$ j7 q2 F9 ]) g4 Y, P                                if @.Destination /= void then
  ?. h7 ?! K6 q$ n                                        @.Destination.NumReservation :=
8 `& _2 ^5 ^7 r! I6 d( Z  _& e8 r                                        @.Destination.NumReservation + 1;7 Q/ B2 {; Z8 U3 z6 @( p7 i
                                end;
% Y( O9 V! i) p8 R0 q' K                                @.CurrIcon := "drivingHome";: k: n- p, {' u. p, S8 j
                                @.DrivingHome := true;  ^- e; A0 N4 t2 [% \0 ]
                        end;2 W6 X9 x1 g( d: D
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
6 W) i# ~; U, u% z                        part := @.transpOrder;# P* m$ K, N! b. S
                        part.move(@);-- load part$ ?# I3 z- i6 I) H* @
                        @.CurrIcon := "load";
) b+ P! z3 h" _9 P                        GlobalDistObj := part.globDestination;. h5 j  `( a: A* I  \
                        assignLObj := rgmanager.rgAssignL;
9 g1 }* o: L: L2 l5 j# ^$ F                        row := assignLObj.getRowNo(GlobalDistObj);8 h6 l' e  Z# }
                        if Row = -1 then -- since 70% {& e/ l, W2 }* g9 K$ v2 z
                                if lan=1 then; V. |2 y5 t% b$ s
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),* r9 K, a" Q9 W9 P
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
5 U4 \3 d: a2 N2 {) W7 u                                else
; w; S) x5 U6 E! e$ i8 L                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),8 n+ Q/ X1 V: d9 M, w2 w7 u9 k2 |! j" r
                                                to_str("in docking station: \"",?.~.name,"\""));                                . W( \4 u% o. a3 ^& i  @* q; w
                                end;" q7 t; s, e* s6 b% r. i
                        else
: i- R9 z! F9 p4 r$ }  I                                @.Destination := assignLObj[1,row];5 C* G9 m+ r% R! }
                        end;                       
$ c" R- }1 k9 O6 r$ H6 m# _" Y                        newDirection(@);
0 D; {& a* p3 }% Y5 R6 t" R                        @.HasOrder := true;/ z& {; D% a4 ?1 R; p
                end;
3 X- b3 W, ]8 O9 A$ ~0 h7 a2 g        end;
# }6 v0 t9 G3 _end;        -- of the method1 L$ q; \4 F# u5 l- m+ e0 v
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑   V  [! _- s$ Q9 P( n

5 O) q) N3 E/ h1 K$ L3 ?这是AGV_putin中arrive的method。
. H" [/ ~+ T$ |) i, G8 L
) K& Q! h8 o1 S6 V. v6 ~/ e! X当到达物料速度越高时,这个报警更多,
, n; W$ I* w1 B8 @" x可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
) O- ^+ ?. ?8 h% `5 I: g程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?5 N4 o2 O( Y# [( K# ]1 q% G+ v8 ^

+ l) O  e+ k+ y8 q6 P! I  C另外一个小建议,就是move,所有的move都可以这样+ j2 R! Q& @  }8 Q+ _( w
if not move() then debug end6 P* A) h% `  n- i8 b
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。: a; W2 s7 y# R: `( Q& ?8 G
plant simulation中的free libraries有AGV模板,
% O3 j3 `: V/ N% T- w7 Q里面也有案例。
! T6 X. v- w9 C: W4 L; V我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。' X1 {6 T" r( ^) Y" |9 [; u2 `. K
$ U3 G- y6 y% V. _% g/ e( b
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 & ?4 r2 L0 G0 K( c

5 N: \7 [" t% f$ a那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
1 C2 J+ I, a- E" R这是AGV_putin中arrive的method。3 \0 T( f  m0 e; z7 |: l# z
. J$ Y  b1 U1 m' {3 X8 M
当到达物料速度越高时,这个报警更多,

- W# u! V) R! x0 D! V4 R/ R另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-29 16:04 , Processed in 0.018451 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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