Chapter 3

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 46

Chapter 3

3 Description of software
In this chapter, we will explain the use of software in detail. We have used the following
software’s for our project

1) MATLAB

3.1 MATLAB
MATLAB is a software that provides us a programming platform used for iterative
analysis, algorithm development, creation of models, and applications. We have used
this software to develop a radar model, the target model and environment be the help of
a phased array toolbox. We have also used this software to quantize the data, verify the
output of Fourier transport taken from HDL approach by using HDL blocks to
implement the algorithm in Simulink (explained below), implementation of the
algorithm, and display the output i.e. Range Estimation of the target.

3.2 Approach of FMCW Radar for Range Estimation


The FMCW radar in MATLAB Simulink has been implemented via two approaches i.e.

1. Phased array Tool Box in Simulink


2. HDL coder Blocks in Simulink

3.2.1 Phased Array Toolbox


Phased Array System Toolbox is a toolbox in MATLAB software that helps us to
design, simulate and analyze array systems in different applications e.g. in Radar,
Sonar, wireless communication, ADAS, EW systems, and imaging applications. For
example, a phased array toolbox can provide an algorithm to design radar and its
environment to analyze the system in a different situation. One application of this
example might be to set radar speed and radar velocity as well as target speed and target
velocity to a specific value. Apart from this, Phased Array Toolbox provides us a wide
variety of different functions and modeling that are used to model antennas,
microphones, sonar transducers, array geometries, signal radiation, signal collection,
transmitters, and receivers. Some of the elements of the phased array antenna are
described below:

3.2.1.1. Defining the Parameters: The FMCW radar parameters such as the Bandwidth
‘bw’, sampling frequency ‘ F s’, Sweep time ‘T sweep’, Radar position and initial velocity,
target position, RCS and initial velocity, Operating frequency of the FMCW radar ‘ F c’
and the radar specification that includes the gains of the antennas and the transmitting
peak power.

Figure: Showing the parameters set for FMCW simulation in Simulink model

System Parameters Symbols Value

Operating Frequency Fc 2 GHz

Sample rate F𝑠 56 MHz

Sweep bandwidth 𝐵 55 MHz

Sweep time Tsweep 9.82us

Maximum target range 𝑅𝑚𝑎𝑥 c∗Tsweep


Rmax = =1473
2
m

Range resolution ∆𝑅 c
∆𝑅 = =2.72m
2∗BW
Maximum beat frequency 𝑓𝑏𝑚𝑎𝑥 2∗BW∗R max
fbmax = =55MHz
c∗Tsweep

3.2.1.2.Waveform: this toolbox is capable of generating different types of the


waveform, e.g. we can use the toolbox to generate the waveform of FMCW signal that
might be of any nature e.g. ramp signal, triangular signal, etc. In oue scenario we are
using SAWTOOTH WAVEFORM since our only parameter of interest is range
estimation which frequency modulates a sinusoidal carrier.In practice a train of such
waveforms is used to calculate the range of a target.

Figure: Frequency modulation using sawtooth waveform: (a) Spectrogram of the sawtooth
function, (b) Modulated signal in the time domain.
Figure: Sequence of Sawtooth waveform where bold lines shows the transmitted signal and
dotted lines shows the received signal

By using the FMCW waveform generator of the Phased Array toolbox a specified
sweep have been generated of a specified sweep time, bandwidth and sampling
frequency.
Figure: The following block represents the FMCW waveform implementation using the phased
array toolbox of the MATLAB

This is a up-sweep linear FMCW signal, often referred to as sawtooth shape. 


Figure: The spectrogram shows a sawtooth waveform for the FMCW Chirp.

3.2.1.3. Phased.RadarTarget: Creates a radar target System object. It can set different
properties of targets like its mean Radar cross-section, target statistical model, etc. It
can also specify the target scattering mode, sources of the mean scattering matrix of
target, mean radar scattering matrix for polarized signal, signal propagation speed, and
signal carrier frequency etc. This is modelled in two parts as:
3.2.1.3.1. Target: It is modelled using the specifications of the target such as RCS and
the operating frequency
Figure: The target car modelled with phased array toolbox

3.2.1.3.2. Platform: It is modelled using the specifications of


target such as targets position and velocity.

