设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8505|回复: 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'7 ^# `9 \. q3 `" H; E- }  N8 k
*/
' \9 c5 n; u, Wis
6 R8 X% ^* u1 `6 L0 M$ N+ r  U        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
# b# Z) Y) M) O1 z& G4 Mdo4 `% [) a2 @- c
        Lan := rootfolder.Internal.Tools.AOLlanguage;
  i+ q* y  r  ~0 X. k7 X: f' R        if current = @.Destination -- else return$ n7 |) |7 @# E. R5 u6 g
        then8 h  K% O& F- z5 ~, I
                @.Destination := void;! W2 [) a8 p" U( r8 G2 D$ X
                if @.occupied then2 x5 G# s+ U2 Z: Y" Y, p
                        part := @.cont;: k/ D1 g' ^7 k
                        @.transpOrder := void;
# E) ?  Y1 x$ ?/ K. R1 @$ _) B1 w                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
  c  U, \- i3 N& ?, r1 u  I6 I5 [                                @,root.eventcontroller.simTime);4 F$ O2 ?. v" ~% ], `1 S; ?: w+ J
                        @.HasOrder := false;2 I  ~8 i3 Z3 z
                        @.DrivingHome := true;
. x  ]3 L& W: f8 s                        rgManager.tryToStartTransOrder;2 d( d+ l( i4 K' B3 f( p: h
                        if @.Destination = void
# H, o0 f- f% i/ w) P& y( m3 R! m7 B                        then -- no transport order for vehicle @# l( q4 b4 h4 g1 U1 L
                                @.Destination :=& t' h0 a' m8 s9 J: E6 R
                                rgManager.nearestFreeStation(@,track.~);# z, Y* ^/ F8 T) `3 _& y9 r
                                newDirection(@);   
+ K+ p0 {& z5 G                                if @.Destination /= void then
. v- o7 f+ n# a4 s                                        @.Destination.NumReservation :=( x- A6 \4 ^% ]4 m# j
                                        @.Destination.NumReservation + 1;, c- I; f1 T  G( r, u3 }
                                end;
" R5 U1 S& e+ ~) j# e                                @.CurrIcon := "drivingHome";
% c0 Q- M1 _& Q$ X% y: L                                @.DrivingHome := true;
' x1 R& W1 x) y" n3 E2 \3 P3 c                        end;
+ _$ t4 W/ M  C& `; D9 T                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
* P  X( r* G8 Z( g. W                        part := @.transpOrder;5 |  o8 N: [) K; a
                        part.move(@);-- load part% Z: n3 k! M. W/ ^1 U" e1 ]
                        @.CurrIcon := "load";6 y5 Y' D2 U4 u1 {# q
                        GlobalDistObj := part.globDestination;3 }' z; i" G! ?7 }
                        assignLObj := rgmanager.rgAssignL;
, O6 G/ p# g  M5 f9 Q                        row := assignLObj.getRowNo(GlobalDistObj);9 Q# k4 h7 r) g0 G" Z0 O. d
                        if Row = -1 then -- since 70
1 W, j1 o/ y$ M: L  Z' v5 s                                if lan=1 then
# m- U( w7 l; p4 R; q4 M, R                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
# X: M0 y; o& R                                                to_str("in der Andockstation: \"",?.~.name,"\""));
0 K0 y/ N3 J# t0 M                                else# G0 B3 }. E" A. J
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),6 K- u4 C7 @4 `; V2 e) {
                                                to_str("in docking station: \"",?.~.name,"\""));                                5 z# S0 Q5 ?  G9 K! b
                                end;/ R/ g" t4 g2 K6 x
                        else7 E8 U/ W( U' }. j( m
                                @.Destination := assignLObj[1,row];# R, {, v: v8 g# _% r7 @' k
                        end;                        - k) e9 V8 q7 F& z& U2 s- m6 T
                        newDirection(@);9 P8 C3 t6 Z' {! V" o
                        @.HasOrder := true;
, a  A; k5 z: ^                end;
" h4 o! x. P4 c* v        end;: O' B8 t3 `" [3 f3 Q/ u
end;        -- of the method( @' ~7 `: H4 N; H) Q4 F8 }, t
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
" O, k& F1 u, E- r: K: L" n: |
. J: T5 _- {. G, @这是AGV_putin中arrive的method。
: j) P; e3 R+ O# \
7 Y$ q. V. f# }: H2 [7 d! @当到达物料速度越高时,这个报警更多,% i( E6 a" W$ g4 O
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
7 @! t' r3 k* V# y2 P" z' V# C程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
, @& r& r! S# s  Z) e2 M+ y. x; o: E. Q
另外一个小建议,就是move,所有的move都可以这样, t; Q& E' B7 C5 @9 _
if not move() then debug end
4 ]6 t+ U! J/ ^这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
- H0 \( D$ K) E% z$ h% n: \plant simulation中的free libraries有AGV模板,
6 q; B4 @4 u4 M7 H# M- V里面也有案例。
% l- d+ y( T; c% d我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。; K% ?: `7 ]* o
& Z6 |# b8 |3 x( ]' {
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 1 f$ I- I, E- a5 H6 Y

4 P1 o9 O; o5 g2 p- k那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ; f9 u& {, G9 a
这是AGV_putin中arrive的method。- w/ E% N; R# x, R0 t! i" c
) H/ {1 Z1 v  J! Q8 d2 v
当到达物料速度越高时,这个报警更多,

" z& @! x; o! _$ y0 e$ a) ~2 ]另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-8 05:24 , Processed in 0.015266 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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