设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7662|回复: 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'
, V7 c9 |  U% |6 ]& C*/
6 x2 p4 B: L+ J* h3 V% A6 _is
- Y+ N6 `# O' D$ \        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
# Q- q" z1 c6 U! Ydo
  z' J+ S- {% {- [+ P5 p0 q5 J        Lan := rootfolder.Internal.Tools.AOLlanguage;
/ J' p$ c& G/ |9 v7 y        if current = @.Destination -- else return; }. z2 {  {0 d: K1 J" [
        then1 F. M1 A3 r1 b1 C" y7 N( i
                @.Destination := void;
* g  N8 }9 b: m9 L. I9 w                if @.occupied then) K% g; N1 p! i6 P
                        part := @.cont;
+ @# n/ C5 y9 P4 V9 G- n0 q                        @.transpOrder := void;
# ?* M+ k$ C2 ?% f% E! R/ C2 m8 R                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
% e. r  Q" u/ {                                @,root.eventcontroller.simTime);
6 e+ [  K9 \/ u                        @.HasOrder := false;/ w) _& {  P, \8 R
                        @.DrivingHome := true;" b% `. {/ P3 _7 Y5 n% c. U) Q
                        rgManager.tryToStartTransOrder;
* Z$ l) D1 ]: N4 R# p                        if @.Destination = void
. }% t3 j: I- L; ^) T# R! N                        then -- no transport order for vehicle @' e% t% T( j" _9 S6 D! H
                                @.Destination :=
* P3 ^5 a3 \4 v! p1 ~  X                                rgManager.nearestFreeStation(@,track.~);- b6 ?4 {; [& D* e
                                newDirection(@);   
! r. P5 e6 F9 F2 T5 D. m$ y  Q                                if @.Destination /= void then1 q: L0 l! t, H! k- d
                                        @.Destination.NumReservation :=
9 Z  C! [# ^8 O2 \  Q1 H                                        @.Destination.NumReservation + 1;, P+ B! P. W2 w6 V6 Q. f; T
                                end;
$ f- d2 d. o7 q3 C2 q                                @.CurrIcon := "drivingHome";0 U5 U' N  D1 j1 I
                                @.DrivingHome := true;9 {( D: N% F2 M5 }2 r9 z
                        end;
0 i) g' t& z4 c+ [# w                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
! R# ]+ q+ A6 k( X% e                        part := @.transpOrder;( ~) k5 I. [, b+ i
                        part.move(@);-- load part
& K' }( p( ?* L4 u  k3 E4 s                        @.CurrIcon := "load";
  E# X0 @9 C6 j. l# x+ o                        GlobalDistObj := part.globDestination;
" k1 d; h, C9 U! H+ T                        assignLObj := rgmanager.rgAssignL;- Y% w" D+ |3 p  q2 z3 t" i
                        row := assignLObj.getRowNo(GlobalDistObj);
# A9 f1 B1 Q+ ]" G7 M; T" a" [& y                        if Row = -1 then -- since 70
0 f5 X0 W- w5 z2 O7 L                                if lan=1 then
2 d$ Y% C' B) J/ p/ a' Y                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
2 ]* G4 W) U+ I9 X! c6 V                                                to_str("in der Andockstation: \"",?.~.name,"\""));+ J' e9 m' M$ X$ F. y1 [& S" y; j5 H
                                else  j1 a: O$ g! Q' y
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
& ]7 S- z' A; y( \3 p2 h& s                                                to_str("in docking station: \"",?.~.name,"\""));                               
/ a6 b( [) i) R& N& U4 p                                end;  L' m* s4 c+ ]5 s
                        else
% Z" u1 C/ u5 |- G2 b4 o                                @.Destination := assignLObj[1,row];, Y2 s% Q/ H/ ?% L
                        end;                       
- V( P7 x0 N9 |' ?- R                        newDirection(@);1 v% i" P- Z& e/ M+ l1 e
                        @.HasOrder := true;# u/ p, \6 S! p8 F' x8 `# A9 G
                end;+ h! j/ ]. J  y* G
        end;+ v4 g+ U1 b8 B) X
end;        -- of the method
; z' ?4 R) _/ u" E- t" i
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 0 a. r: l8 Y, u7 T5 J! s0 D( S$ B
9 j1 R/ a; o6 @2 j2 O( w4 D1 F" g: T
这是AGV_putin中arrive的method。. C; u2 j. [. n# G* W' c1 b

/ u) P) @, }8 D+ s/ b- }+ X当到达物料速度越高时,这个报警更多,% y0 J/ m4 M3 n; `
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。' ~0 J: D/ }- T" S
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?$ {, R* q4 |2 S/ a

1 a" ?4 M' b5 a1 K  |另外一个小建议,就是move,所有的move都可以这样
0 m6 W, {6 J7 D& m- gif not move() then debug end3 `% X& J4 P7 h
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
9 V. O/ h5 D; N, S: W$ lplant simulation中的free libraries有AGV模板,3 S2 e! t% [8 o/ s
里面也有案例。+ n$ j3 @2 z) d( x& B
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。) G; j" _+ e9 }& Z
4 t0 w+ G; w; A
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
* O  U9 m5 U  a) f9 d" \
  ~$ C5 [8 i- D* N( q  R+ h) g那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
8 i* K- D  V$ l这是AGV_putin中arrive的method。& }8 Y2 ]- N& k4 O# I9 L/ o8 o
5 a9 A0 @; g! n3 i+ x! d# f
当到达物料速度越高时,这个报警更多,
. ^1 @* W9 {8 [" X) M& C
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-23 01:53 , Processed in 0.022282 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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