设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 10266|回复: 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') _  U; t3 {7 u+ [
*/
: p8 o+ N4 J/ `2 x  W) b2 zis. U4 p: |5 u' d  ~
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
# Z1 x, P0 J5 A0 o& ddo
8 S7 a! F% [- c) F        Lan := rootfolder.Internal.Tools.AOLlanguage;
" c" X; u: S5 B( P" M$ U        if current = @.Destination -- else return
0 ^" V* D' O  U( f, q        then
) I! F8 n* L  @                @.Destination := void;: ]3 ~3 k! Q4 t4 _: D& z1 W
                if @.occupied then( J& {! N4 g& O2 e5 r8 z
                        part := @.cont;2 }& i3 s9 h% V3 k' K
                        @.transpOrder := void;
2 f' k7 H* V2 ]; w8 r; O                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
/ g* D0 a; J3 H                                @,root.eventcontroller.simTime);
. ~$ z& D$ h6 d                        @.HasOrder := false;, r2 |! n1 c8 w0 q& x
                        @.DrivingHome := true;3 d! u& E1 m' G2 r
                        rgManager.tryToStartTransOrder;
9 t% D- T$ U% h, B, {                        if @.Destination = void
3 z+ S# R3 {; x                        then -- no transport order for vehicle @
2 P$ U9 r/ n  E5 B& T$ K) W6 g/ B                                @.Destination :=. @0 j# v' P5 E+ u2 `: f% r
                                rgManager.nearestFreeStation(@,track.~);
7 D6 e+ t3 m5 P  @& a3 v: E  M                                newDirection(@);   
4 o/ H, U, A  U: Y* P) ^# e' d" `                                if @.Destination /= void then6 W% K. x1 u' t- g4 p
                                        @.Destination.NumReservation :=5 h; P) s, K2 Z: j
                                        @.Destination.NumReservation + 1;7 Z1 H7 i/ ]+ j6 E
                                end;
' T' @! H/ P* p3 A/ [$ U. q+ t                                @.CurrIcon := "drivingHome";
/ ~& j0 ]  C8 l' W$ F% S' h                                @.DrivingHome := true;  u& {6 q- x4 x" b
                        end;/ Q. t9 C$ F3 k5 t4 l
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
8 c5 R3 y0 Z% C; `                        part := @.transpOrder;
' U( ]6 s* I9 v9 Z! t! G* }                        part.move(@);-- load part2 n+ U: S# y3 o$ A0 O) E2 h
                        @.CurrIcon := "load";
0 `' `- X, a1 X4 }# `8 C' g                        GlobalDistObj := part.globDestination;  q5 i1 d! s" @/ }" E% i
                        assignLObj := rgmanager.rgAssignL;: u. f1 Z0 F: L$ S9 V# x
                        row := assignLObj.getRowNo(GlobalDistObj);
6 b0 S) e" W& \1 o  X                        if Row = -1 then -- since 70/ c. m$ a! {. Q6 C: x
                                if lan=1 then* {+ `/ |/ v% n$ O
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
3 _# o1 M9 e- X5 [( L  ?                                                to_str("in der Andockstation: \"",?.~.name,"\""));
9 [  n* w# N8 H# f! D" d& e                                else! E  {4 x0 S# B6 g' s. [; F
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),9 ]5 z4 W& m; B# E! L
                                                to_str("in docking station: \"",?.~.name,"\""));                                9 x9 L# S% d0 u
                                end;
$ d. K5 z: |( L$ Q  s                        else+ o# F& W- J4 i: @
                                @.Destination := assignLObj[1,row];" \7 }+ V, p  x8 G. ~
                        end;                       
  R6 L. C, |# p0 p7 U                        newDirection(@);8 L$ v, G/ B2 x: h  I% V3 ^
                        @.HasOrder := true;
$ I$ l# B2 c: }9 F* r                end;6 l$ H+ X1 \" t9 ~1 ~" ^3 Y
        end;
( `" V. o8 a2 i+ ?5 \end;        -- of the method- P: Y8 o2 r7 F5 Q
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
# @9 Z: ^' ~! J: d5 y' n( m8 g0 K6 s  s' `2 c6 w, @# ^& d* y
这是AGV_putin中arrive的method。" S; Q0 ?4 Y! C- S' W
( x  k2 v* x0 H' O
当到达物料速度越高时,这个报警更多,; K3 V: M4 |2 \: j1 D
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。: s7 P8 {) i; A% Z9 {
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?5 M# P& U7 S2 u, Q
  d& y6 n* x( x+ q. z! l" d
另外一个小建议,就是move,所有的move都可以这样
, N4 }' \" P; d$ r9 hif not move() then debug end
" l: @- Q2 n7 {: f+ |9 D这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
' @. ~+ o0 |) }6 i4 T' zplant simulation中的free libraries有AGV模板,$ {2 ^5 p: S8 x
里面也有案例。
$ b. K1 ^& d0 {& \我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。& B/ ~. T9 w$ g: c! \- Z4 |

) N( B7 c, D/ C# `1 q我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
7 h+ F  E! [8 j( U6 I% G2 c. O, z" v* }0 R9 n; {$ M% t
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ; M1 k7 d1 K! W8 f0 L& l
这是AGV_putin中arrive的method。
0 y/ j9 r  g2 C. x" j- j4 w/ F8 b0 Z* D$ T
当到达物料速度越高时,这个报警更多,

: J8 O0 |  K* ^2 r  t* T7 k另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-23 11:50 , Processed in 0.040581 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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