Figure: The target car platform modelled with phased array toolbox

3.2.1.4. Phased. Platform: is used to model the motion of the platform in the
environment. The environment may contain free air, clutter, or target of interest. It can
model the motion of a platform e.g. the velocity and acceleration of the platform (e.g.
radar or garget). It can also be used to model object motion, the initial position of the
platform, current velocity of the platform, source of acceleration data, acceleration of
the platform, initial scan angle of the platform, azimuthal span, azimuth scan rate etc.
Figure: The radar platform modelled with phased array toolbox

3.2.1.5. Phased.Freespace: is used to model the free space environment .here the user
can set different properties of free space, for example, the Signal propagation speed,
signal carrier frequency, Sample rate, Maximum one-way propagation distance, the
maximum number of input signal samples, etc.

Figure: The channel modeled as free space with phased array toolbox
3.2.1.6. Phased.Transmitter : is used to model the transmitter of an antenna where we
can define different parameters of transmitting antenna e.g. its peak power, transmit
gain, loss factor, preservation of coherence among pulses, pulse phase noise output.
Each of these parameters have their default value. If the user does not define their value,
then the default value of that parameter is set.

Figure: The transmitter modelled with phased array toolbox

3.2.1.7. Phased.ReceiverPreamp: is another element of a phased array toolbox that is


used to model receiver preamplifier. Here the received signal is multiplied by amplifier
gain and divided by the losses of the system. Some of the parameters of these elements
are receiver gain, loss factor, noise method, the noise the figure, reference temperature
of the receiver, sample rate, noise power, and noise complexity. Each of these
parameters has its default value. If the user does not define their value, then the default
value of that parameter is set
Figure: The Preamp Receiver modelled with phased array toolbox

3.2.1.8. Phased.RangeResponse: is used to find out the range response of the signal.
It finds out the response to a fast time and slow time data. It takes the input parameters
as Propagation Speed, beat Frequency, Sampling Rate, Range Method Sweep Slope,
and Range FFT Length.

3.2.1.8.1 Signal Processing:

It is modelled using a signal processing algorithm modeled as follows:


Figure: The Signal Processing Algorithm modelled in Simulink

3.2.1.8.1.1. Dechirp:

It mixes the input signal with the reference signal. The input signal can be a matrix
where each column is an independent channel. The reference signal is a vector. The
reference signal is conjugated and then multiplied with each column to compute the
output.

Figure: The Dechirp Algorithm modelled in Simulink

3.2.1.8.1.2. Coherent Pulse Integrator:


The Coherent Pulse Integrator block performs coherent integration of successive
pulses of a signal and puts out an integrated output according to the specified
number of pulses to integrate and the number of overlapped pulses in successive
integrations.

Figure: The 64 pulse Coherent Integration Algorithm modelled in Simulink

It performs a 64 pulse coherent integration of 216 FFt points.

3.2.1.8.1.3. Range Estimation:

It is used to estimate the range of target detections found in the radar data by
analysis of beat frequency. It takes the input parameters as Propagation Speed, beat
Frequency, Sampling Rate, Range Method Sweep Slope, and Range FFT Length.

Figure: The Range estimation Algorithm modelled in Simulink


The function used inside the range estimation block is as follows that processes the beat
frequency and finds the maximum beat frequency. It hen processes it through the
function ‘beat2range’ that is used to give the resultant range from the beat frequency
using the formula i.e.

c∗Tsweep
R=
2∗BW ∗fb

Figure: Matlab code for finding the range from beat frequency, implemented in the Range
estimation Algorithm modelled in Simulink

3.2.1.9. FMCW Radar Model For Range Estimation:


The model shows an automotive cruise control system using the frequency modulated
continuous wave (FMCW) technique in order to perform range estimation of a
stationary vehicle at a distance of 50m from the radar. Unlike pulsed radar systems that
are commonly seen in the defense industry, automotive radar systems often adopt
FMCW technology. Compared to pulsed radars, FMCW radars are smaller, use less
power, and are much cheaper to manufacture. As a consequence, FMCW radars can
only monitor a much smaller distance and the designed radar has a range resolution of
2.72m
Figure: Matlab model of FMCW radar for Automotive Cruise Control for Range Estimation of
single stationary target

