Giovanni Gentile
Published © LGPL

Cayenne and SparkFun IoT 433 Mhz Sockets

I know the Z-Wave or Netatmo system for IoT, domotic system and automation of house. But now you can make an ESP8266 DoMo system.

IntermediateFull instructions provided2 hours2,104
Cayenne and SparkFun IoT 433 Mhz Sockets

Things used in this project

Hardware components

SparkFun ESP8266 Thing - Dev Board
SparkFun ESP8266 Thing - Dev Board
×1
Arduino Nano R3
Arduino Nano R3
×1
Breadboard (generic)
Breadboard (generic)
×1
Receiver and Transmitter 433 Mhz radio
×1

Software apps and online services

Arduino IDE
Arduino IDE
Arduino Web Editor
Arduino Web Editor
Arduino Cloud
Arduino Cloud
Cayenne
myDevices Cayenne

Hand tools and fabrication machines

Soldering iron (generic)
Soldering iron (generic)

Story

Read more

Code

Code snippet #1

Plain text
<p>//#define CAYENNE_DEBUG         // Uncomment to show debug messages<br>#define CAYENNE_PRINT Serial  // Comment this out to disable prints and save space
#include "CayenneDefines.h"
#include "BlynkSimpleEsp8266.h"
#include "CayenneWiFiClient.h"</p><p>#include RCSwitch mySwitch = RCSwitch();</p><p>// Cayenne authentication token. This should be obtained from the Cayenne Dashboard.
char token[] = "xxxxxxxx";
// Your network name and password.
char ssid[] = "xxxxxxxx";
char password[] = "xxxxxxxx";</p><p>void setup()
{
	mySwitch.setPulseLength(xxxx);
	Serial.begin(9600);
        mySwitch.enableTransmit(16); // on NodeMCU is D0
	Cayenne.begin(token, ssid, password);
}</p><p>void loop()
{
	Cayenne.run();
}</p><p>CAYENNE_IN(V2)
{
  CAYENNE_LOG("Got a value: %s", getValue.asStr());
  int i = getValue.asInt();
  
  if (i == 0)
  {
    mySwitch.send("xxxxxxxxxxxxxxxxxxxxxxxx");
  }
  else
  {
    mySwitch.send("xxxxxxxxxxxxxxxxxxxxxxxx");</p><p>  }  
}</p>

Credits

Giovanni Gentile

Giovanni Gentile

31 projects • 60 followers
Graduated in Psychology expert in new technologies and communication, with expertise in electronics, automation and home automation.

Comments