设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9728|回复: 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'
3 q, A- H7 a8 I  }3 _2 K# `" J*/
7 J# O4 C- n* ?$ g6 R2 D; {is
! P  n% j  x( C8 e% j3 W        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
, c6 u, P) Y8 L+ ^4 hdo7 S( R$ U. W% x+ q
        Lan := rootfolder.Internal.Tools.AOLlanguage;- P- c: \0 d+ @3 h
        if current = @.Destination -- else return" g. @( R9 L7 w4 f5 Z" E
        then( W1 r; Q! V0 d# A' M9 g
                @.Destination := void;+ b5 \) F& u3 ?' s
                if @.occupied then8 a( M" o, Q& h; G# t! ^* e+ K
                        part := @.cont;4 z  U# n& G7 x2 [/ W6 T
                        @.transpOrder := void;' Q, Y4 r3 t9 f; \7 {
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,3 G7 e* @# _7 @/ h) n
                                @,root.eventcontroller.simTime);
2 Y0 @/ {6 g- T) j% o7 A                        @.HasOrder := false;
9 s# t8 M8 v& j! W                        @.DrivingHome := true;
0 u4 ~' ?) o7 Y                        rgManager.tryToStartTransOrder;( g) g/ z* E( k) V
                        if @.Destination = void
2 q% U6 l9 g9 M( v4 O                        then -- no transport order for vehicle @, R+ y4 s: `" {" b5 `
                                @.Destination :=
" ~8 Y- }# m' q8 B6 H; Q                                rgManager.nearestFreeStation(@,track.~);( p% z. I5 h' N# |! l4 W% q# Y
                                newDirection(@);   
7 j  R( E6 T9 g; p' \! p                                if @.Destination /= void then
, t& R2 |, v0 [  ]                                        @.Destination.NumReservation :=
- l' q8 y- K) b& Z                                        @.Destination.NumReservation + 1;
; l) [1 v' q9 N& `/ x9 Y) s0 [0 _                                end;
* C( |: }4 U" j4 a0 W, X; @0 O1 S                                @.CurrIcon := "drivingHome";! [0 b. W3 X: p& e' O% S) P% Z
                                @.DrivingHome := true;8 P1 q, G- L0 a. `/ ]1 }0 X9 m0 ^
                        end;' U7 l- {) u9 T
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station* o; E5 [) i" t4 ]9 `& W
                        part := @.transpOrder;# _7 Q9 C$ M# Q
                        part.move(@);-- load part
4 I0 D# d4 A' X                        @.CurrIcon := "load";: L$ d$ {) [0 F6 _1 A
                        GlobalDistObj := part.globDestination;
/ F; P7 Z" X1 z: Y                        assignLObj := rgmanager.rgAssignL;
) x" W" d' F  R3 p6 V                        row := assignLObj.getRowNo(GlobalDistObj);6 s# E9 j4 L. q! ]8 e  s- t8 I
                        if Row = -1 then -- since 703 L5 z( G  l9 L$ y9 e  X  z
                                if lan=1 then
, B9 i2 X3 J. Y. t! j9 c                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),: j: e" J/ ?. S+ c% x' {. V
                                                to_str("in der Andockstation: \"",?.~.name,"\""));
$ d( t% Q( d& f0 u4 H& s5 V                                else
7 V3 U- f6 e4 y, {5 L( w; L                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),1 l% B* E4 z: d! {
                                                to_str("in docking station: \"",?.~.name,"\""));                               
3 e. g  F8 f; [, U3 B9 n                                end;, A8 B6 N: i8 w# Z3 R! A9 X3 S: z
                        else, f8 B* ^6 F$ N* R! j' T. Z3 q9 k
                                @.Destination := assignLObj[1,row];
# u5 Y7 w7 h4 [& j+ I/ V( ~. ~                        end;                        8 ?# Y1 E& T- F1 P
                        newDirection(@);
) x2 m4 p0 h4 ~1 C& h; ^4 x                        @.HasOrder := true;
& L. O5 H* e9 P8 F$ y8 p  r. \0 ?                end;
; o  A8 K" i1 F2 X0 K" h7 J        end;* b- A5 y; Q; L' u
end;        -- of the method7 s4 C' J' n5 T: L
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 " {- {. u1 t# ~! Z2 @( u' K

% a' n5 b/ s' |+ z7 s这是AGV_putin中arrive的method。
5 R3 {+ @, f* M
/ H2 j* H: R; y2 X当到达物料速度越高时,这个报警更多,
* Y# _5 T( j, }3 b* x- D" i可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。: X# O6 d! R* l( r
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?0 {+ m2 ]3 ]- [6 }( v% M% _# B2 G

2 o9 T! c# U; \, ~" D另外一个小建议,就是move,所有的move都可以这样
; f7 S( _+ ~! Jif not move() then debug end
9 S6 K# a( Q& _) v: l4 r" o这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
9 r0 Z+ w1 s- g/ q! }plant simulation中的free libraries有AGV模板,
7 q/ p' k8 h$ I! W5 G7 \3 ?里面也有案例。  y3 D" k: c9 Q2 ^' W% h
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。" f! e) C! [1 I9 i
# i) I+ Y+ c" Q  U0 T
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 8 Q; u6 Y3 [* y$ j3 _
9 C5 m" O" ]% s) u8 _- V/ ~# e
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ) w& k) @; i  ^! @& \4 G  A" A
这是AGV_putin中arrive的method。' L1 Q' J  i9 L4 Q3 }6 I1 V
2 K: }$ I1 P. C) q' `6 K' P
当到达物料速度越高时,这个报警更多,
9 V8 S5 |5 \- w/ n- c  ]- v# }
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-20 21:17 , Processed in 0.017704 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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