Hey guys,
Here is my project:
My washer and dryer are located downstairs outside and it is very hard to hear when their are finished.
For many years (this is not an obsession, but I have always wanted to do this) I have been looking into different microcontrollers (MC) (hell I even tried an Amazon button), but the thing that kept getting in the way was the way the MC was going to alert me. I tried Twitter (yes, @Laundry_Done) and SMS to mention a few. I was a contributor for the Digispark campaign and when Oak was announced I thought with built-in wifi and the low cost, sure sign me up...
So this does not go on even further....
I finally got my Oak up and communicating and the some semblance of code in there. So my coding skills suck, but I did manage to get it to work.
The process is this:
A button press triggers the Oak to publish on Particle. When Particle gets the notification, it tells IFTTT to send an email.
If anyone can help me clean it up or have any other ideas to make it better, please PM me.
I use 2 Oaks, one to be installed in the washer and one will be installed in the dryer.
The built-in LED (pin 1) is just a visual for me during testing.
Here is my code:
#define BUTTON_PIN 6
#define LED_PIN 1
void setup() {
Particle.begin();
pinMode(BUTTON_PIN, INPUT);
pinMode(LED_PIN, OUTPUT);
}
void loop() {
if (digitalRead(BUTTON_PIN) == HIGH) {
Particle.publish("WASHER_DONE", "Washer Done");
digitalWrite(LED_PIN, HIGH);
} else {
digitalWrite(LED_PIN, LOW);
}
}
Thanks everyone and sorry for the long post.
Alan