设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7483|回复: 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'
# C2 L+ _# r' M! i9 r8 P- `* v*/
. O$ G# m: C: q+ E6 w+ k; Tis4 C. z: |9 L3 r5 t  m$ n5 ^7 u1 g
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;  l4 r2 n/ \2 {& q- T
do
; M: G" W5 m$ x; G# J" k        Lan := rootfolder.Internal.Tools.AOLlanguage;
/ o- u; E) n& Q* i        if current = @.Destination -- else return
3 |0 p3 J( s) I8 }! n        then0 X% q) Q: e5 F, b. q" O
                @.Destination := void;7 ^$ Q$ S( c4 c" b& z2 Z
                if @.occupied then! W/ j$ G+ l  b8 Y4 f
                        part := @.cont;
% T- t/ O. c, n9 i, M                        @.transpOrder := void;
, D2 a- v. J& V8 Q  }$ b6 h                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
( e  n  j; K- s! k                                @,root.eventcontroller.simTime);
! \& g! k: M* `1 L                        @.HasOrder := false;
. D) {5 p; F* S4 c- E8 Q                        @.DrivingHome := true;
6 X% u, j3 ]# V) Y, |4 P                        rgManager.tryToStartTransOrder;9 t' b, \9 F9 Y6 e
                        if @.Destination = void; V2 q. e; _2 m( s
                        then -- no transport order for vehicle @
4 l# Q6 g3 @! |5 g( s! P                                @.Destination :=- Y  g! j* B% B0 p2 ]8 ?
                                rgManager.nearestFreeStation(@,track.~);% |, `; A4 f3 @; a
                                newDirection(@);   
9 i/ M1 _% ]: L" J& V& A5 x. I& R                                if @.Destination /= void then
& w! `6 y3 s" C# p" u                                        @.Destination.NumReservation :=
* j4 [: h: r! y% d                                        @.Destination.NumReservation + 1;9 X5 P9 E5 ]* Q# ~+ x" b" ^. R
                                end;
) b! i( M3 f( N* R. e9 g! z% [                                @.CurrIcon := "drivingHome";
, ]* X; c/ y! I% Q! H% U2 g                                @.DrivingHome := true;. A7 J& x1 M* U. a) l# x- h( q& h
                        end;
! V% a& ^9 K% B) _                else -- the vehicle @ is empty, both vehicle and part are in the same dock station/ C* [2 Q; o& Z: z: s+ I* m( y
                        part := @.transpOrder;
* X  M1 F0 I7 ?9 V/ f                        part.move(@);-- load part  [0 T' B8 x* |3 b. u- l' j" h
                        @.CurrIcon := "load";  O9 Z3 o2 ?: I& \- p9 N; }
                        GlobalDistObj := part.globDestination;
' [; a9 V2 J4 Y5 t0 Q                        assignLObj := rgmanager.rgAssignL;' y# \& d+ j& \
                        row := assignLObj.getRowNo(GlobalDistObj);
3 Q  U8 x! `; \% {0 M: ~                        if Row = -1 then -- since 700 }8 g6 P) P) D
                                if lan=1 then1 B: v* L+ v7 }( A' p0 O
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),0 q1 d( T  I/ R
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
  x9 X% o; j0 O3 R4 y                                else
) \$ ^* F# n- T& N, B1 c                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),$ s, r7 E: K3 j$ [
                                                to_str("in docking station: \"",?.~.name,"\""));                                : @$ e( A( b: q
                                end;
' W7 Z0 d/ D9 r  [% M/ K                        else9 }- [! P( }  K& w
                                @.Destination := assignLObj[1,row];
5 g# I4 f. a1 @8 |- R                        end;                        + p' Q: G; I6 F; R8 f6 f6 b9 ~
                        newDirection(@);! F. z3 o8 b3 h0 ]- N
                        @.HasOrder := true;
. w/ V- B6 Y3 I( W& w/ e                end;4 U6 I7 m2 u; {; G7 g
        end;
2 a3 [$ h0 r  k- b0 _end;        -- of the method
$ Y/ H3 H6 m* A' `5 w8 L
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 . _0 U+ q; n% J% V: H3 X

9 t: E8 @- g! g1 ?) A这是AGV_putin中arrive的method。
( {$ P: @6 B0 P- a/ T: J/ ^& G' }' ~* c8 c
当到达物料速度越高时,这个报警更多,
3 A! M! J: Q3 H# S8 W7 K可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
, k  p/ M+ F3 V* _! J程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
3 R8 g$ q7 f! T/ b# O& G) c$ w% h# i5 f9 j7 k
另外一个小建议,就是move,所有的move都可以这样/ c0 [/ T9 V7 t9 C, r" w! P' Y
if not move() then debug end
. c. X# P" ?: x' n这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
! i- a; V+ C( Uplant simulation中的free libraries有AGV模板,4 q; q7 I/ Y7 J2 E1 L7 ~0 e% o
里面也有案例。' j% u# @( ]) H0 S, l
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。7 j; k$ @2 ?3 o0 E7 A
$ J( n- b8 `( c8 j& _# @7 E2 e
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
0 |2 t; `/ D) q, P1 @
7 z& G- C. p' ^9 P那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ! m2 w# g% |8 b
这是AGV_putin中arrive的method。
2 e  J! n' {5 S" ?2 `7 y. n/ ?, G0 R  a
当到达物料速度越高时,这个报警更多,

- T6 \! ]1 l) Q. ^5 d) }* R% ]0 V另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-14 02:43 , Processed in 0.020191 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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