设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7297|回复: 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' {4 i* c# B( k+ O*/
# O* f% T) M! H; q# \* Mis: W4 }, }  I  p+ l" O, q
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
" E. Z) K  C( j' edo) Q9 \0 ?; J; A5 |8 t" p1 i
        Lan := rootfolder.Internal.Tools.AOLlanguage;
/ L* N$ p. @7 {9 N% ]        if current = @.Destination -- else return
) s5 [+ `5 K. ]        then5 m% S, G5 u$ y, X$ p6 {$ ^
                @.Destination := void;7 K4 O. g" x- `9 C; _* n
                if @.occupied then
' \, H% I- S5 c6 y: J+ }$ d                        part := @.cont;
# q* P$ G; M' [9 l+ \6 N                        @.transpOrder := void;
* e! i5 _. E5 E" j8 I0 K$ L' Y                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,& {) v( X! d5 m/ R9 y% @
                                @,root.eventcontroller.simTime);
* T+ n# Q  a$ J) z' X                        @.HasOrder := false;% u' G" m2 p6 e) q
                        @.DrivingHome := true;4 W3 E4 U- w3 E5 t5 d0 a" N' d
                        rgManager.tryToStartTransOrder;; a7 i6 p3 r8 [, v# i5 G; R! u- {
                        if @.Destination = void4 r% g1 N* t% g' P% z: _' ?# c
                        then -- no transport order for vehicle @
+ M& T1 ?( ~1 O; q$ D) ^                                @.Destination :=
7 V) p  c* e7 B                                rgManager.nearestFreeStation(@,track.~);
9 c0 i" \% {! {2 j& L* p                                newDirection(@);   
0 ?* l, k0 y1 C& z                                if @.Destination /= void then
  i+ d0 {. ^9 @* n( m# w+ E. c                                        @.Destination.NumReservation :=# c9 r. V: e: s1 N$ V! g1 Z1 F/ q
                                        @.Destination.NumReservation + 1;
# K0 j% @9 o# u/ Z                                end;, t% o3 f% {! \% f
                                @.CurrIcon := "drivingHome";; Y9 L. Z  P& H, m
                                @.DrivingHome := true;
& f0 k" x5 r$ u& w* ^; C                        end;8 y, ]0 \+ Z. B- c8 w5 f8 }; D
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
% Y1 r6 X; {3 V+ \3 G# m" i  o9 ]                        part := @.transpOrder;+ i) y* f6 o$ p' M
                        part.move(@);-- load part5 N/ ]- J4 ?; V3 \
                        @.CurrIcon := "load";5 A8 r2 z; q1 k1 y/ ]7 |
                        GlobalDistObj := part.globDestination;" o5 Y7 h, J3 a' A0 |: @
                        assignLObj := rgmanager.rgAssignL;- X% ~: |% S" ]" o, |
                        row := assignLObj.getRowNo(GlobalDistObj);
+ e- v. b4 p% L% M& U. w                        if Row = -1 then -- since 70
- S  t( x3 g, \& d) I% B                                if lan=1 then
8 M$ S/ X6 F4 i+ N4 D                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
" c) D- ?* t/ `* M( q! Y- m5 Z                                                to_str("in der Andockstation: \"",?.~.name,"\""));1 X/ t. L' t9 F: q
                                else
# r% A( g* k6 [! E                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),+ G8 Y6 a9 Z+ m) v/ x
                                                to_str("in docking station: \"",?.~.name,"\""));                               
+ }* `2 t1 N  }' r3 T6 k/ D                                end;% c* P3 k4 c8 T# c" X) T) P: h
                        else
8 y& n2 e8 p4 |4 s% |                                @.Destination := assignLObj[1,row];2 L! w+ f6 u/ a; }; z& P" _9 I3 |
                        end;                       
, w- t' t9 r8 @/ O9 W                        newDirection(@);
! D+ x0 g6 w  D/ \* x7 C9 m                        @.HasOrder := true;
4 z; f' s  `* @$ K& j# J                end;2 X( F, h1 ^1 S- P% P( F7 B
        end;7 k' A, H5 C& g! T
end;        -- of the method  U; Q8 f+ q; c* X) Q" i* L) g
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 # |) P) `7 P( R3 s  |# M4 C% f

, n. i+ S+ m# G3 d' H9 Q$ N# [7 b% A这是AGV_putin中arrive的method。
+ j/ v+ ], J' T) c) H' h
# P  S% p) D- B1 B: P! D当到达物料速度越高时,这个报警更多,
* u$ m' u0 E2 V可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。/ P# q+ j+ `: y8 S- \: T+ L
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
: O6 f- Y0 ~. a* A% h7 p' v0 j
6 h: G& a3 X) t4 g3 U另外一个小建议,就是move,所有的move都可以这样1 H& N1 }- X8 E* u* g6 }+ r
if not move() then debug end2 E4 k; g# }' E' t
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。1 t# c4 N/ b3 ?1 V' D, `+ m5 Q7 d
plant simulation中的free libraries有AGV模板,
1 Z- v, d* T- q$ W2 P' N' X2 P里面也有案例。/ A' c& R& I" P7 H
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
: ^0 J. n% T$ r7 l; ~. S* F  V4 b8 h# X6 S
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 + Y9 t- X& ~8 Z7 D; _$ y
8 K/ S3 p6 I  }/ g! ^
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
( ~& M: z, P. s5 e; z4 S这是AGV_putin中arrive的method。
( v* l$ t3 L  R/ H/ p( B; J0 C# ?% C" W, a+ o3 E* C
当到达物料速度越高时,这个报警更多,

9 o* A# A+ |1 R+ [$ E另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-2 13:28 , Processed in 0.023715 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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