Things used in this project

Hardware components:
Hologram SIM Card w/Device Management
Hologram Dash
SparkFun Beefcake Relay Control Kit (Ver. 2.0)
10A GFCI Power Outlet
Dual Power Outlet Enclosure
Dual Power Outlet Enclosure Cover
Standard Power Strip
2A USB Power Adapter
Standard USB Cable
826 04
Male/Female Jumper Wires
AMP Female Disconnects (12 - 10)
Push-In Wire Connectors (3-Port)
Software apps and online services:
Avatar light%402x
Hologram Data Router
Ide web
Arduino IDE
Hand tools and fabrication machines:
Wire Stripper (Generic)
09507 01
Soldering iron (generic)
Screw Driver (phillips)
Precision Screw Driver Set
Cell Phone (SMS Compatible)


Hologram Dash SMS Relay Control CodeArduino
Upload this code to the Hologram Dash for it to control the connected power outlet.
The Dash will accept the following SMS messages:
ON (turns the power on)
OFF (turns the power off)
RESET (turns the power off for 30 seconds, then turns it back on)
int controlPin = R04;

// EFFECTS: Strips away the length number from the payload as it's not needed.
String stripOffLengthNumber(String payload) {

  int index = 0;
  while (payload[index] == ',') {
  while (payload[index] != ',') {

  payload.remove(0, index);

  return payload;

void setup()
  Serial0.begin(9600); /* TTL UART */
  pinMode(controlPin, OUTPUT);

char currChar;
String tempBuffer = "";
String payload = "";
bool foundSMS = false;

void loop()

  while (Serial0.available()) {

  while (SerialCloud.available()) {

    currChar = (char);

    // check if the current buffer hits the SMSRCVD code.
    if (!foundSMS) {

      if (tempBuffer == "SMSRCVD") {
        foundSMS = true;
    // If it received the SMSRCVD code, the payload will get populated until
    // we get a \n.
    else if (currChar == '\n'){

      SerialUSB.println("\nSMS received: ");
      Serial0.println("\nSMS received: ");

      payload = stripOffLengthNumber(payload);


      if (payload[0] == 'O' && payload[1] == 'N') {
        digitalWrite(controlPin, LOW);
        SerialUSB.println("Switched to ON");
        Serial0.println("Switched to ON"); 
      } else if (payload[0] == 'O' && payload[1] == 'F' && payload[2] == 'F') {
        digitalWrite(controlPin, HIGH);
        SerialUSB.println("Switched to OFF");
        Serial0.println("Switched to OFF"); 
      } else if (payload[0] == 'R' && payload[1] == 'E' && payload[2] == 'S' && payload[3] == 'E' && payload[4] == 'T') {
        digitalWrite(controlPin, HIGH);
        SerialUSB.println("Resetting... Switched to OFF");
        Serial0.println("Resetting... Switched to OFF");
        digitalWrite(controlPin, LOW);
        SerialUSB.println("Switched to ON");
        Serial0.println("Switched to ON");

      // reset foundSMS and the payload for the next iteration.
      foundSMS = false;
      payload = "";
    else {

    // Only keep a sliding buffer length of size 7
    // (need to only check for SMSRCVD).
    if (tempBuffer.length() >= 7) {
       tempBuffer.remove(0, 1);

    // add latest char to our buffer.




Thanks to Nate.


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


Similar projects you might like

The composting friend
  • 611
  • 34

Full instructions

Our goal is to make composting easier to use and to maintain.

Automatic Fear 1.0
  • 284
  • 5

Full instructions

A device capable of frightening my sister and with compatibility with other members of the family

Theremino Adapter for CNC.
  • 281
  • 7

Full instructions

Attention: This adapter is used to replace the parallel port with the USB, and not to operate Mach3 CNC or Linux.

Theremino Logger
  • 157
  • 4

Datalogger is simple to use but with great performance. The base, concise and intuitive.

Smart Sump Pump Monitor
  • 827
  • 10

Full instructions

Sump pump monitor has live dashboard for usage statistics, and data logging. Email notifications through Particle Cloud or IFTTT.

Smart Home 433MHz RF <-> MQTT Gateway With Some Extras
  • 819
  • 4

Full instructions

Control your RF devices via MQTT and integrate them into your smart home 🏡, using the WEMOS ESP8266 connected to MQTT service via WiFi.

ProjectsCommunitiesContestsLiveAppsBetaFree StoreBlogAdd projectSign up / Login
Respect project