As the number of COVID -19 cases increase in the world, countries’ health care facilities are being overburdened. The infrastructure that was once thought to be just adequate is now turning out to be grossly inadequate. To accommodate the increasing number of patients and to provide them care, governments are deploying field hospitals. Patients, as well as people working in these field hospitals face many challenges, most prevalent of which is inadequate infrastructure due to set up costs, time, and availability.
Hospitals generally have emergency alarm systems wired into the patients’ rooms/beds for patients to use when they require assistance. Setting up such alarm systems in field hospitals is tedious, time-consuming, and expensive.
This project is an attempt to provide a solution to this problem, which is easy to deploy, and has a low setup cost and time.DESCRIPTION
This project is a wireless, touch-free IoT based emergency alarm system for deployment in field hospitals.
Being an IoT based system, it requires a fraction of the effort, time, and cost to set up as compared to the wired systems. Moreover, it can still be monitored from a central station like the wired systems. Since it is touch-free in its use, it reduces the probability of surface contamination and makes sanitization procedures easier.
The device is meant to be attached to the patient's bed or nearby where the patient can reach it easily. When the patient requires assistance, they wave their hand in front of the device. This triggers the device and it transmits this over the internet to the central monitoring station. A computer at the central monitoring station displays the status of the devices corresponding to each of the beds (whether it has been activated by the patient or not) on a web page. From here, health care personnel can be dispatched as needed.THE BUILD
This project uses an IR proximity sensor and a Bolt Wi-Fi module (I didn’t have any other Wi-Fi module at hand. The system can be easily set up to work with other Wi-Fi modules) which is based on the ESP8266 for its IoT functionality.
A Python Script (running on your computer) queries the Bolt device (via the Bolt IoT platform) for the IR proximity sensor value using the Bolt Python Library, which is based on the Bolt open APIs. Another Python script running Flask creates and hosts a local web page displaying the current status of the device (i.e., whether the patient has called for help or not). The web page also permits managing multiple devices and adding new devices easily.
Note: Since I am using the free service of Bolt cloud, the API calls are rate limited to 20 hits per minute. I have set timers to not violate these limits. This should not be an issue depending on your Wi-Fi module, or if you decide to use their (Bolt IoT) paid plans.
How it works
The device is triggered when a person waves or places their hand in front of the sensor (depending on the need/availability, any other sensor or switch/button also can be used with minor changes to the code). This triggers the device and the status of the device at each patient's bed is displayed on a web page in the central monitoring room.
Once a device has been triggered (i.e. a patient has called for help), the user must click the "Attend" button on the web page next to the corresponding device/patient number to reset the device.INSTRUCTIONS
Hardware Set Up
1. Connect the IR proximity sensor to the Bolt module as shown in the diagram.
2. Connect the Bolt module to a power supply (portable or otherwise).
Software Set Up
3. Set up the directories as mentioned in the Directory_structure.txt (linked). The directories have been set up in this manner to work with the Flask framework for python.
4. Create a database for the devices to be stored: (see images below)
i. Start a terminal in the directory of the project.
ii. Start the python interpreter in the terminal.
iii. Import db and device_response from app.
iv. Then type db.create_all() to create the database and table.
v. Optional: Then add the relevant device details to the database – device id and API key. This is available from the Bolt Cloud dashboard. This can be added later via web interface also.
vi. Type db.session.commit() to save changes to the database and then exit the python interpreter.
5. Run device_code.py.
6. In a separate terminal, run the app.py. You can now access the web page displaying the status of the device. In this case, the web page is at http://127.0.0.1:5000/
7. If you haven’t added any device credentials while creating the database in step 4, you can do so now by navigating to the “Add New Device” page.
8. You can Manage your existing devices (Edit/Delete) from the Manage Devices page.
9. The “Device Status” page displays the current status of the devices.
Note: Both python scripts need to be running in the background.
The entire assembly has been placed in a small box with cut outs for the sensor.
This project is easy to deploy and scale. Multiple devices can be deployed and connected to a single server to monitor the patients call for help. These systems will benefit not only COVID field hospitals, but any field hospital or situation where set up time and cost must be kept to the minimum. In its current form, the prototype costs approximately $20 to make. Its compact form allows it to be attached easily to any surface. Additionally, these systems don’t require much maintenance. Fabrication and repairs are also easy.
Though I have used the Bolt Wi-Fi module, this project can be adapted for use with other Wi-Fi modules. Thus, allowing the devices to run entirely on a local network without the need of internet, further reducing the cost. With suitable adjustments to the code, these devices can be modified to make use of other actuators (e.g., buzzers or lights) as needed.
Information about using flask here.
Information on the Bolt IoT platform can be found here.