Shapy
Published © GPL3+

Particle Switch

A Particle-Android powered wall socket for when your device is left charging at home and you want to switch it off or on from anywhere.

IntermediateFull instructions provided5 hours1,950
Particle Switch

Things used in this project

Hardware components

Photon
Particle Photon
×1
MORNSUN LS03-15B05SR2S(-F) AC to DC converter
×1
MORNSUN B0503S-1WR2 DC to DC converter
×1
Relay (generic)
×1
Darlington High Power Transistor
Darlington High Power Transistor
×1
1 Amp Fuse
×1
S14K320 Varistor
×1
13D-5 Thermistor
×1
SMBJ7.0A Diode
×1
Resistor 10k ohm
Resistor 10k ohm
×1
Capacitor 10uF(400V)
×1
Capacitor 10uF(10-20V)
×1
Capacitor 4.7 µF
Capacitor 4.7 µF
×1
Capacitor 330uF(25V)
×1
Capacitor 68uF(35V)
×1
Capacitor 0.1uF(50V)
×1
Capacitor 1nF(400VAC)
×1
Inductor 4.7 mH
Inductor 4.7 mH
×1
Inductor 2.2uH
×1
Male Header 40 Position 1 Row (0.1")
Male Header 40 Position 1 Row (0.1")
×1
Female Header 8 Position 1 Row (0.1")
Female Header 8 Position 1 Row (0.1")
×1
Jumper wires (generic)
Jumper wires (generic)
×1
Wire Cable - By the Foot
OpenBuilds Wire Cable - By the Foot
×1
Wall Socket
×1
Wall Socket Plug
×1

Software apps and online services

Particle Cloud IDE
Google Android Studio
Autodesk Eagle CAD

Hand tools and fabrication machines

Soldering iron (generic)
Soldering iron (generic)
Wire Cutter
Electrical Tape
Copper Clad PCB/Perfboard

Story

Read more

Schematics

Switch Circuit

Code

Photon Code

C/C++
///List of Variables...

int button = D0;
int indicator = D7;

void setup() {
    pinMode(button,OUTPUT);
    pinMode(indicator,OUTPUT);
    
    Particle.function("power",Power);
}

void loop() {
}

//Main Function...

int Power(String command){
    //Particle.publish("Led Status",command,60,PRIVATE);
    if (command=="on") {
        //Power ON...
        digitalWrite(button,HIGH);
        digitalWrite(indicator,HIGH);
        return 1;
    }
    else if (command=="off") {
        //Power OFF...
        digitalWrite(button,LOW);
        digitalWrite(indicator,LOW);
        return 0;
    }
    else {
        return -1;
    }
}

Android App

Credits

Shapy

Shapy

1 project • 1 follower

Comments

Add projectSign up / Login