Many people feel quite well during quarantine, but suddenly their health collapses and they often die despite the help.
The pulse oximeter is able to help infected patients and indicate when they should seek help in the hospital as soon as possible.
With a pulse oximeter at home, every patient can monitor their health. In this way, every person is definitely better prepared to fight the disease.
Normal oxygen saturation is around 95-98%. Smokers usually achieve lower rates. Oxygen level below 90% already indicates severe respiratory failure, but you should see your doctor immediately when your result is 92% and less. Long-term pulse recording during daily could provide important information about patient health situation. E.g. continuous pulse rate monitoring helps prevent sudden heart attacks.
This portable vital parameter monitor is dedicated to patients with suspected COVID-19 disease who are asymptomatic.
The pulse oximeter is a tiny device that we put on the finger, it measures the level of blood oxidation. Infected people, as a rule, have very low oxygen levels, which is a characteristic symptom of Covid-19.
The device consists of several basic blocks:
- bio-sensor capable of recording heart rate and determining the level of oxygen saturation in the blood
- microcontroller for Digital Signal Processing
- communication module enabling communication with other systems using wireless connections via Bluetooth
Mikroelektronika Heart Rate 3 Click Board was chosen as the bio-sensor.
Heart rate 3 click is a mikroBUS add-on board whose functionality is determined by two components: an OSRAM’s SFH7050 pulse oximetry and heart rate monitoring module, and a Texas Instruments AFE4404 (Analog Front-end) IC specialized for bio-sensing.
The SFH7050 multichip package contains 3 LEDs and one photodiode separated with a light barrier to prevent optical crosstalk. When the three LEDs shine through a finger, some of the light is absorbed by the pulsating blood.
The analog signal from the SFH7050 is forwarded to the AFE chip that is able to derive pulse readings from the intensity of the reflected light.
The AFE4404 sensor uses i2c for communication so we need to connect SCL and SDA lines from the sensor to the target MCU.
The schematics of the Heart Rate Click module shows the drawing:
The microcontroller for digital signal processing should be characterized by high efficiency and low power consumption.
The ideal choice for this solution is FTDI FT900 microcontroller.
The FT900 embedded microcontroller include:
- High performance, low power 32-bit FT32 core processor, running at a frequency of 100MHz
- 256 kB hi-speed Flash memory
- USB2.0 host controller
- USB2.0 peripheral controller
- 10/100Mbps Ethernet controller
- Real Time Clock
- SPI / I2C / UART interface
- Four timers- SD host controller
- 10-bit DAC0/1 channel
- 10-bit ADC1-7 channel
- General purpose I/O interface with 5V tolerance I/O cells
The block diagram of the FT900 microcontroller is shown in the figure:
The program for the FT900 microcontroller was written in microC PRO IDE. This design environment provides full support for these microcontrollers.
Microelektronika offers complete libraries for the Heart Rate 3 Click board. You can find them at:
https://libstock.mikroe.com/projects/view/1908/heart-rate-3-click
The library contains low-level functions for the AFE4404 sensor and a hardware abstract layer (HAL) for FT900 MCU.
Because a paid license is required to fully compile the developed project, we decided to share the compiled version as a binary file.
Clicker boards have a built-in bootloader. You can program your board using software provided by Mikroelektronika.
The developed program uses UART0 with the following parameters:
- Baud rate: 115.200
- 8 data bits
- No parity
- 1 STOP bit
- HW flow control: None
Every second, results with information about heart rate and oxygen saturation are sent separated by a semicolon (", ")
Serial port lines are attached to GPIO48 (UART0_TXD) and GPIO49 (UART0_RXD).
The software for the FT900 microcontroller has been placed as an attachment.
Step 2 Programming Bluetooth microcontrollerWe chose the Nordic nRF52840 microcontroller as a communication microcontroller for Bluetooth connections.
The nRF52840 microcontroller works as a Bluetooth module. The only task of this MCU is to transfer data from serial port to a mobile device via Bluetooth connection.
Nordic Semi. offers the Software Development Kit (SDK) with many examples and full documentation.
The necessary code can be found in:
<SDK InstallFolder>\examples\ble_peripheral\ble_app_uart
This program serves as a peer to phone application and emulates a serial port over Bluetooth.
Before you can run the program, you must program the SoftDevice on the board.
The SoftDevice binary is located in folder:
<SDK InstallFolder>\components\softdevice\s140\hex
There are several methods to program the SoftDevice. The best choice is use the nRFgo Studio.
You can find this application here:
https://www.nordicsemi.com/Software-and-tools/Development-Tools/nRFgo-Studio/Download
Then you can run the Bluetooth application on nRF52840 with the S140 SoftDevice.
The application includes one service with 128-bit vendor-specific UUID service (6E400001-B5A3-F393-E0A9-E50E24DCCA9E).
This service exposes two characteristics: one for transmitting and one for receiving (as seen from the peer).
RX Characteristic (UUID: 6E400002-B5A3-F393-E0A9-E50E24DCCA9E)
The peer can send data to the device by writing to the RX Characteristic of the service. The received data is sent on the UART interface.
TX Characteristic (UUID: 6E400003-B5A3-F393-E0A9-E50E24DCCA9E)
The application can send data to the peer as notifications and transmit all data received over UART as notifications.
It uses two serial port lines from the nRF52840 board:
- RX P0.8
- TX P0.6
The application for Android has been written in MIT App Inventor. This is a very good environment for rapid application development for Android.
The application is shown in the figure:
The application logic has been programmed using built-in blocks:
If you have all the parts that make up the system, you can join them into a complete system.
1. Place Mikroelektronika Heart Rate 3 Click Board in the mikroBUS socket on the Clicker 2 for FT90x development board.
2. Program the FT900 microcontroller using the bootloader and binary file with software for this MCU.
3. Program the Nordic nRF52840 MCU using Embedded Studio.
4. Connect the appropriate lines of microcontroller serial ports with cables:
nRF52840 P0.8 (RX) to FT900 GPIO48 (UART0_TXD)
nRF52840 P0.6 (TX) to FT900 GPIO49 (UART0_RXD)
Both microcontrollers are powered with 3.3V, so they do not need voltage level translators
5. Reset both microcontrollers
6. Install Android application on your smartphone or tablet.
7. Launch the application and select the appropriate Bluetooth device (click "Select portable monitor").
8. The application updates the measurement results every 1 second.
Designed device sends information about the measured heart rate and blood saturation to a smartphone via a Bluetooth connection. Every patient is informed about his health in the special application developed for Android mobile devices.
Hardware components- Mikroelektronika Heart Rate 3 Click Board, MIKROE-2036
- Mikroelektronika Clicker 2 for FT90x Development Kit, MIKROE-1724
- Nordic nRF52840 Development Kit
- Mikroelektronika mikroC PRO for FT90x IDE
- SEGGER Embedded Studio IDE for ARM
- Nordic nRFConnect
- Nordic nRFgo Studio
- MIT App Inventor (https://appinventor.mit.edu/)
Comments