Introduction: Non-Contact Hand Washing Timer With Seconds Display

This is a companion to my previous Instructable using an Arduino UNO and four (4) different colored LEDs. As with that Instructable direct contact is not required. That is, this is a non-contact timer.

For personal health, it is quite useful to follow CDC guidelines on hand washing whenever one returns from being out of your house.

My prior Instructable used LEDs, which are quite visible. Each LED was turned on for approximately five (5) seconds. Thus, although the LEDs are very easy to see, there was not a definitive seconds counter, only a broad indication of the time, in seconds, that had past.

I found, it would be easier for me to follow the CDC guidelines if the timing aid I used gave the actual seconds that have past since the timer started, even if only approximate, rather than the broad brush LEDs of my previous Instructable.

So, I made this Instructable using some readily available, and relatively inexpensive, components: an Arduino UNO board, a small breadboard, an IR Obstacle Avoidance Module, an I2C 1602 LCD, and a mixture of 10cm and 15cm Dupont wires to connect the components.

In fact, it is hard to imagine an easier non-contact Instructable to build for following CDC guidelines for hand washing.

As noted, I built an earlier Instructable using an Arduino UNO and four (4) LEDs to keep track of the time using broad, but highly visible, timing aids. Of course, the LEDs are very easy to see, and still may be preferred by some Makers.

This Instructable uses an I2C 1602 to directly display the approximate time in seconds that has elapsed since a hand was held near the IR collusion Avoidance Sensor, rather than the LEDs of my previous Instructable.

Below are the some of the CDC guidelines (i.e., a portion of their guidelines) regarding washing your hands.

Washing should be done even without the presence of the COVID-19 pandemic. Appropriate washing can prevent the transmission of diarrheal infections and other person-to-person illnesses.

"How Germs Spread

Washing hands can keep you healthy and prevent the spread of respiratory and diarrheal infections from one person to the next. Germs can spread from other people or surfaces when you: Touch your eyes, nose, and mouth with unwashed hands. Prepare or eat food and drinks with unwashed hands. Touch a contaminated surface or objects, Blow your nose, cough, or sneeze into hands and then touch other people’s hands or common objects.

Key Times to Wash Hands: You can help yourself and your loved ones stay healthy by washing your hands often, especially during these key times when you are likely to get and spread germs: Before, during, and after preparing food. Before eating food. Before and after caring for someone at home who is sick with vomiting or diarrhea. Before and after treating a cut or wound. After using the toilet. After changing diapers or cleaning up a child who has used the toilet. After blowing your nose, coughing, or sneezing. After touching an animal, animal feed, or animal waste. After handling pet food or pet treats. After touching garbage. During the COVID-19 pandemic, you should also clean hands: After you have been in a public place and touched an item or surface that may be frequently touched by other people, such as door handles, tables, gas pumps, shopping carts, or electronic cashier registers/screens, etc. Before touching your eyes, nose, or mouth because that’s how germs enter our bodies.

Follow Five Steps to Wash Your Hands the Right Way. Washing your hands is easy, and it’s one of the most effective ways to prevent the spread of germs. Clean hands can stop germs from spreading from one person to another and throughout an entire community—from your home and workplace to childcare facilities and hospitals. Follow these five steps every time. Wet your hands with clean, running water (warm or cold), turn off the tap, and apply soap. Lather your hands by rubbing them together with the soap. Lather the backs of your hands, between your fingers, and under your nails. Scrub your hands for at least 20 seconds. Need a timer? [Author: Use this Instructable.] ... Rinse your hands well under clean running water. Dry your hands using a clean towel or air dry them."

The sad reality is that we usually do not wash our hands for a sufficient time. This Instructable. with approximate seconds prominently displayed, hopes to insure we wash our hands in keeping with the CDC's guidrlines. The CDC recommends that we wash our hands for at least twenty (20) seconds, at the key times stated above.

This Instuctable displays the approximate seconds elapsed on an I2C 1602 LCD. The time displayed goes from one (1) second all the way up to to sixty (60) seconds, should we choose to exceed the minimum recommended CDC guidelines.