The model simulation shows that the Range Estimation for a target vehicle placed at a
distance of 50, from the Radar comes out to be 49.63m with the FMCW Phased Array
approach.

To program zynq SoC , we have used HDL coded blocks in Simulink to implement the
whole model as Hardware in Loop.

3.2.2 HDL Coder Blocks Approach in Simulink:

 HDL Coder Blocks in MATLAB Simulink automatically generates HDL code from
MATLAB, allowing to implement FPGA and ASIC designs from the widely used
MATLAB language that allows the FPGA hardware-in-the-loop capabilities for testing
FPGA and ASIC designs. With it, MATLAB now provides HDL code generation and
verification across MATLAB and Simulink. HDL Coder generates portable,
synthesizable VHDL and Verilog code from MATLAB functions and Simulink models
that can be used for FPGA programming or ASIC prototyping and design. As a result,
we can now immediately identify the best algorithm for hardware implementation.
Traceability between Simulink models and generated HDL code also supports the
development of high-integrity applications and readily testing of the algorithm on the
hardware.

3.2.2.1. Waveform: The FMCW waveform i.e. the sweep is generated using the HDL blocks.
The main working is to find a complete new algorithm in order to generate a sweep with HDL
coded blocks identical to the one generated using the phased array toolbox waveform. This is
done as described in detail below.

3.2.2.1.1. Sweep Generation:

y=mx

Where: x=0: Δcount:BW

BW=55e6

Fs=56e6

Δcount=100e3

X=0:100,000:55e6

BW 55e6
∗1 ∗1
Tsweep=No.of steps*sample time= Δcount = 100000 =9.82e-6 seconds
Fs 56e6

count max :

count max
∗1
Tsweep=No.of steps*sample time= Δcount
Fs

count max =Tsweep*Δcount*Fs=9.82e-6*100000*56e6=54992e3

3.2.2.1.1.1. NCO HDL Optimized:

The NCO HDL Optimized block generates real or complex sinusoidal signals, while providing
hardware-friendly control signals. The block uses the same phase accumulation and lookup table
algorithm as implemented in the NCO block. The block uses quantized integer accumulation to
create a sinusoid signal.

Figure: The NCO block algorithm in block form

The NCO HDL Optimized block provides these features:


 Optional frame-based output.
 A lookup table compression option to reduce the lookup table size. This compression
results in less than one LSB loss in precision.
 An optional input port for external dither.
 An optional reset port that resets the phase accumulator to its initial value.
 An optional output port for the current NCO phase.

3.2.2.1.1.1. Phase Increment Algorithm of NCO

The main task is to develop an algorithm for the phase increment of the NCo block in order to
generate an increasing frequency sinusoidal i.e. a Chirp

This is done by giving the input of the phase increment of the NCO Optimized Block with a
COUNTER that generates a max count according to the following calculations as:

count max =Tsweep*Δcount*Fs=9.82e-6*100000*56e6=54992e3


Figure: The NCO Block optimized for HDL implementation parameters setting

For a desired bandwidth, we calculate the phase increment by using the following relation

BW ∗2Nacc
Phase increment= =644366
Fs

Where Nacc is the accumulator word length. The phase increment is specified using an input port
as shown.
Figure: Implementation of Phase increment for NCO through input port as gain

3.2.2.1.1.2. Counter

The counter is implemented as follows that takes the step size and continues incrementing until it
reaches the maximum count i.e. 54992e3

Figure: The Counter implemented in chirp generator with upper limit set as max_count

The complete block for generating the chirp is as follows:


Figure: The Chirp Generator (Sweep generator) using HDL Optimized approach

The chirp generated from the FMCW waveform block and that from the chirp generator
using HDL optimized blocks is shown as follows. Both the chirps are almost identical. The
difference is due to the fractional point approximation as the FMCW has lesser precision as
compared to the HDL approach.

Figure: Comparison of chirp generated via FMCW block of the Phased array Toolbox and that
by NCO built HDL optimized Approach.
3.2.2.2. Transmitter and Receiver: There is no need for transmitter and receiver to be
separately defined in the HDL optimized approach as the chirp after generation is
directly sent to the target which after reflection is processed in the range calculator
block by taking its FFT.

