Project Report Final
Project Report Final
INFORMATION TECHNOLOGY
CHENNAI
PROJECT REPORT
ON
SUBMITTED BY
Vivek Vishwas Deshmukh
Malhar Virendra Patil
Vaishnavi Pravin Salgude
Yogesh Balaji Kendre
Rushi Gajanan Bhasme
at
July 2025
ABSTRACT
his project focuses on designing and implementing an ultrasonic radar system using the STM32
microcontroller. The primary objective of this project is to develop a low-cost, efficient radar
system capable of detecting objects within a specific angular range and displaying their
distance and angle on a computer screen in real time. The system uses an ultrasonic sensor
mounted on a servo motor to scan the surroundings. The servo motor rotates the sensor from
15° to 165°, and at each angle, the ultrasonic sensor measures the distance to the nearest object.
The STM32 microcontroller collects this data and sends it to a computer through serial
communication. The Processing software running on the computer receives this data and
visualises it on the screen in the form of a radar display showing the location of detected
objects.
Compared to other microcontrollers like Arduino Uno, STM32 offers better performance due
to its higher clock speed, better PWM resolution, and more memory, resulting in smoother
motor control and faster data processing. This makes the radar more accurate and reliable for
applications such as obstacle detection, security surveillance, environment mapping in
robotics, and industrial automation. The project also involved learning how to interface
multiple components like servo motors, ultrasonic sensors, and USB-TTL modules with
STM32, uploading bootloaders, writing embedded C code for motor and sensor control, and
developing Processing-based graphical user interfaces.
During the implementation, challenges such as driver installation issues and pin configuration
errors were faced and resolved, enhancing practical troubleshooting skills. The results showed
successful detection of objects within a range of 40 cm with clear graphical representation. In
future, the system can be improved by increasing the scanning range, adding alarms for object
detection, and integrating with mobile apps for remote monitoring. This project provides a
strong foundation for understanding radar principles and embedded system integration for real-
world problem-solving.
Since its inception in 2010, NIELIT Chennai has established itself as a premier institution
providing affordable quality education as per the job market requirements for candidates
primarily from Tamil Nadu. As of date NIELIT Chennai has imparted skill training to more
than 30, 000 youth of this region and conducted digital literacy certification for more than
25,000 candidates. NIELIT Chennai handles the activities of the NIELIT in Tamil Nadu,
Andhra, Telangana, and the Andaman and Nicobar Islands.
Presently NIELIT Chennai is implementing the following projects for Tamil Nadu: ISEA
(Information Security Education and Awareness), Future Skills PRIME capacity building
projects (3D Printing and Additive Manufacturing, Robotic Process Automation, IoT -
technology streams), and the aspirational district projects for SC/ST candidates at
Ramanathapuram and Virudhunagar funded by MeitY, Government of India. The centre also
received funding through the electronics product design and product testing capacity building
project funded by MeitY.
Other than training, the centre also provides services like; Private Cloud Setup using Citrix,
vSphere, Red Hat & FOSS Cloud, Hyper-converged Infrastructure (HCI) and Virtual Desktop
Infrastructure (VDI) Server Setup, High-Performance Computing (HPC) Setup with
100G/200G connectivity, Server and Virtual Lab Setup for BigData, AI & Information
Security, and Digital & Mobile Forensics Service.
NIELIT has also set up a Virtual Academy, a common End-to-End Platform to conduct Online
training courses including a virtual lab environment in the areas of IECT from foundation to
expert level targeting from school students to working professionals.
I undersigned hereby declare that the project report “STM32 MICROCONTROLLER BASED
ULTRASONIC RADAR”, submitted for partial fulfilment of the requirements of the
internship in ‘ Online Internship in Embedded C ’ at National Institute of Electronic & IT,
Chennai is a bonafide work done by me under supervision of Mr. Ishant Kumar Bajpai . This
submission represents my ideas in my own words and where ideas or words of others have
been included, I have adequately and accurately cited and referenced the original sources. I
also declare that I have adhered to academic honesty and integrity ethics and have not
misrepresented or fabricated any data, idea, fact, or source in my submission. I understand
that any violation of the above will cause disciplinary action by the institute and/or the
University and can also evoke penal action from the sources that have thus not been properly
cited or from whom proper permission has not been obtained. This report has not previously
formed the basis for awarding any degree, diploma or similar title of any other University.
Place: Pune
Date :20-07-2025
Student Name
Raghavendran S
ACKNOWLEDGEMENT 1
ABSTRACT 2
LIST OF FIGURES 6
CHAPTER 1. INTRODUCTION 7
CHAPTER 3. METHODOLOGY 9
CHAPTER 6. IMPLEMENTATION 20
REFERENCE 37
Radar stands for Radio Detection and Ranging, traditionally using electromagnetic waves to
detect the presence, distance, and speed of objects. However, for short-range low-cost
applications, ultrasonic waves can be used as an alternative. In this project, an ultrasonic radar
system is developed using an STM32 microcontroller, an ultrasonic sensor (HC-SR04), and a
servo motor (SG90).
The ultrasonic sensor emits sound waves beyond human hearing range and measures the time
taken for the echo to return after hitting an object. The servo motor rotates the sensor to scan
from 15° to 165° creating a radar-like effect. The STM32 microcontroller collects the distance
data at each angle and sends it to a computer, where the Processing software visualises it as a
radar screen displaying object positions.
This system demonstrates how embedded systems, sensors, and real-time processing can be
combined to implement practical solutions in robotics, automation, and security surveillance.
Traditional radar systems are used extensively in military applications, aircrafts, ships, weather
forecasting, and automotive safety for long-distance object detection. However, these systems
use high-frequency electromagnetic waves and complex RF circuits, making them costly and
unsuitable for small-scale educational or robotic projects.
Ultrasonic radars, in contrast, use ultrasonic sensors to detect objects within short ranges
(typically up to a few meters). Previous studies and projects used Arduino Uno for such radars,
but Arduino’s limitations include lower clock speed (16 MHz), less PWM resolution (10 bits),
and small memory (2KB SRAM).
Thus, STM32-based radars are more reliable, precise, and responsive. This project builds upon
these benefits to create a practical and improved ultrasonic radar.
The concept of creating a low-cost radar system using ultrasonic sensors and a microcontroller
is well-established in the hobbyist and academic communities. A review of existing literature
reveals that the most common approach involves the use of the Arduino platform, particularly
the Arduino Uno board. These projects typically share a common architecture: an HC-SR04
ultrasonic sensor is mounted on a servo motor (like the SG90) to provide rotational scanning.
The Arduino microcontroller controls the servo's position and manages the ultrasonic sensor's
distance measurements.
For data visualization, the standard practice is to transmit the angle and distance data via a
serial connection to a host computer. A custom application, often developed in the Processing
IDE due to its simplicity and strong capabilities in serial communication and graphics, is used
to render the data onto a radar-like display. These systems effectively demonstrate the core
principles of radar and sonar and serve as excellent educational tools. However, their reliance
The HC-SR04 ultrasonic sensor is the cornerstone of most non-contact, short-range distance
measurement projects in the DIY and educational sectors. Its widespread adoption is due to its
low cost, ease of use, and reliable performance under a variety of conditions. The sensor
operates by emitting a short burst of 40 kHz ultrasonic sound from its transmitter module. It
then listens for the echo of this sound to be detected by its receiver module. The microcontroller
measures the time duration for which the sensor's "Echo" pin is held high, which is directly
proportional to the time-of-flight (ToF) of the sound wave.
The HC-SR04's key strengths include its immunity to ambient light conditions, which can
affect optical sensors, and its ability to detect transparent objects like glass. However, it is not
without limitations. Its theoretical maximum range of 400 cm is seldom achievable in practice;
factors like atmospheric absorption, target surface properties (size, shape, and material), and
the sensor's own power output typically limit the reliable range to a much shorter distance. The
sensor struggles with acoustically absorbent materials like foam or heavy fabric, which may
not produce a strong echo. Furthermore, surfaces that are highly angled relative to the sensor
can deflect the echo away from the receiver, resulting in a missed detection. These limitations
establish a set of realistic performance expectations for any system based on this sensor.
While the Arduino platform is sufficient for basic implementations, this project deliberately
employs the STM32F103C8T6 microcontroller to create a more powerful and extensible
system. The choice to move beyond the conventional Arduino environment is a conscious
trade-off, accepting a potentially steeper learning curve in exchange for significantly enhanced
performance and future potential. The STM32 platform, based on the 32-bit ARM Cortex-M
architecture, offers substantial advantages over the 8-bit AVR architecture of the Arduino Uno.
This performance headroom is not merely a theoretical benefit; it directly translates into the
capacity for faster processing, smoother control, and the ability to implement more complex
algorithms in future iterations of the project, such as sensor fusion or on-device machine
learning.
The difficulties encountered during development, such as managing COM port drivers and
resolving pin naming conventions (A10 vs. PA10), are direct consequences of this choice.
Using the Arduino IDE as an abstraction layer over the STM32 hardware simplifies the initial
coding process but can obscure the underlying hardware specifics, leading to such
troubleshooting challenges. This experience itself is a valuable learning outcome, highlighting
the importance of understanding the hardware at a deeper level, even when using high-level
Arduino Uno
Feature STM32F103C8T6 Implication for this Project
(ATmega328P)
A survey of publicly available project documentation and tutorials reveals a relative scarcity
of well-documented, introductory-level ultrasonic radar projects that are specifically based on
the STM32 platform. The vast majority of resources focus on the Arduino, leaving a gap in
accessible literature for students and hobbyists wishing to leverage the power of ARM Cortex-
M microcontrollers for this application. This project, therefore, serves as a valuable
contribution to this space. It not only provides a complete guide to building the system but also
documents the specific challenges and solutions associated with using the STM32 in a
simplified development environment (the Arduino IDE).
METHODOLOGY
3.1 BLOCK DIAGRAM AND DETAILS:
1. Control Unit (STM32F103C8T6 Board): This is the core of the system. It runs the
embedded firmware that dictates the behavior of all other components. It generates control
signals, processes sensor data, and manages communication.
2. Sensing Unit (HC-SR04 Ultrasonic Sensor): This unit is responsible for acquiring raw
environmental data. It receives a trigger signal from the Control Unit and, in response, emits
an ultrasonic pulse and measures the echo return time.
3. Actuation Unit (Tower Pro SG90 Servo Motor): This unit provides physical motion. It
receives Pulse Width Modulation (PWM) signals from the Control Unit to precisely position
the Sensing Unit at different angles, enabling the scanning function.
4. Communication Interface (FT232RL USB to TTL Module): This unit acts as a bridge
between the microcontroller and the host computer. It converts the logic-level serial data
(UART) from the STM32 into a USB signal that the computer can understand, and vice versa.
This link is used for both programming the microcontroller and for transmitting real-time radar
data.
5. Visualization Unit (Host PC with Processing GUI): This unit is responsible for the
human-machine interface. A host computer runs a custom application that receives the
serialized angle and distance data, processes it, and renders it onto a graphical radar screen for
the user to interpret.
The operational cycle of the ultrasonic radar system is a continuous, repetitive process that can
be broken down into the following sequential steps:
2. Scanning Loop: The system enters its main loop(). The firmware commands the servo
motor to begin a sweep from its starting position (15°) towards its end position (165°).
This sweep is not continuous but occurs in discrete angular increments (e.g., 1 degree
per step).
Distance=(Time×SpeedOfSound)/2
The speed of sound is approximated as 0.034 centimeters per microsecond (cm/μs). The result
is divided by two because the measured time accounts for the sound wave's journey to the
object and back to the sensor; only half of this time represents the one-way distance.
5. Data Transmission: The calculated distance and the current angle of the servo motor
are formatted into a single, delimited string. The chosen format is "angle,distance.", for
example, "77,10.". This string is then transmitted from the STM32 to the host PC over
the serial connection established by the FT232RL module.
6. Data Reception and Visualization: On the host PC, the Processing application is
continuously listening for data on the designated serial (COM) port. When it receives a
complete data packet (terminated by the '.' character), an event is triggered. The
7. Return Sweep: Once the servo motor reaches the end of its scan at 165 degrees, the
firmware immediately begins a return sweep, moving from 165° back to 15°. The
process of measuring, calculating, and transmitting data (Steps 3-6) is repeated during
this return sweep, ensuring that the radar display is continuously updated without any
"blind" period during servo repositioning. This entire cycle repeats indefinitely,
providing a persistent, real-time scan of the environment.
The "Blue Pill" is a popular and inexpensive development board that features the
STM32F103C8T6 microcontroller from STMicroelectronics. It serves as the central processing
unit or "brain" of the project, responsible for executing the embedded firmware that controls
the servo motor, triggers the ultrasonic sensor, performs all necessary calculations, and
manages serial communication with the host PC.
The HC-SR04 is the primary sensing element of the system, used for non-contact distance
measurement. It operates based on the principles of sonar, emitting high-frequency sound
waves and measuring the time it takes for an echo to return.
• Key Specifications :
o Measuring Angle: The sensor has a narrow detection cone of less than 15
degrees.
The Tower Pro SG90 is a lightweight, widely used, and low-cost servo motor. In this project,
its function is to physically rotate the HC-SR04 sensor, allowing the system to scan a wide
angular area instead of just measuring distance in a single, fixed direction.
• Key Specifications :
o Torque: 1.8 kg-cm at 4.8V, sufficient for rotating the lightweight sensor.
o Control Signal: The servo's position is controlled by the duration of a high pulse
on its signal line, a technique known as Pulse Width Modulation (PWM). The
STM32's timer peripherals are used to generate this signal.
This module is a critical intermediary component that facilitates communication between the
STM32 microcontroller and the host PC. The STM32 communicates using logic-level UART
(Transistor-Transistor Logic levels), while the PC uses the USB protocol. The FT232RL chip
on this module handles the necessary protocol conversion and voltage level shifting to create a
virtual serial (COM) port on the PC. This interface serves a dual purpose: it is used to upload
the compiled firmware to the STM32 (in conjunction with a bootloader) and to transmit the
real-time angle and distance data from the operational radar to the GUI.
The following table provides an itemized list of all hardware components required for the
project, along with their approximate costs. This highlights the overall cost-effectiveness of
the system, a key advantage of this design approach.
USB Cable 1 30
The development of the STM32-based ultrasonic radar system required a suite of software tools
to create the embedded firmware, the graphical user interface, and to manage the programming
of the microcontroller. This chapter details the software environments and programming
languages used in the project.
The Arduino Integrated Development Environment (IDE) was selected as the primary tool for
writing, compiling, and uploading the firmware to the STM32 board. While typically
associated with Arduino-brand hardware, the IDE's open-source nature and extensible
architecture allow it to support a wide range of third-party boards, including the STM32 "Blue
Pill."
Two primary programming languages were utilized in this project, corresponding to the two
main software components:
• C/C++: The embedded firmware running on the STM32 microcontroller was written in
C++. The Arduino IDE uses a simplified C++ dialect and provides a framework of core
libraries that abstract away much of the low-level hardware configuration, allowing the
developer to focus on the application logic.
• Java: The GUI application was developed in the Processing IDE, which uses Java as its
underlying language. The code written in the Processing sketchbook is pre-processed
and converted into standard Java code before compilation and execution.
IMPLEMENTATION
The hardware was assembled on a solderless breadboard for ease of prototyping and
modification. The connections were made using standard jumper wires. The process involved
two main stages of wiring: initial setup for bootloader flashing and the final configuration for
system operation.
• Control Unit Wiring (for Bootloader Flashing): To prepare the STM32 board for its
initial programming, the FT232RL USB-to-TTL converter was connected. The
connections were as follows: FT232RL VCC to STM32 3.3V, GND to GND, TX to
STM32 RX (pin PA10), and RX to STM32 TX (pin PA9). The BOOT0 jumper on the
STM32 board was set to the '1' position to enable programming mode. This setup is
illustrated in Figure 6.2.
• System Wiring (for Operation): After flashing the bootloader, the wiring was
reconfigured for the final application. The FT232RL connections remained the same
for data communication. The sensor and servo were then connected:
o HC-SR04 Sensor: VCC pin to STM32 5V, GND to GND, Trig pin to STM32
pin PA10, and Echo pin to STM32 pin PA9.
o SG90 Servo Motor: VCC (red wire) to STM32 5V, GND (brown wire) to
GND, and Signal (orange wire) to STM32 pin PA8, which is a PWM-capable
pin.
The development workflow for the STM32 "Blue Pill" is more involved than that of a standard
Arduino, requiring an initial setup phase. This hidden complexity is a crucial practical aspect
of the project.
1. Hardware Configuration: The BOOT0 jumper on the Blue Pill board was set to the
'1' position, and the BOOT1 jumper was set to '0'. This configures the microcontroller
to boot from its internal system memory, where the factory bootloader resides, allowing
it to accept programming commands over the UART interface.
2. Flashing the Bootloader: With the board connected to the PC via the FT232RL
adapter, the STM32CubeProgrammer software was launched. The software was
configured to connect to the correct COM port at a baud rate of 115200. The bootloader
binary file (a generic STM32 bootloader compatible with the Arduino IDE) was
selected, and the target memory address was set to 0x08000000. The programming
operation was then initiated, which erases the relevant flash sector and writes the new
bootloader code.
3. Final Configuration: After successfully flashing the bootloader, the BOOT0 jumper
was returned to the '0' position. This ensures that on subsequent power-ups, the
microcontroller executes the code from its main flash memory, where the user
application will be stored. From this point forward, all application firmware could be
uploaded directly from the Arduino IDE without needing STM32CubeProgrammer or
changing jumpers.
#include <Servo.h>.
long duration;
int distance;
Servo myServo; // Creates a servo object for controlling the servo motor
void setup() {
[Link](115200);
void loop() {
for(int i=15;i<=165;i++){
[Link](i);
delay(30);
[Link]("."); // Sends addition character right next to the previous value needed
for(int i=165;i>15;i--){
[Link](i);
delay(30);
distance = calculateDistance();
[Link](i);
[Link](",");
[Link](distance);
[Link](".");
int calculateDistance(){
digitalWrite(trigPin, LOW);
delayMicroseconds(2);
delayMicroseconds(10);
digitalWrite(trigPin, LOW);
distance= duration*0.034/2;
return distance;
The graphical user interface was created in the Processing IDE. The code is event-
driven and focused on visualization.
import [Link]; // imports library for reading the data from the serial
port
import [Link];
// defubes variables
String angle="";
String distance="";
String data="";
String noObject;
float pixsDistance;
int index1=0;
int index2=0;
void setup() {
smooth();
[Link]('.'); // reads the data from the serial port up to the character '.'. So
actually it
void draw() {
fill(98,245,31);
noStroke();
fill(0,4);
drawRadar();
drawLine();
drawObject();
drawText();
void serialEvent (Serial myPort) { // starts reading data from the Serial Port
variable "data".
data = [Link]('.');
data = [Link](0,[Link]()-1);
index1 = [Link](","); // find the character ',' and puts it into the variable "index1"
angle= [Link](0, index1); // read the data from position "0" to position of the
variable index1 or thats the value of the angle the Arduino Board sent into the Serial
Port
iAngle = int(angle);
iDistance = int(distance);
void drawRadar() {
pushMatrix();
noFill();
strokeWeight(2);
stroke(98,245,31);
arc(0,0,(width-width*0.0625),(width-width*0.0625),PI,TWO_PI);
arc(0,0,(width-width*0.27),(width-width*0.27),PI,TWO_PI);
arc(0,0,(width-width*0.479),(width-width*0.479),PI,TWO_PI);
line(-width/2,0,width/2,0);
line(0,0,(-width/2)*cos(radians(30)),(-width/2)*sin(radians(30)));
line(0,0,(-width/2)*cos(radians(60)),(-width/2)*sin(radians(60)));
line(0,0,(-width/2)*cos(radians(90)),(-width/2)*sin(radians(90)));
line(0,0,(-width/2)*cos(radians(120)),(-width/2)*sin(radians(120)));
line(0,0,(-width/2)*cos(radians(150)),(-width/2)*sin(radians(150)));
line((-width/2)*cos(radians(30)),0,width/2,0);
popMatrix();
void drawObject() {
pushMatrix();
strokeWeight(9);
cm to pixels
if(iDistance<40){
line(pixsDistance*cos(radians(iAngle)),-pixsDistance*sin(radians(iAngle)),(width
width*0.505)*cos(radians(iAngle)),-(width-width*0.505)*sin(radians(iAngle)));
popMatrix();
void drawLine() {
pushMatrix();
strokeWeight(9);
stroke(30,250,60);
line(0,0,(height-height*0.12)*cos(radians(iAngle)),-(height-
height*0.12)*sin(radians(iAngle))); //
popMatrix();
pushMatrix();
if(iDistance>40) {
else {
fill(0,0,0);
noStroke();
textSize(25);
text("10cm",width-width*0.3854,height-height*0.0833);
text("20cm",width-width*0.281,height-height*0.0833);
text("30cm",width-width*0.177,height-height*0.0833);
text("40cm",width-width*0.0729,height-height*0.0833);
textSize(25);
if(iDistance<40) {
text("
"
textSize(25);
fill(98,245,60);
translate((width-width*0.4994)+width/2*cos(radians(30)),(height-height*0.0907)
width/2*sin(radians(30)));
rotate(-radians(-60));
text("30°",0,0);
resetMatrix();
translate((width-width*0.503)+width/2*cos(radians(60)),(height-height*0.0888)
rotate(-radians(-30));
text("60°",0,0);
resetMatrix();
translate((width-width*0.507)+width/2*cos(radians(90)),(height-height*0.0833)
width/2*sin(radians(90)));
rotate(radians(0));
text("90°",0,0);
resetMatrix();
translate(width-width*0.513+width/2*cos(radians(120)),(height-height*0.07129)
width/2*sin(radians(120)));
rotate(radians(-30));
text("120°",0,0);
resetMatrix();
translate((width-width*0.5104)+width/2*cos(radians(150)),(height-height*0.0574)
width/2*sin(radians(150)));
rotate(radians(-60));
text("150°",0,0);
popMatrix();
The system was successfully assembled and tested, demonstrating its ability to detect objects
and visualize their location in real-time. The graphical user interface, rendered by the
Processing application, provides a clear and intuitive representation of the scanned
environment. The following figures, captured during operation, showcase the system's output
when detecting objects at different positions.
• Range and Accuracy: The system was tested and found to be effective within the 40
cm range limit defined by the GUI's visual scale. While the HC-SR04 sensor has a
theoretical maximum range of 400 cm, this is rarely practical for small targets in open
air. The effective range is limited by several factors, including the attenuation of the
sound wave as it travels, the size and acoustic reflectivity of the target object, and the
sensitivity of the receiver. For this project's purpose of short-range scanning, the 40 cm
range is sufficient. The accuracy, observed qualitatively, appears high for solid objects
placed perpendicular to the sensor's path. However, precise quantitative accuracy would
require calibration against a known standard and implementation of environmental
compensation.
The development process was not without its challenges. Overcoming these issues provided
valuable practical experience in embedded systems troubleshooting. The two main problems
encountered are detailed below, formalizing the notes from the project's documentation.
• Challenge 1: COM Port Detection Failure: During the initial setup, the Windows 10
operating system failed to automatically recognize the FT232RL USB-to-TTL adapter
o Troubleshooting and Solution: The Device Manager was used to identify the
unrecognized "USB Serial Port." The correct drivers for the FT232RL chip were
then manually downloaded and installed. After installation, the device was
properly recognized, and a COM port was assigned, enabling both the
STM32CubeProgrammer and the Arduino IDE to communicate with the board.
This experience underscores the critical importance of proper driver
management, a common hurdle in embedded development when interfacing
with various hardware modules.
• Challenge 2: Incorrect Pin Naming Convention: When first writing the firmware,
the STM32 pins were referred to using the labels printed on the Blue Pill board's silk
screen (e.g., "A10", "A9"). This resulted in compiler errors, as the Arduino core for
STM32 did not recognize these aliases.
While the project was successful, it is important to acknowledge its inherent limitations, which
stem from the chosen components and design.
• 2D Scanning Only: The system scans in a single horizontal plane and cannot provide
any information about the height or vertical position of detected objects.
8.1 Conclusion :
This project successfully achieved its objective of designing, building, and testing an STM32-
based ultrasonic radar system. A functional, low-cost prototype was created that accurately
detects objects within a 150-degree field of view and displays their location on a real-time
graphical interface. The project effectively demonstrates the successful integration of multiple
engineering domains: embedded systems programming, hardware interfacing, sensor data
acquisition, mechanical actuation, and software development for data visualization.
The current prototype offers numerous avenues for future enhancement and expansion. The
robust STM32 platform provides the necessary resources to implement more advanced
features. The STM32-based ultrasonic radar was successfully designed and implemented. The
system demonstrated real-time object detection and graphical display, showing the potential of
low-cost radars for robotics, automation, and security applications.
To achieve a full 360-degree scan, the SG90 servo motor could be replaced with a continuous
rotation servo or a stepper motor coupled with a slip ring to manage wiring.
The system's reliability and detection capabilities could be dramatically improved by adding a
sensor of a different type and fusing the data.
To make the system accessible from anywhere, it could be connected to the Internet of Things
(IoT). An ESP8266 or ESP32 Wi-Fi module could be interfaced with the STM32 via a UART
serial connection.
Datasheets: