Creating a Home Assistant Web Scraper Sensor

Here is a demonstration of using lxml for scraping a website to extract essential HTML data and pass the data as sensor to Home Assistant. GitHub: debsahu/lxmlWebScraper Here is a demonstration of using lxml for scraping a website to extract essential HTML data and pass the data as sensor to Home Assistant. Overview Installing lxml If working in virtual environment, install lxml using pip $ pip3 install lxml If working on python installation installed globally...

December 1, 2018 · Debashish Sahu

ESP8266/ESP32 Connecting to SSL/TLSv1.2 Secured Mosquitto MQTT Broker

Demonstration on ESP8266 & ESP32 using SSL/TLSv1.2 two-way handshake with secured mosquitto broker. SSL is preferred way of encryption of communication between devices over the internet. Here we secure a mosquitto MQTT broker and connect to it via ESP8266 & ESP32 that do a two-way handshake. Andreas Spiess on ESP devices & SSL: https://www.youtube.com/watch?v=Wm1xKj4bKsY GitHub: debsahu/ESP_MQTT_Secure ⚠️ ⚠️ ⚠️ Will not be maintained/updated ⚠️ ⚠️ ⚠️ Demonstration on ESP8266 & ESP32 using SSL/TLSv1....

November 17, 2018 · Debashish Sahu

Using ESP8266 to Call RESTful API From TheRide to Get Real-Time BUS Data

Here is a tutorial on how to call RESTful API on ESP8266 and process the data using ArduinoJSON. This data is visually represented in a NeoPixel ring for easy tracking of 3 buses approaching a certain stop. This code also sends MQTT messages with the received data. debsahu/RESTful-Ride Using ESP8266 to call RESTful API from http://TheRide.org to get real-time BUS data Features: Easy to read interface Fast and Responsive Portable, i....

October 27, 2018 · Debashish Sahu

Hacking an Automatic Trash Can to Listen to You

Idea To convert an automatic trash can into a smart one. Hardware Automatic Trash Can Wemos D1 mini (ESP8266) 2N2222 transistor Implementation Here we use an ESP8266 to tap into the pins and emulate a physical button press. The ESP8266 uses a code as described in https://github.com/debsahu/SmartTrashCan to emulate a Wemo Switch, which is detected by Alexa/Echo device as a switch. GitHub: debsahu/SmartTrashCan Dependencies Library Link Use Wemo Switch Emulator Library https://github....

October 22, 2018 · Debashish Sahu

Using Gestures to Control Lights on Home-Assistant

Getting one’s hands on APDS9960 is very easy, that can be used to detect hand gestures. Here we use this sensor to control lights on Home Assistant based on a gesture observed on sensor. Software Libraries used: HARestAPI GitHub: debsahu/HARestAPI APDS9960 GitHub: SteveQuinn1/SparkFun_APDS-9960_Sensor_Arduino_Library SSD1306 OLED I2C GitHub: ThingPulse/esp8266-oled-ssd1306

July 21, 2018 · Debashish Sahu

ESP8266 Talking to AWS IoT Using MQTT

Arduino library connecting to the AWS IoT service from an ESP8266 using websockets and MQTT. GitHub: debsahu/esp8266-arduino-aws-iot-ws ⚠️ ⚠️ ⚠️ This is no longer maintained and obsolete, there is better way to do this: follow instructions from here Still want to use this, follow instructions below ⚠️ ⚠️ ⚠️ Arduino Library derived from joekickass/esp8266-arduino-aws-iot-ws to work with Arduino Dependencies Library Link Use arduinoWebSockets https://github.com/Links2004/arduinoWebSockets websocket comm impl PahoMQTT https://projects.eclipse.org/projects/technology.paho/downloads mqtt comm impl ArduinoJSON 6....

July 13, 2018 · Debashish Sahu

ESP8266 Making Google Home Speak

Using esp8266-google-home-notifier library on ESP8266 to make Google Home speak! Software Prerequisites/Limitations The GoogleHomeName must match the name of Google Home / mini setup in Google Home App. The ESP8266 must be on the same network as Google Home. MDNS: Dont include ESP8266mDNS.h supplied by Arduino-ESP8266. Internal ESP8266mDNS.h should suffice. Libraries required esp8266-google-home-notifier esp8266-google-tts WiFiManager (optional) GitHub: debsahu/GoogleSay sercret.h #define SECRET const char* ssid = "<WiFiSSID>"; const char* password = "<WiFiPassword>"; GoogleSay....

July 6, 2018 · Debashish Sahu

ESP32 Communicating With Xiaomi Flora Plant Sensor Using BLE

Using ESP32 to communicate with Xiaomi flora (miflora) plant sensor using BLE and posting the values on MQTT server. I also demonstrate the use of Home Assistant miflora sensor component. Change ESP32 Partition: https://desire.giesecke.tk/index.php/2018/04/20/change-partition-size-arduino-ide/ Home Assistant miflora sensor: https://www.home-assistant.io/components/sensor.miflora/ GitHub: sidddy/flora Archived code from https://github.com/sidddy/flora below config.h // array of different xiaomi flora MAC addresses char* FLORA_DEVICES[] = { "C4:7C:8D:67:11:11", "C4:7C:8D:67:22:22", "C4:7C:8D:67:33:33" }; // sleep between to runs in seconds #define SLEEP_DURATION 30 * 60 // emergency hibernate countdown in seconds #define EMERGENCY_HIBERNATE 3 * 60 // how often should the battery be read - in run count #define BATTERY_INTERVAL 6 // how often should a device be retried in a run when something fails #define RETRY 3 const char* WIFI_SSID = "ssid"; const char* WIFI_PASSWORD = "password"; // MQTT topic gets defined by "<MQTT_BASE_TOPIC>/<MAC_ADDRESS>/<property>" // where MAC_ADDRESS is one of the values from FLORA_DEVICES array // property is either temperature, moisture, conductivity, light or battery const char* MQTT_HOST = "10....

June 29, 2018 · Debashish Sahu

Resurrecting a GPU Cooling Fan Using a Micro-Processor and PWM

Trying to rescue a GPU cooling system containing a 12V 4-wire fan using a PWM signal from ATtiny85 and reading a voltage from ADC from a potentiometer knob. Ultimately building a 4-wire fan controller. 25kHz PWM on ESP8266: https://github.com/esp8266/Arduino/issues/4598 Software

June 16, 2018 · Debashish Sahu

Building LED String Using Capacitive Dropper

Convert a string of filament lights (X-mas decoration lights) into a LED string of lights. Inspired from bigclive’s project

June 10, 2018 · Debashish Sahu