3.2.2.3. Deserializer: It is used to convert from scalar to vector, or from smaller-size


vector to larger-size vector. The output rate is S / (Ratio + Idle Cycles), where S is the
input rate.

Figure: Deserializer block with output/input vector size ratio set as 3000

3.2.2.4. Channel and Target: The channel and target are implemented as they takes
inputs the information regarding the radar and target positions as well as velocity, also
the target specifications such as RCS and set up channel propagation for the chirp. It
consists of:
3.2.2.4.1. Car Target: The car target Compute the signal echo according to the
specified radar cross-section (RCS) or scattering matrix (when polarization is enabled).
The target is set into non fluctuating Swerling models

3.2.2.4.2. Car Platform: It models the motion of platforms such as airplanes or ground
vehicles. Platforms can be configured using either constant velocity or constant
acceleration models. The orientation of the platforms can also be specified.

3.2.2.4.3. Radar Platform: It models the motion of platforms such as airplanes or


ground vehicles. Platforms can be configured using either constant velocity or constant
acceleration models. The orientation of the platforms can also be specified.

3.2.2.4.4. Channel: The Propagation channel between the radar and the car is set to be
free space with maximum one way propagation distance set as 1473m equal to R_max.

Figure: The target and channel in the FMCW radar implementation

3.2.2.5. Dechirp: It mixes the input signal with the reference signal. The input signal
can be a matrix where each column is an independent channel. The reference signal is a
vector. The reference signal is conjugated and then multiplied with each column to
compute the output.
Figure: The Dechirp Algorithm modelled in Simulink

3.2.2.6. Buffer: It converts scalar samples to a frame output at a lower rate. The output
buffer size is set to be 2^16 =65536 and it is the same number as the number of FFT
points taken. The Buffer block always performs frame-based processing. The block
redistributes the data in each column of the input to produce an output with a different
frame size. Buffering a signal to a larger frame size yields an output with a slower frame
rate than the input.
Figure: The Buffer block modelled in Simulink with output size as 65536

3.2.2.7. FFT-fast Fourier Transform: It computes the fast Fourier transform (FFT) across the
first dimension of the input. When you set the 'FFT implementation' parameter to 'Radix-2', the
FFT length must be a power of two and in this case it is selected as 2^16 = 65536 FFT points.

BEAT FREQUENCY
FFT RANGE
(MAX)

Due to the unavailability of hardware, we were not able to implement signal processing
on hardware. For this, we simulated the FFT in HDL implementation.

3.2.2.8. Square Law Detector: The FFT output is squared as in to process in the range
calculation block

3.2.2.9. Range Calculation: The range is estimated by finding the maximum of peaks of the
FFT output and then multiplying it with the gain as follows:

8∗56 e 6
C∗fb∗Tsweep 3 e ∗9.82 e−6
Range= = 216 *[FFT of fb]
2∗BW
2∗55 e 6
Figure: The Range Estimation Algorithm modelled in Simulink

3.2.1.10. FMCW Radar Model For Range Estimation Using


HDL Coded Block:

Figure: The HDL Coder Block Implementation of FMCW Radar for Range Estimation

The model simulation shows that the Range Estimation for a target vehicle placed at a
distance of 50, from the Radar comes out to be 50.89m with the FMCW HDL coder
based approach and is accurate since the range resolution for our design is 2.72m.

Figure: A stationary target at distance of 50m from a stationary car having FMCW radar
We have determine the fundamental waveform parameters for a radar working at 2 GHz in the
MATLAB environment using Phased Array System Toolbox functionality. In the case, we
assume the car as well as the target to be stationary at a distance of 50m from the car radar.
The first problem we have to cope with when designing a new algorithm for the FMCW
waveform generation which is HDL supported in order to run it on the Hardware. We have
successfully developed, simulated and tested the Chirp Generator to determine the range of the
stationary single target with desired resolution within the specified range. We consider an
automotive long-range radar with maximum unambiguous range of 1473 meters and a minim
detectable range of 5.45 meters simulated with an operating frequency of 2GHz and a sampling
frequency of 56 MHz over a bandwidth of 55 MHz that is supported by the hardware.

c∗Tsweep
Maximum Unambiguous distance= Rmax = =1473m=
2

