Introduction: Life Arduino Biosensor
Have you ever fallen and not been able to get up? Well, then Life Alert (or its variety of competitor devices) might be a good option for you! However, these devices are expensive, with subscriptions costing upwards of $400-$500 per year. Well, a device similar to a Life Alert medical alarm system can be made as a portable biosensor. We decided to invest time in this biosensor because we think it is important that the people in are community, especially those at risk of falls, are safe.
Although our specific prototype is not wearable, it is easy to use to detect falls and sudden movements. After motion is detected, the device will give the user an opportunity to press an "Are You Okay" button on the touch screen before making an alarm sound, warning a nearby caregiver that help is needed.
There are nine components in the Life Arduino hardware circuit adding up to $107.90. In addition to these circuit components, small wires are needed to wire the different pieces together. No other tools are needed for creating this circuit. Only Arduino software and Github are needed for the coding portion.
Half Size Breadboard (2.2" x 3.4") - $5.00
Piezo Button - $1.50
9V Battery Holder - $3.97
Arduino Uno Rev 3 - $23.00
Accelerometer Sensor - $23.68
Arduino Sensor Cable - $10.83
9V Battery - $1.87
Breadboard Jumper Wire Kit - $3.10
Total Cost: $107.90
Step 1: Preparation
To create this project, you'll need to work with Arduino Software, download Arduino libraries, and upload code from GitHub.
To download the Arduino IDE software, visit https://www.arduino.cc/en/main/software.
The code for this project can be downloaded from https://github.com/ad1367/LifeArduino., as LifeArduino.ino.
Disclaimer: This device is still in development and is not capable of detecting and reporting all falls. Do not use this device as the only way of monitoring a fall-risk patient.
- Don't modify your circuit design until the power cable is disconnected, to avoid risk of shock.
- Do not operate the device near open water or on wet surfaces.
- When connecting to an external battery, be aware that circuit components may begin to heat up after prolonged or improper use. It is recommended that you disconnect from power when the device is not in use.
- Only use the accelerometer for sensing falls; NOT the whole circuit. The TFT touchscreen used is not designed to withstand impacts and may shatter.
Step 2: Tips & Tricks
- If you feel you've wired everything correctly but your received signal is unpredictable, try tightening the connection between the Bitalino cord and the accelerometer. Sometimes an imperfect connection here, though not visible by eye, results in a nonsense signal.
- Due to the high level of background noise from the accelerometer, it may be tempting to add a low-pass filter to make the signal cleaner. However, we've found that adding a LPF greatly reduces the magnitude of the signal, in direct proportion to the selected frequency.
- Check the version of your TFT touchscreen to make sure that the correct library has been loaded into Arduino.
- If your Touchscreen doesn't work at first, make sure that all the pins have been attached to the right spots on the Arduino.
- If your Touchscreen still doesn't work with the code, try using the basic example code from Arduino, found here.
If the Touchscreen is too expensive, bulky, or difficult to wire, it can be substituted for another component, such as a Bluetooth module, with modified code so that a fall prompts the bluetooth module for a check-in rather than the touchscreen.
Step 3: Understanding the Accelerometer
The Bitalino uses a capacitive accelerometer. Let's break that down so we can understand exactly what we're working with.
Capacitive means that it relies on a change in capacitance from movement. Capacitance is the ability of a component to store electrical charge, and it increases with either the size of the capacitor or the closeness of the two plates of the capacitor.
The capacitive accelerometer takes advantage of the closeness of the two plates using a mass; when acceleration moves the mass up or down, it pulls the capacitor plate either further or closer to the other plate, and that change in capacitance creates a signal that can be converted into acceleration.
Step 4: Circuit Wiring
The Fritzing diagram shows how the different parts of the Life Arduino should be wired together. The next 12 steps show you how to wire this circuit.
Step 5: Circuit Part 1 - Placing the Piezo Button
The first step of building the circuit is to place the piezo button on the breadboard. The piezo button has two pins which should be firmly attached to the board. Make sure you take note of what rows the pins are attached to (I used rows 12 and 16).
Step 6: Circuit Part 2 - Wiring the Piezo Button
After the Piezo button has been attached firmly on the breadboard, connect the top pin (in row 12) to ground.
Next, connect the bottom pin of the piezo (in row 16) to digital pin 7 on the Arduino.
Step 7: Circuit Part 3 - Finding the Shield Pins
The next step is to find the seven pins that need to be wired from the Arduino to the TFT Screen. Digital pins 8-13 and 5V power need to be connected.
Tip: Since the screen is a shield, meaning it can connect directly on top of the Arduino, it may be helpful to flip the shield over and find these pins.
Step 8: Circuit Part 4 - Wiring the Shield Pins
The next step is to wire the shield pins using the breadboard jumper wires. The female end of the adapter (with the hole) should be attached to the pins on the back of the TFT screen located in step 3. Then, the six digital pin wires should be wired to their corresponding pins (8-13).
Tip: It is helpful to use different colors of wire to make sure that each wire connects to the correct pin.
Step 9: Circuit Step 5 - Wiring 5V/GND on Arduino
The next step is to add a wire to the 5V and GND pins on the Arduino so that we can connect power and ground to the breadboard.
Tip: While any color of wire can be used, consistently using red wire for power and black wire for ground can help in troubleshooting the circuit later.
Step 10: Circuit Step 6 - Wiring 5V/GND on Breadboard
Now, you should add power to the breadboard by bringing the red wire connected in the previous step to the red (+) strip on the board. The wire can go anywhere in the vertical strip. Repeat with the black wire to add ground to the board using the black (-) strip.
Step 11: Circuit Step 7 - Wiring 5V Screen Pin to Board
Now that the breadboard has power, the last wire from the TFT screen can be wired to the red (+) strip on the breadboard.
Step 12: Circuit Step 8 - Connecting ACC Sensor
The next step is to connect the accelerometer sensor the BITalino cable as shown.
Step 13: Circuit Step 9 - Wiring BITalino Cable
There are three wires come from the BITalino Accelerometer that need to be attached to the circuit. The red wire should be connected to the red (+) strip on the breadboard, and the black wire be wired to the black (-) strip. The purple wire should be connected to the Arduino in analog pin A0.
Step 14: Circuit Step 10 - Putting Battery in the Holder
The next step is to simply put the 9V battery into the battery holder as shown.
Step 15: Circuit Step 11 - Attaching Battery Pack to Circuit
Next, insert the lid on the battery holder to make sure the battery is tightly held in place. Then, connect the battery pack to the power input on the Arduino as shown.
Step 16: Circuit Step 12 - Plugging in to the Computer
In order to upload the code to the circuit, you must use the USB cord to connect the Arduino to the computer.
Step 17: Uploading the Code
To upload the code to your beautiful new circuit, first ensure that your USB properly connects your computer to your Arduino board.
- Open your Arduino app and clear out all of the text.
- To connect to your Arduino board, go to Tools > Port, and select the available port
- Visit GitHub, copy the code, and paste it into your Arduino app.
- You'll need to "include" the touchscreen library to get your code working. To do this, go to Tools > Manage Libraries, and search for the Adafruit GFX Library. Mouse over it and click the install button that pops up, and you'll be ready to start.
- Finally, click the Upload arrow in the blue toolbar, and watch the magic happen!
Step 18: Finished Life Arduino Circuit
After the code is uploaded correctly, unplug the USB cable so that you can take the Life Arduino with you. At this point, the circuit is complete!
Step 19: Circuit Diagram
This circuit diagram created in EAGLE shows the hardware wiring of our Life Arduino system. The Arduino Uno microprocessor is used to power, ground, and connect a 2.8" TFT Touchscreen (digital pins 8-13), a piezospeaker (pin 7), and a BITalino accelerometer (pin A0).
Step 20: Circuit and Code - Working Together
Once the circuit is created and the code is developed, the system starts working together. This includes having the accelerometer measure large changes (due to a fall). If the accelerometer detects a large change, then the touchscreen says "Are You Okay" and provides a button for the user to press.
Step 21: User Input
If the user presses the button, then the screen turns green, and says "Yes," so the system knows the user is okay. If the user does not press the button, indicating that there may be a fall, then the piezospeaker makes a sound.
Step 22: Further Ideas
To extend the Life Arduino's capabilities, we suggest adding a bluetooth module in place of the piezospeaker.
If you do, you can modify the code so that when the person who falls doesn't respond to the touchscreen prompt, an alert is sent via their bluetooth device to their designated caretaker, who can then come check on them.