I have two friends who work in healthcare. One is a radiologist in Europe and the other works as a nurse at an american hospital. Both of them told me you're supposed to wash your hands for at least 20 seconds for it to be effective. This was the first time I've heard that, and my average time spent washing my hands each time was only a few seconds. I thought I could make a fun little device that could help me get into a better habit!
What it does
You attach the device above or below a soap dispenser or bowl. When you pick up the soap or use the dispenser, the device turns on and blinks red until enough time has passed. At which point it turns green, and you can stop washing your hands. The indicators are also accompanied by small beeps indicating when you start and when it's done, allowing it to be used by the visually impaired as well.
How I built it
First off I made a circuit in Eagle. Then designed a battery pack so I knew what dimensions I could use. Then moved onto testing it on a breadboard using an ATTINY13 programmed with Arduino. At that point I sat down and soldered it together on a breadboard and spent a few hours debugging it (turns out I forgot to connect the LED rail to power). Then spent an entire evening designing an enclosure to be printed. I think I finally finished at 7 AM so I could setup my 8h print to run over night. The last day was more or less making adjustments to the code, making sure it pulled low enough power to last months, and testing it in real world applications.
Challenges I ran into
One challenge was to program efficiently enough to fit all the code into the 1024 byte flash of the microcontroller. Basically don't use floats, pick integer types sensibly, avoid analog functions etc.
Something that annoyed me for a long time was getting the IR sensor spaced just right. It was incredibly sensitive and the device would turn on by itself or when you even moved within half a meter of it. Had to bin a prototype print because of it, and spend a few hours into the morning printing different designs of just the holder for the LEDs.
The biggest challenge was designing the case. Due to having to design a custom slotted battery pack (something I've never done before), I had to give up a few times and restart. The end result seemed to have worked, even tho the device is quite chonky.
Accomplishments that I'm proud of
- I'm very proud of the battery enclosure and how it easily slots into the design.
- Managing to compile the whole program using only 640 bytes of flash
What I learned
- Never do a full print without doing small tests for each "slot" on the enclosure. It'll save a lot of time and help refine it.
- Learned how to read the datasheet for the microcontroller to figure out what bits I needed to set in the software.
What's next for Rinsense
I would like to make an SMD version of both the Rinsense and the charger. That way it can be made much smaller and cheaper. And with a multi-charger it could be used for schools since you'd have a lot of these devices in the bathrooms, which means you need to be able to charge in parallel.
In either case, I'll definitely be using the prototype I built personally to get into a better habit of washing my hands.