设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9245|回复: 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': |7 ?3 \3 J6 S8 a9 ~
*/
9 _6 E" O3 M  o0 c9 Xis
% `4 C7 l2 I" E1 P2 t+ v; B        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
; C1 g0 y. |( {) Y! @2 ^( pdo
9 @% t9 f0 ~; O7 v# A        Lan := rootfolder.Internal.Tools.AOLlanguage;
7 s1 y2 ~) L$ F  _& |        if current = @.Destination -- else return, o$ \1 ~3 C$ q. y7 u
        then
2 e# C( H7 M, x                @.Destination := void;5 [" ?, o4 [( D5 i% \
                if @.occupied then& [7 [9 M( Y2 G/ K
                        part := @.cont;1 r5 s9 `1 k7 s/ J) b! y5 J, Q
                        @.transpOrder := void;
8 w3 `9 W9 @4 r2 Y' r1 L* p$ _                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,: i; |$ E' B8 Y$ x" z: I9 Z
                                @,root.eventcontroller.simTime);7 s, q0 J0 j$ T3 i2 D1 J, S
                        @.HasOrder := false;
& ~# D+ C' k& ?: d" g                        @.DrivingHome := true;) s; s# |3 `. Q+ @& y5 n
                        rgManager.tryToStartTransOrder;% A$ X9 L  h  m! u: V3 w# R
                        if @.Destination = void
5 b' j# |. ^$ j- V& o' X+ L                        then -- no transport order for vehicle @7 ]9 l( E  Q4 N) I
                                @.Destination :=
2 C  `1 S3 t6 ?' L6 v: Q                                rgManager.nearestFreeStation(@,track.~);
; J7 L2 U' Q/ E# P                                newDirection(@);   , {/ _! y0 a2 y8 Q& Y
                                if @.Destination /= void then# m3 J4 c$ z9 U8 Z
                                        @.Destination.NumReservation :=
- V2 [' j/ }) c$ y& _/ M                                        @.Destination.NumReservation + 1;+ |% r; K( S' ^* |, F/ w$ B
                                end;
  q, M$ W% K4 i3 \0 f                                @.CurrIcon := "drivingHome";& O$ i! E5 o7 r' V  |+ f2 F
                                @.DrivingHome := true;% F* T! f# X0 R. H! ?- N# J
                        end;
( L) q1 Q  v( X5 ^7 \/ q: c. o+ B                else -- the vehicle @ is empty, both vehicle and part are in the same dock station2 i7 S6 F0 ~; x" g- a
                        part := @.transpOrder;1 U+ [" T7 C4 x# |; E( G% p) h& P
                        part.move(@);-- load part
3 E3 o; h3 g7 B/ x5 u% [                        @.CurrIcon := "load";6 p9 d9 o( `7 \
                        GlobalDistObj := part.globDestination;
+ C- k; e) c+ d+ p( d9 i0 C: z+ e                        assignLObj := rgmanager.rgAssignL;# }) @: `# W% u2 D8 n6 ^& P
                        row := assignLObj.getRowNo(GlobalDistObj);$ b2 t& |0 X# F* f
                        if Row = -1 then -- since 70/ {$ ?& i' j1 S6 j* P. X
                                if lan=1 then  d* x4 a1 A' }+ j
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
- h. v+ C, g9 f. V1 ]' |                                                to_str("in der Andockstation: \"",?.~.name,"\""));) ~0 E5 y4 E  N3 e  W
                                else- f' o, \* g2 v$ V* l* w
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
& \+ {( }# V' v& _; b                                                to_str("in docking station: \"",?.~.name,"\""));                               
0 a* L1 Q3 T2 V- M4 F7 t+ @% f5 U$ T                                end;" V, A# A% \3 p3 K
                        else0 u1 O, \0 Y" X3 B/ V. w& M
                                @.Destination := assignLObj[1,row];
; h% T4 P8 k) W. v! D                        end;                        % i( X5 b, r# W7 m
                        newDirection(@);
; [$ S, t' I. z, w  n- S                        @.HasOrder := true;1 I. Y4 ^: h8 j  r% h$ R! P, j3 B
                end;  K$ T% @- j- M& s8 N  k" {4 c; o) t
        end;: l, ~9 r. U/ s) ?$ {* l$ s
end;        -- of the method
7 T: H" N+ `  H0 H  d
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 5 N6 s: c/ Y- J, {- c! y: m

' s2 C- R7 `1 z# r+ Y" z! @这是AGV_putin中arrive的method。0 e- z' w1 z8 j/ d# t
3 p$ q1 v6 a$ K) S5 v: {
当到达物料速度越高时,这个报警更多," y) i, W' m) ]2 G. o* @2 I
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。0 o. o) ^% Y% G, G
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
1 G  }  s5 n* R& ~9 {( R+ _! r0 z
/ i- m6 Z8 D: S另外一个小建议,就是move,所有的move都可以这样
+ V% a6 ~& ?( C" S- Mif not move() then debug end; s8 x7 T" z- }
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。1 k8 H0 Y/ a7 {
plant simulation中的free libraries有AGV模板,
+ @: T- x/ f1 V+ [" s( Q里面也有案例。
5 C. P( k. @* l我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
3 p/ J, {9 k! W- U1 _# ~2 w& T9 i2 L# E" v5 B. T+ v. Q, q
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 9 a" v- ]+ k$ J* R" W
2 J. `8 f4 E2 m" @1 c1 I3 A" S
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
, ~1 q, T$ p" O" N; ~8 \# _4 V7 G这是AGV_putin中arrive的method。
& d5 J* h8 _3 ~. ^5 Z1 H1 y1 t0 L( u0 h' S0 ]7 X6 i' T+ J% \
当到达物料速度越高时,这个报警更多,
, l, j) T4 j! P+ N5 T/ h: o2 P
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-7-20 22:20 , Processed in 0.015525 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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