设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8768|回复: 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'1 ~! n6 k( |! c" R. s) a
*/
- \% A# m9 Z: [; T4 H+ F; Q8 K. Pis0 y( }# g( s& e9 Q, X
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;/ p6 r% {" {+ q% Q4 k" d
do2 I! P$ G5 ?, C3 a0 I5 W
        Lan := rootfolder.Internal.Tools.AOLlanguage;
2 N, A# Y/ {3 F' r        if current = @.Destination -- else return
5 w2 ?% z2 t7 j1 y$ P; ?        then* m, _2 g3 M: T9 Z
                @.Destination := void;
+ l$ o2 V' a! q7 g1 I1 {  o                if @.occupied then7 J9 Q' i# D2 q: P  b% @
                        part := @.cont;( W$ L+ ?. d; t
                        @.transpOrder := void;- F; S3 @, z% z. z, f5 B
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,6 j' I2 Q0 }  x' P; Q, P" d4 E
                                @,root.eventcontroller.simTime);2 J  `( Y$ [9 w" h$ _3 a. \
                        @.HasOrder := false;1 r5 Q/ H# M# e
                        @.DrivingHome := true;. q! h. u5 |- L, b$ |' h( T
                        rgManager.tryToStartTransOrder;
% E% g3 z: l) f8 e( t                        if @.Destination = void
; ]) J- b8 j$ R' F% l5 h! K% P                        then -- no transport order for vehicle @; s- D3 ?8 z7 N. c' N1 V+ X- w& y
                                @.Destination :=7 c0 W  x4 p* m5 P/ b5 g4 S. H
                                rgManager.nearestFreeStation(@,track.~);
0 ]( B- J* u: |* ?                                newDirection(@);   . {# g8 O) {5 m* o0 k7 w" h5 @. _% v
                                if @.Destination /= void then! i: Z& Z0 I9 x; Q/ e% O' V6 ^
                                        @.Destination.NumReservation :=* T7 ~# p& P5 _
                                        @.Destination.NumReservation + 1;6 z5 `) F4 n7 ~) }5 V
                                end;
, I5 r% F7 o4 d- z9 Q) _/ W5 x7 r                                @.CurrIcon := "drivingHome";+ ]" C" Z, C2 r' r! L3 L
                                @.DrivingHome := true;
) i! T5 M1 I: J/ F, ~$ c                        end;$ O$ j  z( [3 B0 E; O7 f1 Q, l
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
8 P' e" [9 G, G( h1 l                        part := @.transpOrder;
2 Q4 @' L% j- n7 W' L                        part.move(@);-- load part9 d+ c" b9 |/ E0 \/ X7 F4 \
                        @.CurrIcon := "load";
0 \" h1 P- Q, X0 `2 B8 U                        GlobalDistObj := part.globDestination;; A( F0 w3 J3 J* C- `' O( ?
                        assignLObj := rgmanager.rgAssignL;
% J% D$ P# b, n2 ^: k                        row := assignLObj.getRowNo(GlobalDistObj);) m, z8 K9 z+ o/ v
                        if Row = -1 then -- since 70. L6 i* F" n; X+ {2 Y
                                if lan=1 then
: N; t6 |8 }% G, T                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
# `5 q2 D- D* i$ f3 T! w                                                to_str("in der Andockstation: \"",?.~.name,"\""));. V5 p9 C9 ]3 E/ i- u
                                else# x& q2 k) q  @/ k$ I' f3 i! @& b' f
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
' c1 [! K' ^& E                                                to_str("in docking station: \"",?.~.name,"\""));                               
, i( @( N* h% T9 H" z! Y7 W                                end;( O) ~; s2 a  `  e: a7 ?; l
                        else& \/ b4 U) i- \$ l7 o: v
                                @.Destination := assignLObj[1,row];( v+ {9 r5 T/ w2 Y
                        end;                       
- }, q* O6 j, p6 S, H                        newDirection(@);
2 E' X; A4 C) B1 q$ x2 L( \+ b                        @.HasOrder := true;' C9 D  _& p- M! f& `
                end;
# a1 y) ]) Y  J6 b& Q- `        end;
# ^. ]; @) v" M) F* T- a% a1 iend;        -- of the method9 a: R. j  R% h5 o$ h
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
0 L* |1 u! y4 z, F7 C4 a1 t+ ~  F3 _
/ m, x% P# @) t5 x这是AGV_putin中arrive的method。+ n( M8 g* p* Y) w( D
; K  ~( [: s" T6 e
当到达物料速度越高时,这个报警更多,
* \7 L5 @/ d9 c! D可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
% H# p: U% ^, _) L- a4 n程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?# V$ v* _; ~6 a! B# V7 ~% R
0 @4 ]! z( x8 o2 ^
另外一个小建议,就是move,所有的move都可以这样
, s( i/ M; |- Q4 X, F% Qif not move() then debug end
0 A1 {. s* Q3 j这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
# ^( N! \6 k3 H& q: U! Dplant simulation中的free libraries有AGV模板,
- b* p+ K5 q8 L( w里面也有案例。
9 L5 m- ?6 C" [+ V- I我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
6 `- j) `3 X$ x6 V  D: T6 C% w. F6 l' n6 ?) q9 i
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 $ [5 ^, W! n' L% u' ^' e. b

, `) \6 h; m% H; \7 T$ f# [那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
1 R/ w' b& R8 W; ?5 |这是AGV_putin中arrive的method。; W. f1 E  w) z

/ Z, r  y" a$ C9 |7 A+ r当到达物料速度越高时,这个报警更多,

; t  m8 x  g: y另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-6-25 11:27 , Processed in 0.014441 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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