Singing loudly in the shower is always fun, but yelling and trying to have a conversation with the person outside the door isn't. Sometimes the hardest part about that is actually knowing if someone is trying to get your attention or not This becomes a big problem in the master bath, when the room is too deep to even hear a knock at the door, let alone actually have a conversation.
So, I decided to create a little gadget that would help called the 'Shower Knocker'. Now, when someone knocks on the door, lights blink in the shower to let you know that someone is trying to reach you. This way, you can poke your head out of the curtain and away from all that running water to try and hear what they are trying to say.
Step 1: Supplies
I decided to go what some may say "all out" because I also wanted it to look nice. Instead of a plain old LED (which you can certainly do instead) I used an RGB Light strip so it would have a nicer effect.
I created a LED Strip library for the arduino a while back. While it doesn't work the exact same (due to some PWM complexities) it will still help out a lot. Download it and install it to your Arduino IDE
Step 2: Building the LED Strip Circuit
First, let's get our LED strip lights up and running. This is probably the more complicated circuit. in terms of what is actually going, but fairly easy to actually put together. It's pretty simple to put together on a breadboard. If you're actually deploying though, you can solder it together with a protoboard for a cleaner and more polished look.
I've attached both a visual diagram using a breadboard, and a more standard schematic.
An important Note: Unlike the Arduino, the LinkIT ONE only has 2 PWM pins. These PWM pins allow the RGB LED to fade and change colors on the fly. Since I'll just be flashing a color, I elected to just forgo the PWM pins all together.
Step 3: Building the Piezo Circuit
Next up, let's handle the circuit for the piezo element. The piezo element will help us detect knocks on the door. It's basically a little electronic sensor that can detect vibrations, so it will work perfectly here.
An important little fun fact about Piezo elements is that they are polarized. This means that the voltage passes through in a specific direction (instead of just bouncing either way). Piezo elements usually come with a specific red wire and black wire, pay close attention to the color of the wires! Black must be hooked up to the lower voltage, and red to the higher voltage. IF you don't follow these instructions, you might just burn our your Piezo! That's no good!
Piezo elements are best measured with an analog signal, so connecting them to A0 (an analog pin) on our LinkIT ONE will work best.
Also, we should connect a 1-mega ohm resistor between the Piezo element circuit. This limits the voltage and current produced and protect it from frying our LinkIT ONE board.
Step 4: Deploying the Lights
I found a good spot for my lights to be up above the shower. Very little water got up there, and it still stuck pretty well to the tile. Just for added effect, I decided to go a little bit further around the bathroom as well.
Make sure that the lights are low enough so the person in the shower can see them, but high enough to stay away from high moisture areas. I know this is a bit difficult in a bathroom, but do your best!
Step 5: Deploying the Knock Sensor
Next, you'll want to deploy the knock sensor. This can be a bit tricky because you'll probably have to cut a decent amount of wire to make it stretch over the door hinge.
Make sure you tape it high enough for someone to knock. It should pick up the entire door, but of course the closer it is to the actual knock, the more accurate it will be.
Also, make sure to run it across the door hinge, versus over the top of the door. This way you have less dangling wires!
Make sure to tuck away your LinkIT ONE somewhere safe too! I decided it would be best just to put mine in a ziploc bag in the corner. This way it wasn't affected by the moisture in the bathroom. If I lose a cheap light strip, fine. But I don't want my prototype board ruined!
Step 6: Deploying the Code
Whew! Now all the tough laborious parts are over and we can sit down and deploy some code. Lucky for us, the code for this is relatively simple:
-If we sense a knock, blink the lights.
Yup, that's it! A simple if statement is all we need!
I've put a lot of comments in this code, so hopefully it is easy for you just to read and understand. Remember that we are using the custom LED RGB Library, so be sure to download and install that to your Arduino IDE before deploying!
Step 7: Knock Away!
You've done it! Now you have a fully fledged Shower Knocker for your bathroom! Whenever somebody knocks at the door, you'll see lights flash in the shower to let you know that someone wants to talk!
Hopefully this instructable has taught you a thing or two about the LinkIT ONE, and gave you a fun jumping point for future projects. Be sure to ask any questions in the comments and post pictures if you make it yourself!