设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 7826|回复: 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'' C. W4 ?8 `+ d4 v! @5 V1 n. s( l1 G$ W
*/
7 L5 a# O, n: A! b. E  ^is/ O+ B0 w: s6 b. I1 t( H
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;" k3 z# X8 W2 p, `- f
do4 F* R) z2 X) W% O$ u  a
        Lan := rootfolder.Internal.Tools.AOLlanguage;
2 I% \1 P4 v  Q# m        if current = @.Destination -- else return
- ^$ E+ k: Q+ @, y/ o2 {/ t        then9 q3 Q" C/ _& M) J4 z
                @.Destination := void;
) c9 H2 `6 ~# ]% q$ s  o8 h                if @.occupied then
! Q! M6 L8 F& ~/ J                        part := @.cont;
- C8 z, L) c6 C) [. _. f                        @.transpOrder := void;" g) ]. Z: m: l3 U
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,7 H5 |% v0 U3 A) D3 b
                                @,root.eventcontroller.simTime);% ^2 L2 A9 f3 \- e8 d# V: I
                        @.HasOrder := false;: r" w' ^# p+ e0 ]! t
                        @.DrivingHome := true;
; g6 G& s) s/ C$ a3 W                        rgManager.tryToStartTransOrder;
" `# M" Y: f" k' W) E                        if @.Destination = void" i! Q" ]7 i' p- Q+ `* W- A  P
                        then -- no transport order for vehicle @# m, L/ S2 j% j9 f6 n& x
                                @.Destination :=
/ T) V  M$ {# N+ E                                rgManager.nearestFreeStation(@,track.~);/ ^: R7 L0 ?1 n# w" C# a2 e  o
                                newDirection(@);   
+ O8 _% N3 |5 o                                if @.Destination /= void then
# [3 l! l: D& T0 s) J+ d7 C                                        @.Destination.NumReservation :=; D  U& X' P/ f# X
                                        @.Destination.NumReservation + 1;# R( e8 Z2 |# I! C+ @# k
                                end;5 k6 |( [6 E3 x
                                @.CurrIcon := "drivingHome";( o- s# O+ x. I5 m3 v
                                @.DrivingHome := true;
/ s# l5 d4 |2 r/ j* \+ R                        end;
* Q. S) R5 C3 K, e* \8 m3 p% f8 f8 ~                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
1 {. Z, j' }0 R7 k                        part := @.transpOrder;/ H& Y# g/ n1 j5 ^
                        part.move(@);-- load part
  ?# j5 d6 b. T4 j- s* X" ?                        @.CurrIcon := "load";- G1 m/ Z4 M: K% i
                        GlobalDistObj := part.globDestination;7 i* x+ c: t5 `$ K* O
                        assignLObj := rgmanager.rgAssignL;
& y$ E+ w3 u, L" z# P" ?4 X4 @                        row := assignLObj.getRowNo(GlobalDistObj);0 f5 }+ T8 x% c) D' |
                        if Row = -1 then -- since 705 E% b4 Q8 t) l
                                if lan=1 then
& K2 b3 X4 D' k/ V! i                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
: P) p( H+ j7 A1 _. G% h: K( R3 Z                                                to_str("in der Andockstation: \"",?.~.name,"\""));
1 o) [' Y6 W# s1 V- R: o& ^. c/ W                                else1 d# C, i5 ~1 i( S1 F+ z
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),0 F$ ]* ]: {+ U# |4 U+ k
                                                to_str("in docking station: \"",?.~.name,"\""));                               
% Q2 v: w/ e/ n+ n                                end;
4 z- _* Q' G" N: {                        else, U3 Q  ?: ~: q9 c( T
                                @.Destination := assignLObj[1,row];
- K: F$ U  A4 |                        end;                        7 u! z# k* m4 i0 m
                        newDirection(@);
" w. Q! X6 u8 ~                        @.HasOrder := true;
& y: ]6 [$ D) {( S( {  z" r                end;3 A, N6 C+ G/ w# [
        end;9 |! D( j$ C+ W4 b' ]
end;        -- of the method, ~( I4 A, h8 C% p6 E6 X4 S
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑   U" V# h+ n1 K8 d) ]+ d

4 I- T8 O( |3 s; Y$ _% Y5 j这是AGV_putin中arrive的method。: L! u! T1 x" I

7 r8 B1 p; o* s: |% l) V当到达物料速度越高时,这个报警更多,
7 |6 i/ d3 t" Y# m+ k6 G' [6 w* E可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
' R4 U6 z2 q$ ^* S% P- |程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?
$ Z1 {' Y' W% G( o5 E) s" X) @4 C- ^7 W
另外一个小建议,就是move,所有的move都可以这样, Y6 z1 y) L  h) S- Z& E: ]
if not move() then debug end
+ A- `! n7 _8 ~* r这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
$ |5 c% t$ o. m& splant simulation中的free libraries有AGV模板,
! a, @6 E) D) S( F" o4 F$ J1 `+ z里面也有案例。/ P, P, d3 }9 j
我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。& ?5 N* y- e3 S: M' @; q7 X
! f* E. [( R" [3 ~0 C* T8 Q+ [
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑 9 g) B( A5 g: `8 d' }! b! ^, A

0 k* p4 a) X3 n% ?, \. H) |6 B0 C那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
* T2 U+ t) M5 z2 Y" ]6 \) W9 }这是AGV_putin中arrive的method。7 [) @4 y  l* K" C6 Y

+ |; k, b* X. X8 H  T0 L当到达物料速度越高时,这个报警更多,

, z7 L; s% U7 G另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-4-30 18:20 , Processed in 0.017930 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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