There is no need to touch any components, as the IR Collision Avoidance Module allows us to come near the assembly and start the timer without any direct contact with it.

Unlike Alcohol or Bleach which eliminates germs by killing them, washing eliminates germs by flushing them down the drain.

Instructables have been published to assist Makers to follow CDC hand washing guidelines. However, I believe this one is the easiest to build.

As can be seen, in this Instructable I use only a relatively small number of components, and the timer assembly, as previously noted, is easy to build, and fun to use.

Supplies

The supplies needed for this project are,

- An Arduino UNO board

- A small breadboard

- An IR Obstacle Avoidance Module

- An I2C 1602 LCD

- Dupont cables to connect components.

An experimental platform was used here, but is not absolutely necessary, although it may prove useful. I used an experimental platform to make it easier to move the assembly as a single unit.

Step 1: Test IR Obstacle Avoidance Module

Before we connect all components together it is useful to test that the IR Obstacle Avoidance Module and the I2C 1602 LCD both work correctly.

The IR Obstacle Avoidance Module is tested in this Step and the I2C 1602 LCD is tested in the next Step.

In this Step we want to insure the Obstacle Avoidance Module is working correctly before we use it in our project.

The IR Obstacle Avoidance Module outputs a LOW or zero (0) when an obstacle (a hand in this Instructable) is near, and turns on the second Green light, and we test that this second Green LED is turned On when a hand is brought near. The first Green LED simply tells us that power to this IR module is present.

We use this IR Obstacle Avoidance Module so it will not be necessary to physically touch any component to start the timer. Just coming near the Module with a hand will be adequate to start the LCD display.

Fortunately, testing this module is quite easy to do. A Sketch is not really required, as only the power connections, i.e., 5 volts and ground from the Arduino UNO are needed.

The bare bones Sketch to test this IR module is shown below, and is also shown in an attached text file, possibly in a better format.

There are two attached still photographs that show the test configuration on an experimental platform using an Arduino UNO only for power and ground.

/*

Test IR Obstacle Avoidance Module

Written June 15, 2020

by R Jordan Keindler

*/

void setup() {

}

void loop() {

}

This simple Sketch (or non-Sketch) when a hand is/is not close by this IR Obstacle Avoidance Module is all that is needed to test this module.

If we can get both Green LEDs to light when a hand is near, as here, we know the IR Obstacle Avoidance Module is working.

Step 2: Test I2C 1602 LCD

In the previous Step we tested the IR Obstacle Avoidance Module.

We wrote a Sketch (actually non-Sketch, as we only needed power) for this test and ran it.

In this step we test the LCD I2C 1602 module. This is connected to the Arduino UNO. One of the attached photographs shows the SCL and SDA, the last connections at the end of the digital pins. These SDA and SCL headers connect to the SDA and SCL connections on the "piggyback" adapter for I2C on the 1602 display. The 5 Volts and GND connectors, on the UNO, connect respectively to the VCC and GND connectors on the "piggyback" adapter of the 1602 display. through the power rails.

The sketch to perform this test is shown below. The text between the brackets of a #include is often missing in an Instructable but is provided here in the attached text file. The first two includes should have between the less than and greater than signs Wire.h and LiquidCrystal_I2C.h, respectively.

/*

Test I2C 1602 Display

Written June 14, 2020

by R Jordan Keindler

*/

#include // See text

#include // See text

LiquidCrystal_I2C lcd(0x27, 16, 2);

// set the LCD address to 0x27 for a 16 chars and 2 line display

int delay1(1000);

void setup()

{

lcd.init(); // initialize the lcd

lcd.backlight(); // Turn backlight On

}

void loop()

{

lcd.setCursor(0, 0); // Set cursor at position zero (0) on first line of 1602 LCD

lcd.print("Test First Line"); // Test first line of LCD

lcd.setCursor(0, 1); // Set cursor at position zero (0) on second line of 1602 LCD

lcd.print("Jordan Kreindler"); // Test second line of LCD

delay(delay1); // Delay one second after each the display of elapsed seconds

}

