IntroductionAbout a year ago we bought a new washing machine which seems to work nice, but it lacks a very important feature: it doesn't notify me when the washing is done. I usually start a new load in the morning and, even though the programs usually finish in about an hour, I tend to forget it and hang the cloths only in the evening.
|The finished board - just add a washing machine and it's ready to roll! :)|
After this happened a few times, I decided that as soon as the warranty period is over I would install a small circuit inside the washing machine and let it beep once the program is finished. (The circuit would be very simple as I don't have to dig deeply in the private parts of the washing machine - I noticed that when a washing program is over all three status LEDs on it blink at the same time.)
However, as time has passed, I forgot the wet clothes in the machine for longer and longer periods and it became clear I needed a solution for this as soon as possible.
I had the following criteria for any solution to be acceptable:
- Since there is no power outlet in our bathroom (apparently, when our house was built installing power sockets in a bathroom was illegal or at least frowned upon...) it must be operated without a separate power inlet.
- It should not void warranty of the washing machine (for obvious reasons...)
- It should be very simple, easy to use, preferably no user interface on it at all. It should do only one thing, but it should do it well.
- It should be cheap, easy to make using commonly available parts.
- +1: it should be compatible with not only our current washing machine but with any other as well.
HardwareAfter a lot of thinking I came up with the idea that I should monitor the movement of the washing machine: What all washing machines have in common is that as they move clothes around they move a bit. I recently played around with Freescale's MMA7361 3-axis accelerometer and I thought that must be sensitive enough to do the job.
I quickly built a prototype on breadboard and started to experiment:
|The breadboard uses modules and breakout boards I had created for quick and easy prototyping.|
|Circuit diagram for washing machine monitor|
|Front side of custom made PCB|
|Back side of custom made PCB|
3 AD converters are used for interpreting the analog signals from the accelerometer (MMA 7361). The remaining I/O pins are used for the buzzer, the LED, and ICSP. Since pins used for ICSP some pins have to be shared between ICSP and other functions: the usage can be selected using a jumper. It's not a big deal: once the development is over these jumpers do not need to be touched.
|The big black blob is the buzzer that is rated 12V but is loud enough even from 4-5V.|
An LED is used for visual feedback of some parts of the operation while a piezo buzzer is used to notify the user (me! :) ) that the washing is done.
Where possible, I used SMD parts so that the circuit as small as possible.
|Only a few capacitors and the diode is on the bottom side.|
Power considerationsSince the circuit consumes very little power, the obvious choice of powering it is batteries. I was considering using some rechargeable battery packs from old mobiles to give those batteries new life. However, I realized they would be a hassle to recharge and they are not available readily should I had to make further copies of the circuit for others. At the end I settled with using a battery pack consisting of 4 rechargeable AA batteries. These batteries are available everywhere as they are used in most devices around us. I also happened to have a holder for 4 batteries left over from another project.
Another advantage of using 4 AA batteries is that the voltage never goes above 6.5V which is given in the PIC's datasheet as the absolute maximum voltage for VDD. Standard AA batteries supply 1.2V each and even without load they don't go above 1.5V. As an extra caution, I designed a 1N4148 diode in between the power supplied and the circuit to drop about 0.7V. This can be substituted with a short wire if the excess safety is not required. According to the PIC's datasheet the PIC should work OK as long as the supplied voltage is greater than 2.0V. All of this means I can do away without using a voltage stabilizer for the PIC.
The MMA 7361 requires 3.3V to operate - I provide that using a low dropout voltage stabilizer, LP3872 from National Semiconductors (now Texas Instruments).
FirmwareThe firmware was entirely written in assembly using MPLAB X IDE. Not much to talk about :)))
The source code is available on request.
UsageWhen you start the washing machine you need to switch on the little gadget using the switch on the side of the board. The monitor provides a visible "heartbeat" pulse roughly every second. This gives you visual feedback to verify it is on. Also, whenever movement is detected it pulses extra - another visual clue to make sure it is operating as expected. Whenever it doesn't detect movement for about a minute it stops the "heartbeat" and starts beeping. To start things all over you need to switch it off then on again.
Here is a short demo of its use:
MechanicsIt is important to note that the successful operation of the gadget heavily depends on the strong mechanical coupling between the washing machine and the gadget. This means any housing or case it will go in must have no or very limited padding. I spent hours during development trying to figure out why it works perfectly on my desk and why not on the washing machine itself. The answer was easy: on the back of the breadboard there is some sticky padding (probably so that you can stick it to your working surface - which I never used) which is very little but enough to absorb any vibration from the washing machine. On my desk I had the breadboard on its edge, so the padding was omitted.
I found that a small piece of neodymium magnet is strong enough to hold the circuit in place, even on the side of the washing machine!
|Hanging on the side of the washing machine - the 2 small magnets even hold the battery pack!|
Other usesI have accomplished my goal of creating a washing machine monitor/notifier solution within the criteria set out at the beginning.
As a side effect, I realized, the same circuit (with some modification in the firmware) could be used for a number of other purposes, for example it could be an alarm for a suitcase on a bus/train that starts beeping once somebody tries to take it while you are sleeping.
If you come up with more uses please share them in the comments.
This device was a runner up in Lifehacker's Best Laundry Hack competition.