设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6247|回复: 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'
- Y) b1 d) n9 I& J! A: q*/8 Z- T+ ?5 @& n: Q
is
* u+ t; }# F1 X. H        part, GlobalDistObj, assignLObj:object;row,Lan:integer;0 `6 q5 t& y* T) c
do0 b/ Z1 l1 }7 Y+ R6 L- p
        Lan := rootfolder.Internal.Tools.AOLlanguage;
1 D. ~; C1 M" Z  x; W! z7 z        if current = @.Destination -- else return
4 p6 }- a; R3 i) d        then
4 A5 T* H. S, S- q$ H7 ]3 P                @.Destination := void;
0 t6 V# V7 w8 o4 C                if @.occupied then3 |3 h4 v. A* d' t# ^* g$ n
                        part := @.cont;
+ r; k  }" ]9 j+ ~! Z                        @.transpOrder := void;9 Q+ S7 {5 H1 |8 g( J
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,; T* T$ j( h; q  K
                                @,root.eventcontroller.simTime);2 H/ {6 A7 ^$ K; n
                        @.HasOrder := false;, E* k' a* L3 b" h3 u3 v
                        @.DrivingHome := true;7 J+ M' |* w8 U* ~7 d! b: g
                        rgManager.tryToStartTransOrder;
* D2 O6 z3 e: `, T                        if @.Destination = void+ e* g' a6 n, {3 U6 P
                        then -- no transport order for vehicle @
% L- a& c5 Y% f1 A9 K  a                                @.Destination :=9 N9 O$ O) W8 h& l: X
                                rgManager.nearestFreeStation(@,track.~);
$ A) m: w& O. I9 Z2 }+ j                                newDirection(@);   
) K$ c# c0 U0 u* v  v3 G4 b                                if @.Destination /= void then9 Y/ A: k1 a9 c' L  ^
                                        @.Destination.NumReservation :=
! G( b, I1 @- H  [; x: z/ M/ p                                        @.Destination.NumReservation + 1;% o, k2 p. P2 Z8 w1 E- D3 x5 e
                                end;
3 ?1 L) b2 z/ N# Z+ \9 Z7 {                                @.CurrIcon := "drivingHome";, u1 A& Y! w0 ^- S' n- h/ v
                                @.DrivingHome := true;
: ~& |0 X; A0 `  G+ _                        end;
( n0 Q6 F7 N* u4 O& p                else -- the vehicle @ is empty, both vehicle and part are in the same dock station0 V6 a5 Z  V9 h0 i7 @, Y5 u
                        part := @.transpOrder;" M) Q% j) q: s0 Y
                        part.move(@);-- load part; F# s0 g# H5 g: u7 Z
                        @.CurrIcon := "load";" |1 J5 U3 l9 O7 N9 b$ d! E
                        GlobalDistObj := part.globDestination;
( x( A9 B. X  N- a, ^' s                        assignLObj := rgmanager.rgAssignL;4 I9 |7 y# K5 N- {8 @
                        row := assignLObj.getRowNo(GlobalDistObj);
: ]# N; @6 x% V3 Y7 z5 M1 [                        if Row = -1 then -- since 70. `5 ]3 O2 N  y) v' [
                                if lan=1 then: `& k! J& H  Q. F
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),' K) r% @6 V: j
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
: ]% O& j9 b$ J                                else
% }" a2 x* \7 M; `; v$ o2 q                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),( T8 e) T) H4 {3 Y: q/ e/ T, I
                                                to_str("in docking station: \"",?.~.name,"\""));                               
4 ]3 }: U* z# I( T                                end;5 }: X; [6 V, ~$ M) X3 M$ e
                        else- U" J& l, W$ f  G
                                @.Destination := assignLObj[1,row];& V& G+ I" B- ~" ]
                        end;                        5 ], K* a, ?) z/ }6 n$ w
                        newDirection(@);$ U+ w* M' N0 K. G$ S
                        @.HasOrder := true;
  N* B; Z3 |- z                end;( j: l9 f+ O: q! G9 u! P2 \' n4 X( q
        end;
. g2 Z0 s- a  i7 x: C# h# Send;        -- of the method
- u1 t  j& E' ^/ j# h
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ; X! j4 e/ [& U" k, o! b+ O
2 z1 U* y9 T  d8 U3 ]0 k
这是AGV_putin中arrive的method。
; p; i, G1 ?+ Q0 L, l' g; I  L' ~+ H# l
当到达物料速度越高时,这个报警更多,
% r% W" A2 v- z2 a! a( j可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。  ?6 ~9 Q" ^5 [  T1 |; C) A
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
, a7 t# `$ L4 [" J4 ^
9 V4 P* U! a3 Y" |* C# Q. E# r另外一个小建议,就是move,所有的move都可以这样2 S3 F3 q7 J& p! @, h
if not move() then debug end$ _: Y" s3 S/ I' E4 k2 L
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
& v+ ~  ]3 ~! [; N) Z' Nplant simulation中的free libraries有AGV模板,
( w7 O! f' O# x5 W4 z里面也有案例。
# P% k# W0 c% k: d- N0 _我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。+ \/ {( l& s! X$ k9 m- V1 d" A8 _% a

; P3 L3 b0 u& ~% K2 E' ]* y我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
3 T& P; E1 `  v4 ^1 D- V0 M
3 k5 F9 M/ w; r8 `/ S, e4 _! ~5 e, m8 S那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 2 P2 |4 K5 P' i% O% A, ~' @
这是AGV_putin中arrive的method。' ~- |; m& h7 }; t$ Y4 Q

6 _4 G7 b; E( B. A& _/ ~当到达物料速度越高时,这个报警更多,
- B' ]; q" R2 r2 a7 M' I
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-27 02:38 , Processed in 0.025892 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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