设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9658|回复: 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'
4 s$ Q& c3 C; z! d# u/ |! D: Q*/( W0 G, n4 R# Q* J5 @/ [: ^
is
/ G" ~& r) X% K/ ^7 z8 @1 M        part, GlobalDistObj, assignLObj:object;row,Lan:integer;
4 i* j3 f' }8 f# Xdo; y" W- y" W8 z- K
        Lan := rootfolder.Internal.Tools.AOLlanguage;
  u! F1 l1 P) l1 l& W! h        if current = @.Destination -- else return
! j8 W8 v# d0 ^        then6 f% z  b$ o* |0 I+ E
                @.Destination := void;3 R8 {# ~& o4 i0 r
                if @.occupied then
) X& A' [" c( u1 f  g' S                        part := @.cont;
1 ?. f' C' J, e% D+ P                        @.transpOrder := void;7 r. K" W; E5 E! R4 ~
                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
% f6 _2 ^+ _( |" |" P, S                                @,root.eventcontroller.simTime);
, q) A/ l% h& ~3 P                        @.HasOrder := false;7 w1 G6 r  m/ z# R
                        @.DrivingHome := true;$ H* s2 y0 e' ~; R
                        rgManager.tryToStartTransOrder;% K& J: e2 e. |- b/ v
                        if @.Destination = void
! s) b6 }+ S  c                        then -- no transport order for vehicle @
9 g) C5 V1 m: Q8 O( L. H                                @.Destination :=
  ^2 _( _* l% g+ G( Q                                rgManager.nearestFreeStation(@,track.~);
2 G- G2 C7 D; _4 U2 ?                                newDirection(@);   ! o9 t9 m7 k" a. H
                                if @.Destination /= void then
5 |7 |7 _" |: Q) {5 V; K: L                                        @.Destination.NumReservation :=
+ r4 Y$ `; o, K  T                                        @.Destination.NumReservation + 1;
8 d7 P0 s0 K9 Z: q5 {                                end;- k8 p% d/ ?7 f4 N# K! A8 u! q
                                @.CurrIcon := "drivingHome";
; q5 i6 j0 @8 T) {! R& O                                @.DrivingHome := true;
+ I. U4 p, n- s/ }- _2 f                        end;- G2 e  W5 }* B/ E4 i
                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
9 c$ w" y4 y2 r  e& @2 c                        part := @.transpOrder;, }! X1 _% x- x
                        part.move(@);-- load part
7 w: Z6 O5 F7 c3 u$ b                        @.CurrIcon := "load";- `* o7 W: J7 N5 z$ n$ v2 t  m
                        GlobalDistObj := part.globDestination;9 J; ~4 `: S& [' r
                        assignLObj := rgmanager.rgAssignL;8 t7 R# H, ?; T9 `
                        row := assignLObj.getRowNo(GlobalDistObj);
9 L7 \9 [8 a8 P                        if Row = -1 then -- since 70
! z9 `- f% k' r" }* l  L                                if lan=1 then
' v6 C1 b: K& @7 M) @0 a* f0 L                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),& y3 w3 |: `% y0 m: Y' O
                                                to_str("in der Andockstation: \"",?.~.name,"\""));9 C$ l1 d0 H8 I- ^4 L
                                else
- K! F8 m3 V% {                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
# S$ T( s' V5 ?8 O1 B                                                to_str("in docking station: \"",?.~.name,"\""));                                ( N( V% Y' p0 A: V7 @' s' o( D
                                end;
6 e5 i3 J+ r" v# E                        else
5 |, d5 S, c/ s                                @.Destination := assignLObj[1,row];
' |5 P  x# l  E( @                        end;                        0 k+ |$ ^) ]3 e& H7 \
                        newDirection(@);
& ^" E6 F1 m) f7 s                        @.HasOrder := true;  r7 F: T, f: o6 I4 F; O1 H6 t
                end;' C5 W- D4 \  T5 Y$ Z
        end;8 w: @. ~9 f' e0 x/ S: \6 C
end;        -- of the method
0 G( y* e8 L& Z% @
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑 " @% v) @. h& X  ^6 X- P! T* G

7 r, \& S% O  E这是AGV_putin中arrive的method。
( t4 [9 O+ E- q+ L' p4 I- o/ p6 O; z- X% s
当到达物料速度越高时,这个报警更多,% J* c, |0 t# @8 A) b
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。( {0 S( R4 `) C% [  R6 X6 s& A% t
程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?( K2 O- G& Z9 B! e1 `3 c) x

1 {% L* \: u; v. `' f* ?另外一个小建议,就是move,所有的move都可以这样, U# ]- C  n, F. S
if not move() then debug end. G" o) F7 G0 O& x% Y1 G! q1 T
这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。4 K4 Z; z1 u' _, K' s$ C
plant simulation中的free libraries有AGV模板,4 \6 N6 o4 M  F0 O* C
里面也有案例。
# r3 O4 `/ r: ^5 t/ V5 O$ h6 C我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。* b) [6 Z( Q; M3 Y. a- N/ G

: {1 k" B% B7 I+ ]! X" C& S我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
( B  ?! t1 E& w8 {( ^0 U( n4 m/ s" h( l+ b7 L
那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 9 X7 v, r% g5 q* U
这是AGV_putin中arrive的method。3 p7 m( X3 t$ |  a/ P% S- [

, O$ J! s8 j$ k$ N" p当到达物料速度越高时,这个报警更多,
2 S* u' i' b8 R% Z7 f
另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-8-15 08:19 , Processed in 0.017466 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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