c
Minimum distance/Range that can be measured= Rmin = =5.45m
BW

c
Range Resolution: =2.72m
2∗BW
Chapter 4
4 Simulations and Results
In this chapter, we will explain the simulation results of the software. As we have
implemented the FMCW radar with two approaches as to create the software as well as
hardware environment and to test the designed radar in both approaches and verify the
results. This chapter covers the simulation of the FMCW radar for Range Estimation of
a single stationary target in:

1) Phased Array Tool box Approach


2) HDL Coder block hardware supported Approach

4.1 Phased Array Toolbox Approach

4.1.1. Flow Chart

The flow chart below demonstrates the basic process of the FMCW radar for range estimation
FMCW
Parametrs set Waveform Transmisson Recieved signal
Generation

Beat
Range Peak
Frequency Dechirp
Estimation estimation
Analysis

Figure: Process Flow Chart

4.1.2. Parameters:

To generate the simulated data of FMCW radar we used a “phased array toolbox”. To
generate a FMCW sawtooth waveform we need sweep time, bandwidth, and sample
frequency. To set these parameters we need to define system parameters that fulfill the
requirement of our project.

The parameters set for the FMCW radar is as follows

System Parameters value


-----------------------------------------------------------
Operating Frequency (GHz) 2
Maximum Unambiguous range (m) 1473
Range Resolution (m) 2.72
Minimum detectable Range (m) 5.45
Sweep Time (millisecond) 9.82
Sweep Bandwidth (MHz) 5
Sample Rate (MHz) 56
Maximum Beat Frequency (MHz) 55
Figure: Showing the matlab script for setting parameters for FMCW simulation in Simulink
model

The sweep time of the sawtooth waveform can be calculated from the basic equation of
Radar:

The bandwidth of the sawtooth waveform can also be calculated from the same formula
as mention above

Sampling frequency 𝑓𝑠 is chosen to be 56 MHz which fulfills the criteria since the
Bandwidth is 55 MHz

4.1.3. Simulations:

After defining a set of variables for all the parameters needed to describe our automotive FMCW
radar system, we proceed with a complete PC simulation to test whether the System will work
properly. To do that we use a Simulink model with blocks that have as parameters the variables
from the MATLAB workspace that have been set with the script described in the section of
setting parameters.
In this after the FMCW waveform have been transmitted and received back from its reflection
from the target, both the transmitted and received signals are dechirped and produces a beat
frequency which is then analysed to determine the range of the target
.

Beat
Dechirpin
FMCW frequency
g Tx and
Waveform peak
Rx signals
geneartion analysis

Recieved Range
Transmissio
back (after estimation
n (free space
reflection
channel)
from target)

4.1.3.1. FMCW Waveform

The waveform generated by setting the following parameters with the help of the phased array
tool box is a sawtooth waveform that is the actual waveform of our interest in the case and is as
follows as shown
Figure: The spectrogram shows a sawtooth waveform for the FMCW Chirp.

Figure: The scope output that shows a sawtooth waveform for the FMCW Chirp that is a
sinusoidal in time domain

4.1.3.2. Signal Propagation and reflection

Now our next task is to generate Radar, target, channel, and transmitter and receiver
model using a phased array toolbox. The generation of different models is explained in
chapter 3. According to Radar model, the radar as well as the target are both stationary.
The distance between the radar and target is 50𝑚.

Now we have to generate a simulated data of FMCW radar, so we need to transmit the
signal. For this, we have transmitted the signal. The Position of the target and radar is
updated with the passage of time. Then the signal is transmitted and passed through a
channel. When this signal hits the target and reflects back a Doppler will be added in it.
The received signal contains the information of transmitted signal and Doppler shift so
we dechirp the received signal so in end we only had the information of beat frequency.
4.1.3.3. Beat Frequency

The received signal is an attenuated and time-delayed copy of the transmitted signal where the
delay, Δt is related to the distance of the target. Because the signal is always sweeping through a
frequency band, at any moment during the sweep, the frequency difference fb, usually called
beat frequency, between the transmitted signal and the received signal is constant. Because the
sweep is linear, one can derive the time delay from the beat frequency and then the distance of
the target from the time delay.

Figure: sawtooth chirp and beat signal

