Skip to content

Instantly share code, notes, and snippets.

View xxlukas42's full-sized avatar

xxlukas42

View GitHub Profile
@xxlukas42
xxlukas42 / plant_monitoring.ino
Created March 9, 2018 11:31
Plant condition monitoring system based on Blynk platform and ThingSpeak
/*************************************************************
Wemos Lolin32 Lite (ESP32)
Plant monitoring example
by Petr Lukas
Simple device setup, which allows to monitor temperature,
moisture, air pressure, light level and soil moisture
*************************************************************
BLYNK LIBRARY
@xxlukas42
xxlukas42 / moisture.ino
Created July 16, 2018 18:58
Capacitive soil moisture sensor
#include <SPI.h>
#include <Wire.h>
#include <SFE_MicroOLED.h>
#define PIN_RESET 255
#define DC_JUMPER 0
int i;
int moi = 0;
@xxlukas42
xxlukas42 / lolin_d32_pro.ino
Last active March 3, 2023 22:47
Basic demo for Wemos Lolin D32 PRO (ESP32) with build-in SD card reader, TFT display shield and SHT30 sensor
/*************************************************************
Wemos Lolin D32 PRO (ESP32)
Basic demo
by Petr Lukas
*************************************************************/
#include <Adafruit_GFX.h> // Core graphics library
#include <Adafruit_ST7735.h> // Hardware-specific library
#include <WEMOS_SHT3X.h> // SHT30 library
#include <SPI.h>
#include <SD.h> // SD card library
@xxlukas42
xxlukas42 / ambient_led.ino
Created September 15, 2018 11:43
Ambient light shield and LED shield for D1 Pro Mini
/*************************************************************
Wemos Lolin D1 PRO (ESP8266)
Basic demo
by Petr Lukas
*************************************************************/
// Install Adafruit_NeoPixel library https://github.com/adafruit/Adafruit_NeoPixel first
#include <Adafruit_NeoPixel.h>
#include <Wire.h>
@xxlukas42
xxlukas42 / dht12.ino
Created September 15, 2018 11:48
DHT12 shield for D1 mini Pro
// Install https://github.com/wemos/WEMOS_DHT12_Arduino_Library first
#include <WEMOS_DHT12.h>
DHT12 dht12;
void setup() {
Serial.begin(115200);
}
/*************************************************************
Wemos Lolin D32 PRO (ESP32) NTP
Basic demo
by Petr Lukas
*************************************************************/
/*
Based on script
by Michael Margolis
modified 9 Apr 2012
by Tom Igoe
@xxlukas42
xxlukas42 / weather_station.ino
Created March 8, 2019 19:24
Simple sensorless weather station (OpenWeatherMap API)
#include <WiFi.h>
#include <HTTPClient.h>
#include <ArduinoJson.h>
#include <TM1637Display.h>
#define CLK 32
#define DIO 33
const uint8_t CELSIUS[] = {SEG_A | SEG_D | SEG_E | SEG_F};
const uint8_t MINUS[] = {SEG_G};
@xxlukas42
xxlukas42 / eink_demo.ino
Created March 31, 2019 20:47
MH-ET LIVE 1.54-inches E-Paper demo
#include <GxEPD.h>
#include <GxGDEP015OC1/GxGDEP015OC1.cpp>
#include <Fonts/OpenSansBold12pt7b.h>
#include <Fonts/OpenSansBold14pt7b.h>
#include <Fonts/OpenSansBold30pt7b.h>
#include <GxIO/GxIO_SPI/GxIO_SPI.cpp>
#include <GxIO/GxIO.cpp>
#include GxEPD_BitmapExamples
/*************************************************************
Philips Hue @ Wemos D1 mini (ESP8266)
Basic demo of PIR and ambient light sensor to demonstrate
communication between ESP and Hue gateway
by Petr Lukas
Functionality:
Sensor activates the light only in case certain level of light is detected
(by default less than 100 lx). If the ambient light sensor light level exceeds the set value,
@xxlukas42
xxlukas42 / philips_hue_ir.ino
Created April 14, 2019 09:28
ESP32 and ESP8266 communication with Philips Hue bridge
/*************************************************************
Hue @ D1 mini Pro (ESP8266)
Basic demo of switch based on IR sensor to demonstrate
communication between ESP and Hue gateway
Version: 1.00
by Petr Lukas
Functionality:
Identify IR signal and switch light on and off using IR remote control.
*************************************************************/