Things used in this project

Hardware components:
Photon new
Particle Photon
×1
Adafruit industries ada592 image 75px
USB-A to Micro-USB Cable
×1
12002 04
Breadboard (generic)
×1
09590 01
LED (generic)
×1
Software apps and online services:
Particle Buid
Twlarge
IFTTT Twitter service

Schematics

Particle Photon Connections
Untitled%20sketch bb

Code

Code Arduino
//The pin you want to control, in this case I'm blinking the on-board blue LED on digital pin 7
int led = D7;
//This function is called after the Photon has started 
void setup(){
    //We set the pin mode to output
    pinMode(led, OUTPUT);
    //We "Subscribe" to our IFTTT event called Button so that we get events for it 
    Particle.subscribe("Button", myHandler);
}
//The program loop, not sure if this has to be here for the program to run or not
void loop() {
}
//The function that handles the event from IFTTT
void myHandler(const char *event, const char *data){
    // We'll turn the LED on
    digitalWrite(led, HIGH);
    
    // We'll leave it on for 5 second...
    delay(5000);
    
    //Then we'll turn it off...
    digitalWrite(led, LOW);
}

Credits

Replications

Did you replicate this project? Share it!

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

Give feedback

Comments

Similar projects you might like

Direct Photon to TP-Link Device Control
Easy
  • 291
  • 7

Full instructions

Add this small file to your project to control TP-Link bulbs and plugs directly with simple subroutine calls.

Poor Man's CAN Bus
Easy
  • 163
  • 4

Protip

Learn how to connect microcontrollers together using the CAN bus by using a simple AND gate

Internet Connected Bubble Machine
Easy
  • 34
  • 2

Full instructions

Make it possible to activate a bubble machine from anywhere using a Particle Photon

MyPIR-Sensor activate analog RGB Stripe controlled by Photon
Easy
  • 92
  • 2

Full instructions

At my age you have to get up at night and get tired on the way to the bathroom. Using a PIR-Sensor to trigger light on!

Weather Box
Easy
  • 2,185
  • 11

Full instructions

Small weather station that uploads to Weather Underground with a NeoPixel ring for visualization.

Washer/Dryer Monitor
Easy
  • 582
  • 5

Full instructions

Monitor your appliance's power indicator with a photocell for easy notifications without high voltage wiring.

Add projectSign up / Login
Respect project