4.1.3.4. Range Estimation

The frequency of the beat-note signal is the basis of the range estimation for FMCW radar. The
instantaneous phase of the sampled series is calculated and is then used to estimate the frequency
of the beat signal that is the difference between the transmitted and the received signal.

4.1.3.4.1. FFT:

For exposing the frequency content of the received time signal the FFT is applied. It is used
because of its low computational cost and its robustness against low SNR. Its main disadvantage
is when two frequencies are close to each other, then only one of them will be detected. The
resolution limit is given by fmin = Fs /N, where Fs is the sampling frequency and N is the
number of samples from the continues signal. Therefore the most natural approach when high
frequency resolution is required, is to increase the number of samples N. This provides the
higher resolution in most of the cases, but not when working with an FMCW radar signal. This
can be proven by rewriting the beat frequency:

2∗BW∗R
f b=
c∗T sweep

c∗T sweep
→ R=
2∗BW∗f b

Frequency Resolution can be written as:

Where Ts is the sampling time and T is the total sample time.

It proves that the standard way of providing increased resolution does not work. The only thing
that can be done is to increase the bandwidth B of the transmitted signal which is not an option
because of legal requirements and hardware related problems. The limit hmin will in reality also
be degraded since the beat signal is multiplied with a window.

The first step is identification of tones in the “beats” signal, which then correspond to the ranges
of the targets. The straightforward approach is to use Fast Fourier Transform (FFT) algorithms.
The tones identified correspond to target candidates.

Figure: Range processing of one channel of FMCW RADAR


Computational complexity for most FFT algorithms is O(Nlog(N)), where N is the size of the
data block and the base of the logarithm depends on the specific algorithm (two for radix-2
factorization, four or higher for higher radices). The linear coefficient depends on fine details
and hardware used for the implementation. Conventional DSP processors usually have
instructions and architecture features that accelerate the inner kernel of the algorithms, so that
FFT-typical “butterfly” operations are done very efficiently. It is not uncommon for one radix-2
butterfly to execute at one cycle per point rate, which makes a 256-point radix-2 FFT
implementation run in about 256*log2(256)=2048 cycles plus overheads (eight passes of 256
cycles each). Specialized ASIP accelerators consuming and producing one sample per clock can
be implemented, so that pipelined execution of a 256-point FFT takes 256 cycles.

4.1.3.4.2. Interpolation:

When calculating the FFT it produces values at the FFT frequencies which are equally spaced
with Fs/N Hz. This introduces an error when using peak picking if the true frequency is not
located at an exact multiple of F/ N . Instead the true frequency is in the range:

To reduce this error different methods have been suggested over the years. The idea behind them
is best described by the following figure. The figure presents the values from an FFT operation
where the maximum peak is located around 2.05 m. By examining the two closest frequencies
one can see that the frequency to the right has a larger amplitude than the frequency to the left. It
is then reasonable to assume that the true maximum is located somewhere in between the
maximum frequency and the frequency to the right. This is what is called interpolation,
combining the discrete frequencies close to the maximum and thus receive a better estimate of
where the true maximum is located.
Figure: The idea of interpolation explained. The FFT provides the blue lines and the maximum frequency
is located at an offset from the true maximum, the orange line.

4.1.3.5. Simulation Results


Figure: Complete FMCW radar modeled in Simulink using phased array approach

The simulation of the FMCW Radar in Simulink using the phased array approach shows
a range estimation of 49.63 meters for a stationary target at a distance of 50 meters from
the target which is very accurate result since the frequency resolution of the radar is
2.72m

4.1.3.5.1. Simulation Data

The following table shows a simulation results of the Phase Array Toolbox supported design of
the FMCW Radar taken for readings by incrementing the target distance by 10 from
Rmin=5.45m to Rmax=1473m. The estimated range is within the range resolution of the radar
which is 2.72 meters. Thus it shows successful simulation on software.

Distance Range of Target Distance of Range of Target


