设为首页收藏本站

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

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 9910|回复: 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'2 P# O5 G1 P' u3 [6 ?( Y5 O. U5 u
*/
0 \2 h- p0 i4 t. w7 H' bis/ {5 h" i+ h* z" Q# t& w' P; E4 t
        part, GlobalDistObj, assignLObj:object;row,Lan:integer;7 t& a9 g4 d8 x! G# M* f1 [
do" e1 {! A1 O! G& F7 M! q
        Lan := rootfolder.Internal.Tools.AOLlanguage;
% ?  g+ Y/ C/ A- O        if current = @.Destination -- else return. V# ^% X- E& [3 m
        then
- t/ E* U2 _5 R9 a0 ?                @.Destination := void;+ g' E" |" ]& Q( m/ \
                if @.occupied then- B* H9 T! X- c9 J6 z3 q
                        part := @.cont;- S5 R  }7 }3 J# t
                        @.transpOrder := void;
% Y) A% s- ?( [1 Z1 R                        part.move(partExit);-- unload is already possible                        rgManager.freeVehL.writeRow(0,rgManager.freeVehL.yDim + 1,
. R, ~6 y6 W4 p/ q0 p; |+ N                                @,root.eventcontroller.simTime);
! p$ G4 u- k$ B# q1 S) p; f                        @.HasOrder := false;
6 q2 W2 u! V& C1 j$ v1 Z                        @.DrivingHome := true;
8 x( \: l/ z0 T2 U7 k) W                        rgManager.tryToStartTransOrder;
7 m4 }, r/ L& n+ |; n                        if @.Destination = void
- l% C5 c: P: F& y& O8 F                        then -- no transport order for vehicle @
' b8 G5 T; n, z2 ^                                @.Destination :=9 f4 J9 l) n/ P$ g
                                rgManager.nearestFreeStation(@,track.~);
* S: b0 A, ~. v7 m8 P9 u                                newDirection(@);   
2 E7 E' e9 ^% m1 Z! c                                if @.Destination /= void then
+ B0 g' b3 v; c- M+ s9 q$ ~                                        @.Destination.NumReservation :=
( Y% ]+ V: {* w8 J+ U4 C8 F                                        @.Destination.NumReservation + 1;
+ ]" W; A+ ~1 D+ `  d/ T( F                                end;" K! F. y- h: @. g' ^* V+ G# r
                                @.CurrIcon := "drivingHome";
' m! E1 _' R$ K                                @.DrivingHome := true;, A: J* v5 k5 z& y
                        end;
2 B& \5 ~' n/ B1 z9 S8 G3 y* B                else -- the vehicle @ is empty, both vehicle and part are in the same dock station
# w  i# u$ F% S. T  x' c                        part := @.transpOrder;
/ @, e, y& ?/ E, H) @  }                        part.move(@);-- load part. C; M. d8 D' |% {  j' _
                        @.CurrIcon := "load";
+ A$ F. H  `5 z9 h                        GlobalDistObj := part.globDestination;" p1 S% S- P! A& U# c
                        assignLObj := rgmanager.rgAssignL;
/ b! j5 g( g. K- U% g                        row := assignLObj.getRowNo(GlobalDistObj);
. Q/ s# k2 w0 h5 s! Y9 N) v                        if Row = -1 then -- since 70; m# w9 r+ I+ c, T
                                if lan=1 then
8 K- V3 `5 |) U2 `" }                                        promptmessage(to_str("Unbekanntes Ziel: \"",GlobalDistObj,"\""),
: r2 M' B) f# d! d8 ]! e7 H                                                to_str("in der Andockstation: \"",?.~.name,"\""));) {5 u. s# |) `; D
                                else* x- @$ v! c! b$ {9 K3 P0 P, k
                                        promptmessage(to_str("Unknown destination: \"",GlobalDistObj,"\""),
" e* _: G0 y+ e3 M) y                                                to_str("in docking station: \"",?.~.name,"\""));                               
: U) L% Q4 u) B" N; \5 P                                end;4 j4 j  ^4 A9 S! b- ?* i. s' H
                        else
