设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 6704|回复: 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'
$ v9 b6 S4 f* w2 Y  K*/
! k3 m* e# e* qis
9 U2 H9 @: e1 J+ x! C/ Q        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
3 i- Z# S$ U  Hdo. j  h, O* l. h
        Lan := rootfolder.Internal.Tools.AOLlanguage;$ |5 N4 k, x3 B7 T  o) W" D$ B: S: ~
        if current = @.Destination -- else return4 J( M# o1 G) t
        then2 I; g) b" @  m
                @.Destination := void;
9 A9 ^- |+ M, L) A! p                if @.occupied then$ C  i; Y( Y7 l0 |' _
                        part := @.cont;6 r; C" q! p. C+ E$ Y' `6 V
                        @.transpOrder := void;
% ]: K1 L; w/ ?                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,8 F( v. D! T. \. r
                                @,root.eventcontroller.simTime);8 B6 O$ }6 k1 V
                        @.HasOrder := false;
% Z' [3 P6 M) ]+ ~- B; z6 Y                        @.DrivingHome := true;8 o" Y8 g6 _4 i0 e7 F  T3 B
                        rgManager.tryToStartTransOrder;
; U. R, T1 b% n                        if @.Destination = void; i- l  f( Y& _1 R! O1 f; h" K
                        then -- no transport order for vehicle @9 U2 U* |: X$ i8 b# l2 F- z4 k
                                @.Destination :=& p9 y4 o& S9 m+ i
                                rgManager.nearestFreeStation(@,track.~);
2 K- n# u% u' ~  N( R                                newDirection(@);   7 d; c9 c) [8 m  C
                                if @.Destination /= void then
6 `4 r  j6 A' @# I: j2 B                                        @.Destination.NumReservation :=
/ N& `9 V0 Z1 I0 n/ G! C8 }( Q. J                                        @.Destination.NumReservation + 1;' Z$ F1 }8 I/ ]! A* E
                                end;& C( O3 v1 \9 Z+ m
                                @.CurrIcon := "drivingHome";
3 T7 `2 T" r$ K9 }                                @.DrivingHome := true;
, t6 \0 m$ L. c! N. }7 y% C2 b6 x                        end;$ ]( ^# y2 |, C7 l
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station. h, T# X  e4 }, I  @6 H9 ~
                        part := @.transpOrder;
# d* B1 o* A3 k2 r& r                        part.move(@);-- load part+ P6 t$ R$ ~3 V" q/ a
                        @.CurrIcon := "load";
  o7 T) E& n" ^5 r: \7 ]% Z                        GlobalDistObj := part.globDestination;
. F) |1 }0 Z5 b: i! n1 ~                        assignLObj := rgmanager.rgAssignL;& i5 U2 o% P/ B8 y& ~2 F$ [
                        row := assignLObj.getRowNo(GlobalDistObj);
7 Z$ J0 d8 y+ e) y2 A- a# T+ r+ ]                        if Row = -1 then -- since 70; M7 J! J8 {* u# v( d( \
                                if lan=1 then2 l& A6 R2 F  i& Z
                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),) ?" m( f) v: _' [0 h  I. Y; F
                                                to_str("in der Andockstation: \"",?.~.name,"\""));, ^  j  T7 v: `4 F4 I" X$ Z
                                else
2 U7 D( c  K5 J- Z                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),' q0 _$ o" p4 c; f& b4 d4 s8 @% D+ i
                                                to_str("in docking station: \"",?.~.name,"\""));                               
  e. h: c4 n/ I8 Y5 p                                end;5 D* c" f' d: R2 C* d2 G
                        else
' w! j# ]- L2 M: y0 h8 Q                                @.Destination := assignLObj[1,row];
0 d# M! R2 B$ _0 M; t& J  H                        end;                        # m. j3 t) d/ k0 H' {! h
                        newDirection(@);5 ?, i7 [& U7 q6 t1 u4 T1 Z
                        @.HasOrder := true;
4 h0 f5 \/ X2 g/ x9 U9 I0 K7 v                end;
/ t+ h8 \4 [2 F+ h1 A  R        end;
# U9 m& L1 Q7 |3 ?% a0 f) Rend;        -- of the method; u) M7 ^  K$ [( W: l  |. O  ]
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 ' Q, t% B2 o8 K
" E- Q- O' ~2 ~. w" c
这是AGV_putin中arrive的method。
2 L6 k8 w" M# S; j" e+ u8 L" m* n  Z  `/ b
当到达物料速度越高时,这个报警更多,
. Y3 s6 Y6 {, V' k. B0 G可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。4 h5 n% k4 n* Y
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?# K* I, [1 Y: j+ `
/ v0 _6 M3 N" |+ p( D' U
另外一个小建议,就是move,所有的move都可以这样
/ J8 ?0 v0 m+ g; ?8 a2 S1 Nif not move() then debug end
3 ~  [+ X# q$ b& J, O7 y这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。+ Q: T7 z6 q( r- l3 X
plant simulation中的free libraries有AGV模板,
$ ^/ A  f$ h1 f里面也有案例。
% [) i& U( B2 h我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。; T3 A$ s1 J" D% B" a7 Y

9 {. @3 O. q$ r5 u6 L; K: K9 ?2 Q我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
$ q+ `0 k, o+ P5 F6 `# q, d9 \4 b$ }0 ?5 B
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08
/ E& C1 R/ r: ]: f: d. ^这是AGV_putin中arrive的method。( \" I9 z$ y% n
/ x- N" o' I6 N3 O9 m2 M) V6 U
当到达物料速度越高时,这个报警更多,

; v7 i' z! g1 l  P, [另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-2-21 20:15 , Processed in 0.017452 second(s), 16 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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