IOT Fall Alert Prototype & Testing The Problem The IOT Solution The Alert Process Hardware & Firmware Web Server Challenges... Conclusions Repository

WEARABLE IOT FALL ALERT SYSTEM

By Ofek Amir & Arik Olshanezky

General Description & Key Features

This project deals with the development of a wearable IOT fall alert system designed to provide immediate alert upon fall detection by sending an SMS and/or Email to a pre-defined contact list (relatives, friends and / or medical help which the user wishes to contact in times of distress).

The IOT Fall Alert System is a cheap and simple device that can easily save adults from hours of lying in anticipation for medical assistance and prevent serious medical complications due to prolonged waiting. It also contributes to the adult's self-confidence and ability to sustain a normal life, while increasing the confidence of adult’s relatives who know they will receive an alert and will be able to assist if necessary.

Fall Alert Prototype & Testing

The Fall Alert System Prototype is based on a TI-CC3200 Launchpad connected to simple batteries and wearable as a belt buckle:

The following youtube videos demonstrate the functionality of the Fall Alert Prototype:

The next video demonstrates 2 important features (activated by the device buttons):

  1. The ability to send an "SOS" notification at any time
  2. The "False Alarm" button - abort any fall alert in case everything is just fine...

The Problem

Falls are responsible for 40% of all injury related deaths and need immediate medical attention. Falls occur through all age groups, with the major incidents among senior citizens (approximately 28-35% of people aged 65 and above fall every year).

