Things used in this project

Hardware components:
150803 particle 46
Particle Internet Button
×1
Photon new
Particle Photon
×1
2" PVC Compression Coupling
×1
Clear PVC Tube
3" diameter will fit the internet button perfectly, but you'll need to cut a notch to run the cable. Any length you'd like, but mine was 6", but I probably should have done 8".
×1
Software apps and online services:
Q8wtlimqnp04fzhtr9v5
IFTTT Maker service
Hand tools and fabrication machines:
Dremel
Only used this to cut the notch for the cable.
Hot Glue gun
To attach the caps to the tube.

Code

Untitled fileC/C++
#include "InternetButton.h" 
int ledState = false; 
int prevState = false; 
InternetButton b = InternetButton(); 
void setup() { 
   Particle.function("meeting", meeting); 
   b.begin(); 
} 
void loop(){ 
   if (prevState != ledState){ 
       switch (ledState){ 
           case 1: 
               b.allLedsOn(0,255,0); 
               break; 
           case 0: 
               b.allLedsOn(255,0,0); 
               break; 
           case -1: 
               b.allLedsOff(); 
               break; 
       } 
       prevState = ledState; 
   } 
} 
// send  a '1' for Green 
// send  a '0' for Red 
// send -a '-1' for OFF 
int meeting(String command){ 
   ledState = command.toInt(); 
   return 1; 
} 

Credits

Particle mark lg8kxhtlgf
Kevin Monk
0 projects • 0 followers
Customer Operations Manager at Particle
Contact
Thanks to Moors7.

Replications

Did you replicate this project? Share it!

I made one

Love this project? Think it could be improved? Tell us what you think!

Give feedback

Comments

Add projectSign up / Login