设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8299|回复: 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'
9 X" F; T) T. L! ^" K*/
* F# [2 x: s" d6 {6 r- Kis" Z  O" C, `/ g% v* B  e
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;/ ^, d4 ?, k3 a( N
do  ]3 ^# u& Y" X2 u) i+ u3 z
        Lan := rootfolder.Internal.Tools.AOLlanguage;
+ W1 b7 e; c) |: ?* T! r        if current = @.Destination -- else return
4 w" w$ [7 E1 r7 n3 P        then1 b# x# l+ h2 G1 c' C+ u0 p2 l
                @.Destination := void;
+ Q  I. E$ {! J" l, D" ^                if @.occupied then
- W5 f9 V8 L5 R* Z: Q                        part := @.cont;
- D& v. o$ R  h7 ^- n. v5 f                        @.transpOrder := void;+ q$ S2 n  A" k# `
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
* E0 F2 ?* a( F, ~                                @,root.eventcontroller.simTime);% t1 B8 l' v& o8 F) ~$ t6 m5 Y# I
                        @.HasOrder := false;
% }2 `8 G3 `4 ?  K- T4 F1 a, w                        @.DrivingHome := true;
: S- u4 ], p$ j: z! B% C0 Z                        rgManager.tryToStartTransOrder;
0 N& V; Y+ {) O2 F# i9 E. R                        if @.Destination = void
: f% q! H4 Y/ x9 G$ p8 l/ _                        then -- no transport order for vehicle @. W7 U9 q% L% u3 \( a
                                @.Destination :=
" }! y! t  }- b, u                                rgManager.nearestFreeStation(@,track.~);
! y0 Y6 V. p" m0 f5 C, [2 s5 Z                                newDirection(@);   
* j" r9 Q; ?, T$ z, y) `                                if @.Destination /= void then6 U7 D; ]% M6 d2 M! r& V
                                        @.Destination.NumReservation :=! D' C/ c3 F# R& v- c
                                        @.Destination.NumReservation + 1;9 v7 B  Y( S2 a) x% O% g
                                end;
+ `/ h4 ]6 s  `                                @.CurrIcon := "drivingHome";
3 [; p8 ?& ]2 h- S* p( x                                @.DrivingHome := true;' q% e% t' k/ A* l  ~
                        end;
) |& t( D1 D# x4 O; m: Y1 }                else -- the vehicle @ is empty, both vehicle and part are in the same dock station* B, `4 i# V% I5 a' Z
                        part := @.transpOrder;# u, D# u) r6 D8 D9 S, I
                        part.move(@);-- load part
+ u6 `% a% b- b! w% \. [                        @.CurrIcon := "load";/ ^8 Z: B8 a# ^) z4 O4 p
                        GlobalDistObj := part.globDestination;  a3 P: q7 C; G" x5 g
                        assignLObj := rgmanager.rgAssignL;
8 P0 I1 O  @/ c+ F2 a7 u                        row := assignLObj.getRowNo(GlobalDistObj);$ M) Z8 L/ F; E! w
                        if Row = -1 then -- since 707 j, B" p5 C7 y3 W
                                if lan=1 then
2 k- p2 l6 E! U2 U% A. s) G/ T                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
# H7 m! X) Z& ~                                                to_str("in der Andockstation: \"",?.~.name,"\""));
0 r8 s+ H: F/ k$ H: d6 E                                else
* @2 y- k/ {: N7 @( c) C" N" B                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
. j9 m/ I" r$ G' D                                                to_str("in docking station: \"",?.~.name,"\""));                               
2 R3 }* B+ j: q: ^# {( H                                end;' |1 S# U9 X2 H
                        else
; I5 R/ a/ _: @2 ?  K                                @.Destination := assignLObj[1,row];' J7 M% x3 k) P
                        end;                          `0 X: C6 Z2 ~+ o. i' J0 N% C3 I
                        newDirection(@);, H( @0 y- y& P6 A
                        @.HasOrder := true;: _4 c- L8 F0 E! {' B* v
                end;5 o7 {/ h/ q! @, y; B- O6 x! e
        end;
' k" x  ]! K) R7 r6 e8 d2 g5 W* Cend;        -- of the method
; i7 N9 a3 {1 N$ a, C
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 * k& Y6 A' _# `& m
( ]  V/ y% G' N% ^" J3 X# i
这是AGV_putin中arrive的method。( g  |( V! v. G& G

9 Y- j1 V' S' U; `% _) J" J当到达物料速度越高时,这个报警更多,# Q3 O: x9 K1 p# J- e" I, T
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
) o5 Y' j" C( ?4 |程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
2 m, S* x1 M% J7 v( x3 i' L! {8 `' _! h
: U( J; X7 X% G7 h9 J另外一个小建议,就是move,所有的move都可以这样
+ e, s7 e$ L1 y% yif not move() then debug end; Q; A7 A$ F% X1 ]9 E# ~% V) _
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。2 n6 v4 C5 t! y! n2 T- [, W' c
plant simulation中的free libraries有AGV模板,5 P0 U( f6 M! s' D; L
里面也有案例。
+ {" e0 V8 p) M/ N: z( A. I: e8 {我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
' f4 K* U3 i* e& f6 L2 T5 B' |
. `& g  r0 i5 R2 t我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
7 ?" ]5 Z. R  O: n
. O3 T' B4 X' K8 b那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
0 Z/ Q7 Q) r/ s( L7 z; e, O+ f这是AGV_putin中arrive的method。
! f3 [- X, S- I* ]: j$ q( O; ~3 X3 q9 K2 M6 K; r* x0 r
当到达物料速度越高时,这个报警更多,

- u, T- V- D4 V4 m另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-26 10:58 , Processed in 0.019244 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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