Soil Moisture sensor with Arduino in Tinkercad | how to use soil moisture sensor in Tinkercad Circuit diagram: Arduino Sketch: // C++ code // int moisture_data = 0; void setup() { pinMode(A0, INPUT); Serial.begin(9600); pinMode(12, OUTPUT); pinMode(6, OUTPUT); } void loop() { moisture_data = analogRead(A0); Serial.println(moisture_data); if (moisture_data < 21) { digitalWrite(12, HIGH); digitalWrite(6, HIGH); } else { digitalWrite(12, LOW); digitalWrite(6, LOW); } delay(10); // Delay a little bit to improve simulation performance }
IoT Based weather station using BMP280 & ESP32 | BMP280 pressure and temperature sensor with Blynk
Hello Everyone!
I have come up with new tutorial IoT Based weather station using BMP280 & ESP32 | BMP280 pressure and temperature sensor with Blynk #esp32 #iot #blynk
In this video what you will learn about? 1. How to configure the new Blynk IoT Platform. 2. How to setup web dashboard 3. How to create template in blynk iot 4. How to interface BMP280 with esp32. 5. How to read pressure ,temperature ,and altitude form BMP2801.You can Watch Playlist on New Blynk IoT Platfom
New Blynk IoT platform with esp32 | how to setup automation in Blynk IoT app
https://youtu.be/O2HZuu4KtIc
2.How to create events in blynk IoT platform | events in new Blynk IoT platform 🔥🔥
https://youtu.be/X5zVaGk8QV0
3.IoT Based smart garden monitoring system | Smart plant monitoring using Blynk IoT
https://youtu.be/GTdxD5vQwy0
4.Water level monitoring system using IoT | IoT based water level using Nodemcu ESP8266 & ESP32
https://youtu.be/WsfyeBtGXNM
5.Monitoring MPU6050 data over blynk IoT platform | IoT based Vibration Monitoring using Esp32 MPU6050
https://youtu.be/zFbH-f8mhAE
6.IoT Based weather station using BMP280 & ESP32 | BMP280 pressure and temperature sensor with Blynk
https://youtu.be/4CysMQn-OLE
7.Home automation using blynk IoT platform | home automation project using esp32 #homeautomation
https://youtu.be/Moow367kucU
You can watch my previous series videos based on Arduino IoT cloud Platform
1.Getting started with Arduino IoT cloud | Arduino IoT cloud with Esp32🔥 #arduinoiotcloud #esp32
https://youtu.be/I92CX2V5NxA
2. Home automation using Arduino IoT cloud | controlling relay using Arduino IoT cloud #iot #iotproject
https://youtu.be/19DYvM-N2ps
3. Soil moisture sensor with Arduino IoT cloud | IOT Smart Plant Monitoring System #iot #esp32
https://youtu.be/VryVyi9Kj0Y
4. How to send sensor data from Arduino IoT cloud to Email | webhook & IFTTT with Arduino IoT cloud #iot
https://youtu.be/KwkAI8ZT7fo
5. Sending sensor data to google sheet using Arduino IoT cloud | log sensor data in cloud #esp32 #iot
https://youtu.be/D5gBc29V8xg
Circuit Diagram:
/***************************************************************************
This is a library for the BMP280 humidity, temperature & pressure sensor
Designed specifically to work with the Adafruit BMP280 Breakout
----> http://www.adafruit.com/products/2651
These sensors use I2C or SPI to communicate, 2 or 4 pins are required
to interface.
Adafruit invests time and resources providing this open source code,
please support Adafruit andopen-source hardware by purchasing products
from Adafruit!
Written by Limor Fried & Kevin Townsend for Adafruit Industries.
BSD license, all text above must be included in any redistribution
***************************************************************************/
#define BLYNK_TEMPLATE_ID "TMPL1UwtJgg3"
#define BLYNK_DEVICE_NAME "WAETHER STATION USING BMP280"
#define BLYNK_AUTH_TOKEN "5-ZgjAJPX1P56s-CmQrftUtgCcKtlA3A"
#define BLYNK_PRINT Serial
#include <WiFi.h>
#include <WiFiClient.h>
#include <BlynkSimpleEsp32.h>
char auth[] = BLYNK_AUTH_TOKEN;
char ssid[] = "impulsetech"; // type your wifi name
char pass[] = "impulse567"; // type your wifi password
BlynkTimer timer;
#include <Wire.h>
#include <SPI.h>
#include <Adafruit_BMP280.h>
#define BMP_SCK (13)
#define BMP_MISO (12)
#define BMP_MOSI (11)
#define BMP_CS (10)
Adafruit_BMP280 bmp; // I2C
//Adafruit_BMP280 bmp(BMP_CS); // hardware SPI
//Adafruit_BMP280 bmp(BMP_CS, BMP_MOSI, BMP_MISO, BMP_SCK);
void setup() {
Blynk.begin(auth, ssid, pass);
timer.setInterval(100L, sendSensor);
Serial.begin(9600);
while ( !Serial ) delay(100); // wait for native usb
Serial.println(F("BMP280 test"));
unsigned status;
//status = bmp.begin(BMP280_ADDRESS_ALT, BMP280_CHIPID);
status = bmp.begin(0x76);
if (!status) {
Serial.println(F("Could not find a valid BMP280 sensor, check wiring or "
"try a different address!"));
Serial.print("SensorID was: 0x"); Serial.println(bmp.sensorID(),16);
Serial.print(" ID of 0xFF probably means a bad address, a BMP 180 or BMP 085\n");
Serial.print(" ID of 0x56-0x58 represents a BMP 280,\n");
Serial.print(" ID of 0x60 represents a BME 280.\n");
Serial.print(" ID of 0x61 represents a BME 680.\n");
while (1) delay(10);
}
/* Default settings from datasheet. */
bmp.setSampling(Adafruit_BMP280::MODE_NORMAL, /* Operating Mode. */
Adafruit_BMP280::SAMPLING_X2, /* Temp. oversampling */
Adafruit_BMP280::SAMPLING_X16, /* Pressure oversampling */
Adafruit_BMP280::FILTER_X16, /* Filtering. */
Adafruit_BMP280::STANDBY_MS_500); /* Standby time. */
}
void sendSensor()
{
int temp =bmp.readTemperature();
float pressure= bmp.readPressure();
float altitude=bmp.readAltitude(1017);
Serial.print(F("Temperature = "));
Serial.print(bmp.readTemperature());
Serial.println(" *C");
Serial.print(F("Pressure = "));
Serial.print(bmp.readPressure());
Serial.println(" Pa");
Serial.print(F("Approx altitude = "));
Serial.print(bmp.readAltitude(1017)); /* Adjusted to local forecast! */
Serial.println(" m"); //If you don't know it, modify it until you get your current altitude
Serial.println();
Blynk.virtualWrite(V0, temp);
Blynk.virtualWrite(V1, pressure);
Blynk.virtualWrite(V2, altitude); //The "1019.66" is the pressure(hPa) at sea level in day in your region
delay(2000);
}
void loop()
{
Blynk.run();
timer.run();
}
For complete video tutorial:
Comments
Post a Comment
If you any query please comment