Error: Error:
of Target: Estimated: Target: Estimated:
0.01333333
20 21.06 -0.053 120 118.4
3
0.00846153
30 31.61 -0.05366667 130 128.9
8
40 39.51 0.01225 150 147.3 0.018
50 50.06 -0.0012 160 157.8 0.01375
0.01151515
60 60.59 -0.00983333 165 163.1
2
0.00941176
70 71.11 -0.01585714 170 168.4
5
80 79.01 0.012375 180 178.9 0.00611111
1
-
0.00511111
90 89.54 190 191.2 0.00631578
1
9
100 100 0 200 200.9 -0.0045

4.2 HDL Coder Approach

4.2.1. Flow Chart

The following flow diagram shows the process of the Radar Simulation in Matlab. Due to
unavailability of hardware the results have been displayed on matlab with user defined data. Else
the design is ready to be tested on real time data by incorporating hardware in loop with the help
of HDL coded blocks.

Set Chirp Hardware in


Transmission
Parameters Generator loop

Beat Recieved
FFT Dechirp
Frequency Signal

Peak Range Display


Estimation Estimation Results

Figure: Process Flow Chart


4.2.2. Parameters

The parameters set for the FMCW radar is as follows

System Parameters value


-----------------------------------------------------------
Operating Frequency (GHz) 2
Maximum Unambiguous range (m) 1473
Range Resolution (m) 2.72
Minimum detectable Range (m) 5.45
Sweep Time (millisecond) 9.82
Sweep Bandwidth (MHz) 5
Sample Rate (MHz) 56
Maximum Beat Frequency (MHz) 55

4.2.3. Chirp Generator:

The main task in the HDL coder approach is to generate an algorithm for generating a chirp that
is supported by the hardware as the phased array toolbox FMCW waveform is not supported by
the hardware.

This is done by incorporating a NCO’s phase increment with a counter. In this way it gives an
increasing frequency sinusoidal which is actually our Chirp.

Δcount=100e3

X=0:100,000:55e6

BW 55 e 6
∗1 ∗1
Tsweep=No.of steps*sample time= Δcount = 100000 =9.82e-6 seconds
Fs 56 e 6

count max :

count max
∗1
Tsweep=No.of steps*sample time= Δcount
Fs
count max =Tsweep*Δcount*Fs=9.82e-6*100000*56e6=54992e3

Figure: Implementation of Chirp Generator Algorithm using HDL supported Simulink blocks
through Phase increment for NCO through input port as gain

The chirp generated from the FMCW waveform block and that from the chirp generator
using HDL optimized blocks is shown as follows. Both the chirps are almost identical. The
difference is due to the fractional point approximation as the FMCW has lesser precision as
compared to the HDL approach.
Figure: Comparison of chirp generated via FMCW block of the Phased array Toolbox and that
by NCO built HDL optimized Approach.

4.2.4. Simulations:

After defining a set of variables for all the parameters needed to describe our automotive FMCW
radar system, we proceed with a complete PC simulation to test whether the chirp generator will
work properly. To do that we use a Simulink model with blocks that have as parameters the
variables from the MATLAB workspace that have been set with the script described in the
section of setting parameters. After the FMCW waveform have been generated, simulated and
received we perform FFT analysis on the received as well as the transmitted signal to calculate
the beat frequency from which the range of the target is estimated.

BEAT FREQUENCY
FFT RANGE
(MAX)

4.2.4.1. Beat Frequency

As shown in Figure, the received signal is an attenuated and time-delayed copy of the transmitted
signal where the delay, Δt is related to the distance of the target. Because the signal is always
sweeping through a frequency band, at any moment during the sweep, the frequency difference
fb, usually called beat frequency, between the transmitted signal and the received signal is
constant. Because the sweep is linear, one can derive the time delay from the beat frequency and
then the distance of the target from the time delay.

Figure: Beat frequency, difference between the transmitted and received signal
2∗BW ∗R
fb= =1.866938 MHz
c∗Tsweep

As shown in the simulation results the beat frequency comes out to be 2.07 MHz which is nearly
equal to the calculated one.

Figure: Beat frequency for target at 50m

4.2.4.2. Peak Power

In order to determine the different requirements and specifications of the FCMW radar system, it
is necessary to consider the radar equation that determines the received power
Pt G t G r λ 2 σ
Pr = = -107.8dB
( 4 П)3 R4
4.3.4.3. Range Estimation

The range is estimated by applying fast Fourier transform on the beat frequency with FFT points
taken as