Step 3: Build the Unit-Combine the IR Obstacle Avoidance Module and the I2C 1602 LCD

We use the IR Obstacle Avoidance Module to let us know when a hand is close and start the timer.As noted previously, we do not need to touch any component for the timer to start.

To have the Arduino UNO-based assembly let us know what approximate time has past, we added a 1602 I2C LCD, to directly display that approximate time in seconds.

The completed assembly including IR Obstacle Avoidance Module and I2C LCD is shown in the attached photographs.

The Sketch that is used to detect if a hand is close, and run the timer is shown in the next Step.

The positive ground rail on a small breadboard is connected to the IR Obstacle Avoidance Module, pin marked VCC, and to the I2C LED VCC pin.

A positive voltage rail is used to insure all tie points are easily accessible.

The ground rail is in a similar manner connected to a GND pin on the I2C LCD and the GND pin on the IR Obstacle Avoidance Module (through the small breadboard).

The three attached photographs show the assembled timer.

Step 4: The Sketch to Make the 1602 LCD Timer Function

The Sketch to invoke the timer functionality is shown below.

The text between the brackets. i.e., that is the greater than and less than brackets, of a #include are typically missing in an Instructable, but are provided here in the attached text file to mitigate any issues. The #include should have brackets, less than and greater than brackets, and text between then.

The text between them should be LiquidCrystal_I2C.h.

The two attached photographs show how the assembled timer is connected.

/*

Wash Hands Timer

Written June 14, 2020

by R Jordan Keindler

Uses an I2C 1602, An IR Obstacle Avoidance Module,

and an Arduino UNO

*/


#include //See text

LiquidCrystal_I2C lcd(0x27, 16, 2); // Set I2C address to 0x27

int IRModulePinNumber = 7;

int delay1 = 1000;

int i;

int val;

void setup()

{

pinMode(IRModulePinNumber, INPUT);

lcd.init(); // initialize the lcd

Serial.begin(9600);

}

void loop() {

val = digitalRead(IRModulePinNumber); // Read the IR Collision Avoidance OUT pin

Serial.print(val);

Serial.print("\n");

if (val == 0) // If a hand is near

{

lcd.backlight(); // Turn on the backlight

lcd.clear(); // Clear the LCD and place cursor at first position on first line

lcd.print("Wash Hands Timer"); // Print "Wash Hands Timer" on first line of LCD

lcd.setCursor(0, 1); // Position display cursor on second line

lcd.print("Elapsed time: "); // Print "Elapsed time: " on second line of LCD

for (i = 1; i <= 60; i++) { // Count the seconds

lcd.setCursor(14, 1);

lcd.print(i);

delay(delay1);

}

lcd.noBacklight(); // Turn backlight Off

}

}


The timer runs from one (1) second to sixty (60) seconds.That is, its upper time in seconds exceeds CDC minimum guidelines, should a user care to wash longer than these CDC minimum recommendations.

When the assembly completes its sixty (60) second cycle it goes dark (to sleep), and waits until another hand is brought close to the IR Collision Avoidance Module to begin the one (1) to sixty (60) second cycle once again.

Step 5: Afterwards

If you have come to this point - congratulations. You should now have a basic understanding of some of the key elements of the CDC wash hands guidelines as implemented here on an Arduino UNO with an I2C 1602 LCD.

If you like this Instructable you may want to read some of my other Instructables.

Also, if you liked this Instructable, please be kind enough to check the "Favorited" box at the start of this Instructable; it would be appreciated. Thank you.

If you have any comments, suggestions, or questions related to this Instructable, please be kind enough to add these to the comments below, if there are any.

If you have any thoughts or questions, about related items not covered in this Instructable, or any suggestions for how I could improve this Instructable, I would be pleased to hear from you. You can contact me directly at transiintbox@gmail.com. (Please replace the second 'i' with an 'e' to contact me).

Arduino Contest 2020

Participated in the
Arduino Contest 2020