Skip to content

The subject of this project is to make a system that measures how many people are in the room with using Bluetooth signals.

Notifications You must be signed in to change notification settings

berkayarslan17/Capacity-Controlling

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 

Repository files navigation

Capacity Controlling System

Introduction

resim

The subject of this project is to make a system that measures how many people are in the room. The ESP32 microcontroller card will observe the bluetooth signals in the room and record the data coming from the bluetooth devices to its system and try to determine how many bluetooth signal generating devices are in the room. Since the devices producing the Bluetooth signal will be above the people, the number of people in the room will also be measured. This project was conceived to prevent the spread of the recently emerged COVID-19 virus.

System Design

resim

Schematic Design

resim

LCD Screen

resim

The steps can be listed as follows:

  1. Activate the IDLE Screen.
  2. Connect to the Internet.
  3. Activate the tracking screen.
  4. Start the Bluetooth scan.
  5. Increase the counter when the device enters the room.
  6. Decrease the counter when the device leaves the room.
  7. Activate the alarm screen when the counter reaches the maximum capacity value.
  8. Activate the buzzer.
  9. Switch to the tracking screen when the device leaves the room.
  10. Decrease the counter.
  11. Turn off the buzzer.

Beacon's Finite State Machine

resim

The steps can be listed as follows:

  1. When the beacon is detected, initialize it.
  2. Compare the RSSI value from the beacon with the value from the internet, if the system decides that the beacon is inside the room, assign it to the input status.
  3. Compare the RSSI value from the beacon with the value from the internet, if the system decides that the beacon is outside the room, assign it to the output status.

Weighted Moving Average Filter

In order for the system to understand the exit from the room faster, a weighted moving average filter is used instead of the normal filter. In this way, the calculation was made in such a way that the weight of the latest data received was the highest, and the response speed of the system against possible situations was increased.

resim

Using IoT

The capacity control system can be controlled remotely regarding to the data it receives from the internet. It can provide room control according to different room size and capacity management needs. There are two different types of data it receives from the Internet. This data is reached under two headings. These topics can be explained as follows:

Maximum Device Topic

Maximum device data is the data that takes a value between [1,5] and tells how many beacons the system should give an alarm when it detects in the room.

Range Topic

The range data takes a value between [-50, -100] and compares the signal from the beacon with its own data and allows the system to decide whether the beacon is in the room or not.

Web Control Panel resim

Mobile Control Panel resim

Conclusion

The Capacity Control System project has been successfully completed as a system that can monitor RSSI-based devices in the room in real time, can be controlled via the website or mobile application, and can give an alarm when the maximum human capacity is reached in the room. In order to realize these, Bluetooth and WiFi modules of the ESP32 microcontroller card were used. Since it has different tasks from each other, task division has been made on the system by using the FreeRTOS operating system, code readability and the speed of executing commands of the device have been increased. By using a weighted average filter on RSSI signals, the noise on the signal is reduced and the device is able to make more accurate decisions about room tracking. Finally, on the internet connection side, the device can be controlled over the internet with the MQTT Broker provided by Ubidots.

About

The subject of this project is to make a system that measures how many people are in the room with using Bluetooth signals.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published