Calculating Distance and Velocity from FMCW Radar Data in MATLAB

31 visualizaciones (últimos 30 días)
Simeon
Simeon el 11 de Feb. de 2024
Comentada: VICTOR RANGEL LICEA el 19 de Abr. de 2024
I'm working on processing FMCW radar data in MATLAB for a project, and I need to calculate the distance and velocity of a detected object. The dataset I have is called 'adcData' and is structured in three dimensions:
The first dimension (columns) contains sampled values for a single ramp. The second dimension (rows) indexes the ramp number. The third dimension represents the antenna number.
The assignment says: "You're tasked with generating the spectrum for each ramp for both antennas and storing this in a variable named FFT_R. Additionally, you're supposed to create a frequency vector Fr and use it to calculate the distance vector R."
F_c = 76.5e9;
B = 300e6;
lambda = 3e8 / F_c;
d = lambda / 2;
T_rampe = 64e-6;
T_PRI = 70e-6;
N_Rampen = 128;
F_Sample = 4e6;
N_Samples = T_rampe * F_Sample;
%b.)
t = 0:1/F_Sample:T_rampe-1/F_Sample;
x_ant1 = adcData(:, 1, 1);
x_ant2 = adcData(:, 1, 2);
N_Samples_per_Ramp = size(adcData, 1);
FFTR = fft(adcData, [], 1);
FFTR = fftshift(FFTR, 1);
magnitude = abs(FFTR);
[maxValue, maxRangeIndex] = max(magnitude);
df = F_Sample / N_Samples_per_Ramp;
Fr = (-N_Samples_per_Ramp/2:N_Samples_per_Ramp/2-1) * df;
f_beat = Fr(maxRangeIndex);
R = (f_beat * c) / (2 * B);
The formula for R doesn't seem to be correct, the values it produces dont make sense at all, and the dimensions of R are 1x128x2, which seems plausible, one R for every ramp. Unfortunately, I can't find the proper formula or the way to do that in any of my course materials.
  1 comentario
VICTOR RANGEL LICEA
VICTOR RANGEL LICEA el 19 de Abr. de 2024
It seems that the R formula is incomplete, From https://rfbeam.ch/wp-content/uploads/dlm_uploads/2022/10/ST200_UserManual.pdf, page 15 the formula to get R is
R = (c/2) *(f_beat/B) * (TM /2); where TM es the modulation period

Iniciar sesión para comentar.

Respuestas (0)

Categorías

Más información sobre Automotive Radar en Help Center y File Exchange.

Productos


Versión

R2023a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by