/ V) Z4 Y# K( T( g/ _0 z9 h                                @.Destination := assignLObj[1,row];
* M! q. Y! u$ ]- a                        end;                        , B- y+ p4 c4 X! d" J: {/ R% z
                        newDirection(@);; k! K0 w1 d, ]! F# N
                        @.HasOrder := true;2 x& Z) y# m" o) a  [! D
                end;
: T+ `( m' I0 P% P! p& r7 Y: G        end;# U& s# j' Y& E* Z
end;        -- of the method
5 I9 l% B) c" B% ]- I. \/ H
 楼主| 发表于 2011-11-17 11:08:06 | 显示全部楼层
本帖最后由 kuka 于 2011-11-17 11:10 编辑
8 c, t8 Y* o; P
- `) A+ ^3 x1 A2 i1 a% I这是AGV_putin中arrive的method。
1 R% E: ?  q: f3 K+ E# }, ^& v, t. Z6 h) A: H* [+ \
当到达物料速度越高时,这个报警更多,' E; {. R  F9 t) n
可能是到达物料分给了小车,而小车上已有有物料不能接受,所以发生了冲突。
6 x$ |6 l$ M( \8 ^6 u7 l- M4 {程序解决这个冲突程序是暂缓到partExit,但是AGV模板提示这个无效。
发表于 2011-11-25 19:15:24 | 显示全部楼层
是不是partexit未定义或者路径不对?3 U3 z" [( q& G
1 E  u' `1 J( R5 \% N8 p
另外一个小建议,就是move,所有的move都可以这样
# ^% @5 u4 Z9 N' E6 }# Eif not move() then debug end
0 a8 ^# h$ N( b3 `" @$ N这样一旦move有问题就会报错 便于检查和修改
发表于 2011-11-25 19:20:37 | 显示全部楼层
另外弱弱的问一句 AGV是神马 o(╯□╰)o
 楼主| 发表于 2011-11-26 19:26:51 | 显示全部楼层
AGV(Automated Guided Vehicle)自动导引小车。
- g6 d% k2 ~' w8 W1 zplant simulation中的free libraries有AGV模板,1 n6 e% ]5 B2 `  e/ @! W0 |( Q8 B
里面也有案例。
* T8 R6 d7 Q4 c) T我运行过案例,没有发现这种报错,可能案例模型没有发生冲突,运行不到if下面这块。
# U8 B. X/ k7 s' m6 V: v4 E) {0 [' W$ W: p
我开了一下模板,的确没有定义partexit,它可能是一个队列对象,不知道怎么定义。
发表于 2011-11-26 20:09:15 | 显示全部楼层
因为是用的move,可以直接在模型里建立一个缓存模块,比如buffer之类的,容量定义为-1,move的目标指向这个缓存就可以了,囧。。。不过其实我个人不推荐这种解决方法,因为实际中并不存在这种缓存。。。
发表于 2011-11-26 20:10:15 | 显示全部楼层
本帖最后由 五五 于 2011-11-26 20:10 编辑
6 Z- P1 T. M% T  v; ?, u# ?. I/ o3 R
! J5 r  ^8 x: {4 Y5 Y那么 Automated Guided Vehicle 是不是就是小车的自动寻路系统那个呀 还是还有其他功能或者模块咩
发表于 2011-11-26 20:12:36 | 显示全部楼层
kuka 发表于 2011-11-17 11:08 ' n) m3 i8 o8 _: a
这是AGV_putin中arrive的method。
6 [# c0 h) u2 [, k2 I! o7 |9 W% y* {3 o/ P# ^6 a2 L- w* ~
当到达物料速度越高时,这个报警更多,

. @8 d: t/ c8 _2 h  x另外 一般对于容量有限的小车 我个人觉得还是更早引入容量控制比较好些 而不是在装运是才报警
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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

GMT+8, 2026-9-2 05:00 , Processed in 0.022450 second(s), 15 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

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