设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 8202|回复: 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'
, P9 Y* L6 b0 w% Y- `# ^*/( A) T" ]- c7 D( x( C) g6 v
is. V& `* U: o/ J& q
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;1 v8 _% d. @2 e+ O2 s1 C
do
2 O- ~/ Z; ]. l' T        Lan := rootfolder.Internal.Tools.AOLlanguage;
( Z# B( l' E$ s6 s3 H% j3 |        if current = @.Destination -- else return
- a0 y; C+ |# i2 O1 w: e        then# _) a5 _; n% V9 r6 C) s3 M8 |% w+ p$ ^
                @.Destination := void;$ ^& u+ L  B6 @3 k
                if @.occupied then) e7 E& ]" @  k
                        part := @.cont;
6 q% _. @; i3 A. ^                        @.transpOrder := void;
2 x9 P( m- V2 Y( D( l                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,. U1 L9 w, g9 i7 B9 G- x
                                @,root.eventcontroller.simTime);) i( P, G: a1 y- \) B" s# O9 c
                        @.HasOrder := false;' l9 ]# M7 Q3 _# w9 f
                        @.DrivingHome := true;
' r( q8 _! y6 ~# f" [                        rgManager.tryToStartTransOrder;. r, M  E9 j; j8 R% Q# M7 c
                        if @.Destination = void
' y" S. H* `1 k  f* ^0 _* T% S9 N                        then -- no transport order for vehicle @2 t8 Y8 |% z& n/ Z0 h1 X+ r
                                @.Destination :=% U; A/ l2 p7 `. ]5 W' W0 Z& F- [
                                rgManager.nearestFreeStation(@,track.~);$ v4 N% v3 x- n( s8 f5 c4 W
                                newDirection(@);   ! t1 F" l6 i2 y0 n8 R, \* Q0 d
                                if @.Destination /= void then
7 k$ B. a7 l* U+ E6 I: }                                        @.Destination.NumReservation :=; F9 A4 A. H: I! u$ E' B3 x
                                        @.Destination.NumReservation + 1;
' c+ l6 P  u1 F1 G: f+ T                                end;5 L' W/ S7 a- ?6 y  q; @
                                @.CurrIcon := "drivingHome";3 l+ F3 Z, ?5 Z- d/ M8 L
                                @.DrivingHome := true;- P$ X5 ^2 r9 b/ r( U+ [$ H
                        end;5 ^2 j- W2 Z7 W# ]* a
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station2 f- [" C6 W- B. j& i
                        part := @.transpOrder;& l# j9 K3 L5 Y9 v8 m
                        part.move(@);-- load part
# C  _/ q, N( I                        @.CurrIcon := "load";' v" ?7 F( u7 Y. O3 g
                        GlobalDistObj := part.globDestination;
2 a! `- u' x5 p2 {2 s/ P                        assignLObj := rgmanager.rgAssignL;- m4 m# a1 T2 M+ g, H
                        row := assignLObj.getRowNo(GlobalDistObj);0 R( {8 a, E- Q& n! x, M8 e
                        if Row = -1 then -- since 702 f3 K- }& T- X8 m
                                if lan=1 then7 d/ N, I; y! U/ x" u* N# M4 Y
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
' |7 m' g, s5 |  V9 W5 S3 }                                                to_str("in der Andockstation: \"",?.~.name,"\""));) u8 j8 E, \6 X" b
                                else
) p& D6 R! E6 f" j7 D5 ~1 F                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),1 v4 |7 m- Y6 y& Y
                                                to_str("in docking station: \"",?.~.name,"\""));                               
! y" u" C3 W% s' t                                end;
7 F$ k9 H7 h8 |# z& J; s: X0 n                        else
  b) ]' `  ?* y1 e  h/ c9 m* z; u                                @.Destination := assignLObj[1,row];, K& @, f- B6 N( N, Y+ u1 i+ j
                        end;                        7 h6 u$ w7 ]1 `; c! Z# N) Q  \+ q
                        newDirection(@);; Y; o" e6 K, z+ ]3 {0 |1 m) ?
                        @.HasOrder := true;+ Q1 h: g, Q5 L* h& |. j: }
                end;
- ?4 @9 }1 r! J) H        end;' I6 h" g- `1 i5 Q' B8 F
end;        -- of the method7 m" i8 g  M/ i) r' ^& h( x
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
$ v% m+ E  _. U4 H. g+ [
2 s' w1 \& p  }这是AGV_putin中arrive的method。: |+ w; b) L3 L
3 g: T( v  {% Q/ Z7 b2 |
当到达物料速度越高时,这个报警更多,( e8 b5 [. V% M+ c* w
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。4 _2 P" v6 {% `; a: o
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?( g6 b  `6 f; f( X" J( }: L
0 B6 n% ~2 o9 Q; `2 C
另外一个小建议,就是move,所有的move都可以这样  ^7 g1 ^! I- n; Q' p
if not move() then debug end$ j9 i3 B! ]1 N5 |4 X4 N) k
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
  n' J( c6 T' u/ Xplant simulation中的free libraries有AGV模板,% }8 H9 a$ ~+ P- \+ ?* K
里面也有案例。
% ?9 M( m. b. R9 W* |我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
, W8 i, S9 E" W5 i5 S, Q2 K, L) A! f3 A% m5 u+ w9 _, Y6 d+ \
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
' J$ N( \' B$ h. \; u, A3 S: ]- x$ t! W/ ]# L0 L- _5 B- h
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ' g' V2 @) v* _% \
这是AGV_putin中arrive的method。
  ]2 o/ F1 t, o" q/ n9 K& P
) c3 X' |* T+ S! b0 F  _+ \当到达物料速度越高时,这个报警更多,
- c/ |" B( @! M7 |8 u- \( h
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-5-20 15:20 , Processed in 0.019425 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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