设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5990|回复: 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'
% K) [; s* G) p9 L- q) Q*/' Z+ K9 @' a9 v) ]& `
is
; z# l5 O9 C, T/ |1 |6 F        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
. D! s: }- r- ?do6 H# G0 q2 C% a# Y; k: N  [
        Lan := rootfolder.Internal.Tools.AOLlanguage;
& l0 ]$ n! |9 r, s# P        if current = @.Destination -- else return6 R' }# v' T; E) Z
        then; i. F0 o4 W- ?% g# o9 r' _
                @.Destination := void;
0 U& {0 |) y) i/ w3 g                if @.occupied then0 m0 {6 ~+ \! j# }! `; l3 u" i
                        part := @.cont;( B, U, x$ a3 ]1 @7 a1 j( y
                        @.transpOrder := void;8 m: B) U: a, D* m+ R! E) y
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
7 |6 |& y: b; \, e                                @,root.eventcontroller.simTime);
6 F+ l# e1 h5 u( m                        @.HasOrder := false;. h8 {- ]) ~" R0 P7 ^
                        @.DrivingHome := true;
- P6 W0 ~# R6 E3 w7 N! |7 g                        rgManager.tryToStartTransOrder;
; H( z+ W! i' D/ Z3 U                        if @.Destination = void
/ c/ E! _8 N: X% X9 @2 E# a- H6 f                        then -- no transport order for vehicle @
! I& x$ w5 D4 c* }& N2 \0 x                                @.Destination :=' R# g. Y, B8 E/ D3 L
                                rgManager.nearestFreeStation(@,track.~);/ R5 z. r9 n! c* I
                                newDirection(@);   
0 w, \8 d7 `3 B8 S                                if @.Destination /= void then
: `. h) H8 v/ [( x/ Q                                        @.Destination.NumReservation :=
. _) y/ Q! R1 O                                        @.Destination.NumReservation + 1;
; |; G9 `0 y9 k4 f2 [  f                                end;9 Y" H; s9 e1 K9 E4 i/ O! h' \
                                @.CurrIcon := "drivingHome";% K" B; j5 E; v8 ]. T; _$ L7 J
                                @.DrivingHome := true;# e% |- Z! {( ^
                        end;, r# \. O$ }9 C# g5 A
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station& V- h! }# o! t/ ?1 z
                        part := @.transpOrder;
% @+ ]1 I0 k# g7 Y8 l" P+ X; |6 g) @                        part.move(@);-- load part: Q, M, U/ p& m4 H
                        @.CurrIcon := "load";
( O4 \' U9 [- A" ]                        GlobalDistObj := part.globDestination;
5 z0 W$ u" u9 r                        assignLObj := rgmanager.rgAssignL;
# |+ b  r3 E- l$ m# j6 X9 b" r1 @" e                        row := assignLObj.getRowNo(GlobalDistObj);
" n+ ?/ t. ]* M5 i  u: ]$ y                        if Row = -1 then -- since 70
8 _% ~, c) M8 K( _- M$ V! R% A                                if lan=1 then
( \8 U( l. J! `' _& c1 H                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),4 `+ [6 d- z3 |+ w* Q
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
: c! \. R- R# x2 M9 {8 |! t                                else
5 f8 R, `! b! e. L2 I# z; G                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
% E4 g* p2 r' A+ l: ^: G                                                to_str("in docking station: \"",?.~.name,"\""));                               
6 H1 ^0 `$ @/ J& X* q                                end;6 i: i+ q8 \1 @$ ?
                        else4 T4 F# \3 M( \% C8 s
                                @.Destination := assignLObj[1,row];
2 D% l" D9 h( N- {/ v1 n) Q                        end;                       
- J- i$ e+ w" \" u                        newDirection(@);
& f7 _- F0 t0 T' _- E                        @.HasOrder := true;& L& e# l$ p1 C. t; k" e# A1 |4 R6 ~
                end;
- I3 u) ^% m  y& y7 B        end;
/ E2 c; x6 t. o4 w5 Y4 _' gend;        -- of the method
+ L: l0 ~9 o  O: Y/ u% Q" V; t
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
* d/ s7 J* A# z, Z. F6 n' c1 s, t# p9 {( R' a
这是AGV_putin中arrive的method。9 E; x/ M, w" s1 o, H
9 f/ _$ m$ B7 g+ t7 _/ y
当到达物料速度越高时,这个报警更多,. ~' {* K; Y2 ^. f$ @$ ~
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
0 y: Z4 z, E' ~) n' F程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
" H# x) t8 j( s. z6 h- w3 B5 C
# r" i7 X+ L* d* U5 ]另外一个小建议,就是move,所有的move都可以这样$ X" y# ?) `/ I
if not move() then debug end" W, y5 r' G2 `; `7 a4 h
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
& C% B7 B! b8 w" p$ m5 P% bplant simulation中的free libraries有AGV模板,
* q8 w1 R- K: S/ d4 z: C里面也有案例。
2 l* s4 b% X) e+ V2 o4 x我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。5 M5 t7 S2 K: i* g
( E, c' w& k; x  X$ K" E3 n- H  p4 A! S
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 # i) k6 M8 C% K  O  L1 D8 a2 C
0 V! l0 I" w1 w2 o6 c% K
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 9 T  y0 F5 n' {7 H; E! z
这是AGV_putin中arrive的method。" T+ x7 T8 S, s

, Y6 G# Q/ [  D" h( z- l当到达物料速度越高时,这个报警更多,

; C: z( J6 P9 ~0 f7 R& C另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-1-11 17:16 , Processed in 0.018124 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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