Some relevant facts: (Quoted from https://www.mobilehelp.com/resources-information/learn-more/benefits-fall-detection-system.stml)

In conclusion, unfortunately falls are incredibly common among the elderly population and in many cases lead to hospitalization and even death.
Luckily, simple and affordable IOT technologies may significantly reduce the risks related to falling by providing an immediate alert to assure relevant assistance is provided in minimum time.

The IOT Fall Alert Solution

A simple & affordable Fall Alert System which automatically activates an alarm signal upon senior’s fall detection.
This technology addresses the problem of an elder person which falls and is unable to push an alarm button.
It can easily spare from the user hours of helpless lying and prevent serious complications by providing rapid help.
Also, a great advantage is providing the seniors the ability to remain independent in their own homes and live their every-day life with more confidence.
Moreover, the fall alert system helps the elder person’s children by assuring them they will receive an immediate alarm if their parent falls, so they can provide rapid help and call emergency services if required.
Furthermore, a person that wears a fall alert system will usually be more self-confident and less afraid of falling. This by itself may lead to lower probability of falling.

The IOT Fall Alert Process

Therefore, the system provides an efficient automatic solution for fall detection and alert and includes an embedded mechanism for the treatment of false alarms (user may cancel alarm) and false negatives (user may press SOS anytime to set alarm) which are crucial for the user’s trust in the system.

Fall Alert State Machine Explanation:

  1. A fall detection and alert flow starts at the STABLE_STATE where we monitor the device’s 3-axis accelerations and user is in daily activity mode.
  2. If we detect that the normalized acceleration is less than the pre-defined THRESHOLD_LOW we move to POTENTIAL_FALL_STATE and start timing the possible fall.
  3. If acceleration remains below THRESHOLD_LOW for at least MIN_FALL_TIME we move to FALL_STATE.
  4. In FALL_STATE, if we detect an IMPACT (acceleration suddenly hits a peak) we move to IMPACT_&_ALERT_STATE.
  5. We now wait a few seconds to enable the user to press the FALSE_ALARM button:
    • If a false alarm is detected, we move back to STABLE_STATE and start over.
    • Otherwise, a fall was detected and an SMS/Email is sent via Wi-Fi to the user’s pre -defined contact list.
# On any time, if the “SOS” button is pressed, the device immediately generates a TRUE ALERT.

Hardware, Firmware & Overall Design

The Hardware:

The system is based on the TI CC3200 launchpad – a wireless micro-controller unit (MCU) that integrates a high-performance ARM Cortex-M4 MCU and is the industry’s first MCU with built-in Wi-Fi connectivity.
Further information regarding the CC3200 MCU is available here.
The Wi-Fi connectivity contributes for the fall-alert device’s ability to provide a fast and efficient alert via Wi-Fi to the user’s contacts.

This device has a 3-axis MEMS based accelerometer unit (BMA-222) connected to it, which enables the fall alert device to continuously monitor accelerations in x, y, z axis. Further information regarding the BMA-222 unit is available here.

The CC3200’s RED LED light is activated to notify the user once a fall is detected.
The fall alert device also takes advantage of 2 of the CC3200’s buttons configured as a FALSE-ALARM button (‘sw2’) and 'SOS' button (‘sw3’).
The first button enables the user to cancel alert notifications upon possible 'False Alarms'
while the second button generates an ‘SOS’ signal to immediately send an alarm notification to contacts via Wi- at any time.

The Firmware:

We developed the firmware on Code Composer Studio 7 and used Uniflash for flashing the CC3200.

All the firmware code was written in C using TI’s official APIs provided in the CC3200 SDK. This includes –

Alongside to the firmware, we developed a web application responsible for storing the emergency contacts, receiving fall alerts from the MCU and eventually alerting the contacts.

The Fall Alert Web Server

The web application consists of three modules:

  1. Interactive website: written with Html, CSS & Javascript and connected to a Data Base. The website displays to the users the current emergency contacts configured in the system (stored in the DB) and allows adding new contacts and removing existing ones.
  2. Java Restful service which exposes the following http endpoints:

  3. • /alert -alerts all contacts.
    • /alert/sms -alert sms contacts.
    • /alert/email – alert email contacts.
    • /add/sms/{x} – add x to the list sms contacts.
    • /add/email/{x} – add x to the list of email contacts.
    • /remove/sms/{x} – remove x from the list sms contacts.
    • /remove/email/{x} – remove x from the list of email contacts.
    • /contacts – get all contacts.
    • /contacts/sms – get sms contacts.
    • /contacts/email – get email contacts.
    - The /alert API is used by the MCU to notify the server upon a fall detection.
    - The rest of the APIs are used for the retrieval, insertion and removal of emergency contacts via the website.
  4. Backend application connected to a database that stores the emergency contacts. Upon initialization the app retrieves all the emergency contacts from the database and sends them to the website for display. The Frameworks and languages used overall to develop the web application are: Java, Springboot, Javascript, Jquery, Html, CSS.

Following is a high-level overview of the system and the website user interface:

Challenges We Faced

  1. Minimizing type-I and type-II errors:

  2. When it comes to the device’s “alert sensitivity”, we have spent a lot of time experimenting and “cooking the best recipe” by adjusting the constant parameters that concern to the Fall Alert State Machine we presented earlier.

    This includes the following parameters (and many more): the accelerometers sampling rate, the MIN_FALL_TIME & number of sequential “minimum-acceleration” measurements before moving to FALL_STATE, the TOLERANCE for exceptional measurements in FALL_STATE, the minimum IMPACT acceleration peak we expect before raising alert and so on…)

    Throughout the development process, we had 2 important goals in mind – Minimizing type-I and type-II errors:

    1. Type-I Errors – Avoiding False-Positives (“false alarms”): It is obvious we don’t want to become “The Boy Who Cried Wolf”… we wish to provide a trustful system.
    2. Type-II Errors – Avoiding False-Negatives (undetected falls): It might end even worse if we miss a true fall… We must be able to detect at least any severe fall with a significant impact.
    Fortunately, we succeeded to accomplish this task by 3 means:
    1. Fall-Detection Algorithm: Developing a smart & efficient algorithm based on a fall state machine described earlier.
    2. Experimenting: Spending a lot of experimenting time adjusting the constant parameters.
    3. User Interactivity: alerting the user upon fall detection by flashing on the RED LED LIGHT and providing the user with the ability of aborting an alert (to avoid “False alarms”). Plus allowing the user to press “SOS” at any time (to avoid False-Negatives”).

    That being said, our system is still just the first prototype and there is many room for improvement in all the above aspects.

  3. Enabling high sampling rate of the device’s acceleration:

    1. In order to maintain in the “real-time” operating mode, we avoided working with Doubles and used large Integers instead to save complicated floating-point calculations time without compromising accuracy.
    2. We fixed and minimized our code in the critical areas to be as fast as we can, so we save time between samples and enable high-rate monitoring.
  4. A technologically diverse project with complexities in various fields:

    1. Integration of various capabilities of the CC3200 MCU - sampling the accelerometers in high frequencies, communicating with the user by turning on the LED lights and listening to the buttons, using WIFI to send the fall alert – and of course everything must be fast, reliable and bug-free since the user should be able to trust this device as a health protector.
    2. We also integrated a backend server that listens to HTTP requests sent upon fall alert, which manages the contacts Data-Base and generates SMS and Email alerts upon request.
    3. We invested great efforts to provide a smooth end-to-end user experience.

Final Conclusions

We entered this project without any prior experience in the embedded and IOT fields, but we quickly fell in love with the potential of creating great and meaningful products that can change the every-day life.

We were thankful to work with a great piece of tech – the high performance CC3200 MCU with integrated Wi-Fi alongside to TI's extensive and detailed documentation. These turned our experience to an educational and successful adventure.

We believe IOT products such as the Fall-Alert System can be extremely helpful for people that face all kind of disabilities – and the good news is their pretty simple, cheap and even fun to develop 😊

All our work and source code are available at Github.
We hope our project will inspire others to join the IOT adventure and take it to the next level...