4∗BW∗Rmax
N= c
=1080.2

Since FFT points are a power of 210=1024 points is near to the calculated points but we have
taken 216 FFT points as at this the simulations gives better results moreover the hardware can
support up to 34 bits transform size that is it can support FFT points up to 234. So from this
maximum beat frequency peak is estimated and then processed

In an FMCW radar the frequency of the transmitted signal is linearly varied over time. Since
there is a certain distance between the radar and the target, the reflected signal varies in
frequency compared to the currently transmitted frequency. To determine the distance of a target
the difference in frequency, called beat frequency between the transmitted and the received
signal is evaluated. For slow moving targets which can be regarded as stationary during one
measurement cycle a saw tooth modulation scheme can be used. In the case of a single target a
single beat frequency is induced, which has a sinusoidal form in time domain. The beat frequcy
is then translated into the Range by the following relation:

8∗56 e 6
C∗fb∗Tsweep 3 e ∗9.82 e−6
Range= 2∗BW = 216 *[FFT of fb]
2∗55 e 6
4.3.4.4. Simulation Results

Figure: Complete FMCW radar modeled in Simulink using HDL approach

The simulation of the FMCW Radar in Simulink using the HDL supported approach
shows a range estimation of 50.89 meters for a stationary target at a distance of 50
meters from the target

4.3.4.4.1. Simulation Data

The following table shows a simulation results of the HDL supported design of the FMCW
Radar taken for readings by incrementing the target distance by 10 from Rmin=5.45m to
Rmax=1473m. The estimated range is within the range resolution of the radar which is 2.72
meters. Thus it shows successful simulation and testing of our Radar design that is HDL
hardware supported.
Distance
Range of Target Distance Range of Target
ofTarget Error: Error:4
Estimated: ofTarget:2 Estimated:3
:
-
4 5.453213784 260 261.5344105 -0.005901579
0.363303446
-
5 5.453213784 270 272.5408381 -0.009410511
0.090642757
6 5.453213784 0.091131036 280 277.9940518 0.007164101
-
10 10.90642756 290 288.9004794 0.00379145
0.090642756
-
20 21.81285511 300 299.806907 0.000643643
0.090642756
30 29.96271307 0.001242898 350 350.8934726 -0.002552779
40 38.17249645 0.045687589 400 399.1118608 0.002220348
50 49.07892401 0.01842152 450 450.007777 -1.72822E-05
60 59.98535156 0.000244141 500 500.9036932 -0.001807386
68.13520952 0.026639864 550 549.0991966 0.001637824
80 79.04163707 0.011979537 600 599.9951127 8.14542E-06
90 89.94806463 0.00057706 650 650.8910285 -0.001370813
-
100 100.8544922 700 699.1094172 0.001272261
0.008544922
-
110 111.7609197 750 749.7764848 0.00029802
0.016008361
120 119.9107777 0.000743519 800 800.9012496 -0.001126562
-
130 130.8172053 850 849.1196378 0.00103572
0.006286194
-
140 141.7236328 900 899.9926691 8.14542E-06
0.012311663
150 149.8734908 0.000843395 950 950.8885853 -0.000935353
160 160.7799183 -0.00487449 1000 1000.231457 -0.000231457
-
170 171.6863459 1050 1050.00289 -2.75213E-06
0.009919682
180 179.8961293 0.00057706 1100 1100.898806 -0.000817096
190 188.0459872 0.010284278 1150 1150.013458 -1.17024E-05
200 198.9524148 0.005237926 1200 1200.01311 -1.09253E-05
210 209.8588423 0.000672179 1250 1250.909027 -0.000727221
220 220.7652699 - 1300 1299.10453 0.000688823
0.003478499
230 228.9151278 0.004716835 1350 1350.000446 -3.30453E-07
240 239.8215554 0.000743519 1400 1400.896362 -0.000640259
-
250 250.727983 1450 1449.114751 0.000610517
0.002911932
-
260 261.5344105 1473 1473.212502 -0.000144265
0.005901579

4.3 Comparison of Results

Parameters Range 𝑚
Actual Values 50
Phased Array Approach 49.63
HDL Supported Approach 49.07

Figure: It shows a stationary target at a distance of 50m from a stationary car

You might also like