设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6429|回复: 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 D2 b" s/ ?) ^4 Z
*/
7 y! Z/ q( }9 c+ {+ t3 Vis
/ F: J4 }; L& Z) L2 ^        part, GlobalDistObj, assignLObj:object;row,Lan:integer;6 @1 T. p* h. r9 p+ f5 k
do+ w6 h# [7 b3 K( r' o6 d9 u3 I) z, F
        Lan := rootfolder.Internal.Tools.AOLlanguage;3 g7 z  w' z) F6 R, I
        if current = @.Destination -- else return4 v/ {0 [. b. \% C$ m' g
        then
# f9 ~& f+ w1 w3 w+ F- v- |                @.Destination := void;
4 m( n/ q$ W. x4 ]" R9 M                if @.occupied then
) ?0 E% i* o8 Q1 _% T$ j                        part := @.cont;
. l* Y! J! v) O0 }: ^3 a                        @.transpOrder := void;0 q$ M5 y3 u* O; T+ j# p
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
0 @, W: E0 Y  j2 l                                @,root.eventcontroller.simTime);
$ N2 T0 k1 K0 o                        @.HasOrder := false;
+ f2 R0 D! a4 e& N# V+ o, S* F7 F                        @.DrivingHome := true;; U% h- k& L8 ]: J. p4 G* i
                        rgManager.tryToStartTransOrder;) v2 Q8 S  H. Y0 R4 |9 E7 b% \
                        if @.Destination = void6 B$ J$ K# A: K3 k
                        then -- no transport order for vehicle @1 Z: k2 g& n; Y& E5 M
                                @.Destination :=
/ n5 L* \, E" x% N                                rgManager.nearestFreeStation(@,track.~);; x% U- d+ J4 {  C; V
                                newDirection(@);   
3 O/ a" P+ K; `4 B0 `0 i                                if @.Destination /= void then
* A: _" f* G8 I" N8 |                                        @.Destination.NumReservation :=% |' c# m: b4 T+ y* N
                                        @.Destination.NumReservation + 1;. y# y6 q; }1 d9 q7 K' n
                                end;
( x& L/ B! z' @( D                                @.CurrIcon := "drivingHome";
6 \8 N' T# ^  v+ l                                @.DrivingHome := true;/ V9 E0 H& l0 |" o! M# n. X, |
                        end;
! t/ i) x( B6 I" r+ r                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
0 b. H9 f& |5 {" y! c7 f                        part := @.transpOrder;
$ A: ?! ?4 I8 X* m                        part.move(@);-- load part
  h0 R$ S7 Y/ F6 v* C8 U" |                        @.CurrIcon := "load";
- M8 Q: X9 G% B8 V+ s                        GlobalDistObj := part.globDestination;
! q8 Q' F/ T6 H, |4 [                        assignLObj := rgmanager.rgAssignL;
0 H5 Y  V5 g- N1 u% ^: _4 z                        row := assignLObj.getRowNo(GlobalDistObj);" j; D, y9 R  Y5 i
                        if Row = -1 then -- since 701 W: \) d' ]6 M  D
                                if lan=1 then
6 K7 L% T1 w' i; a4 ^7 I                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
" T, X! o8 Q3 p* x4 ^  d                                                to_str("in der Andockstation: \"",?.~.name,"\""));! q% s& @: U6 l$ s0 w% V  K
                                else
3 ~/ I$ l- U- t" S% C                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),! X3 g6 j) p8 e4 B# o* U
                                                to_str("in docking station: \"",?.~.name,"\""));                                ( W) J0 ^! c# O3 j- `# J
                                end;! k$ k7 o7 h2 E! n
                        else
+ d0 _- {; G% U! j+ n                                @.Destination := assignLObj[1,row];' R* _8 x6 V; Z8 Y% I
                        end;                        , u- Y  n# F* Q
                        newDirection(@);) Z1 H) F- `. X& W: N
                        @.HasOrder := true;
5 D' L: r0 |! t! h                end;
- A7 R  s" p: B" S$ x        end;
/ N4 _5 z0 z: i# e! E3 \end;        -- of the method
: r& g- S4 n& Q- R8 o, ^
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 " L4 ]+ y6 u4 v

; ~8 ?; m3 e3 P5 D这是AGV_putin中arrive的method。7 z5 Q: U! A5 P5 _7 M/ M
2 p7 g  k; Y- K9 k* l
当到达物料速度越高时,这个报警更多,& r& p/ y- r4 s; J+ d" f6 I
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。/ a4 g9 A; A6 ^7 |
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?+ P; W7 k( X1 ^. E, V' V) n
; `, P$ L6 k9 Y( X
另外一个小建议,就是move,所有的move都可以这样" `" x7 q# J6 \- p  y
if not move() then debug end
/ `, x! f" I+ ~这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
6 E# B9 u) [1 T/ @0 G; qplant simulation中的free libraries有AGV模板,; k$ p) i; L9 |
里面也有案例。
& ?, R$ Y4 F8 d我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
* u# B! B7 ~9 a, P4 x4 D% G. k3 ]' P: j) A0 ?
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
; ~: T/ H( D" p* s6 L0 R0 R, g  A: k" P, i8 \8 o
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ! ~: V6 L+ [2 \8 u, z
这是AGV_putin中arrive的method。
8 x1 k) B5 Z2 ^& Z# y5 d' L
) w. _2 t4 E2 x' _; t0 U3 V当到达物料速度越高时,这个报警更多,

# S4 f: M3 y& s1 [, E* ?另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-6 04:40 , Processed in 0.019549 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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