Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/dragonscypher/weather-window
Weather Monitoring System
https://github.com/dragonscypher/weather-window
aws-lambda python raspberry-pi
Last synced: about 2 months ago
JSON representation
Weather Monitoring System
- Host: GitHub
- URL: https://github.com/dragonscypher/weather-window
- Owner: dragonscypher
- License: mit
- Created: 2024-02-16T22:16:52.000Z (10 months ago)
- Default Branch: main
- Last Pushed: 2024-10-28T04:06:06.000Z (about 2 months ago)
- Last Synced: 2024-10-28T07:15:15.322Z (about 2 months ago)
- Topics: aws-lambda, python, raspberry-pi
- Language: HCL
- Homepage:
- Size: 21.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Weather Window: Weather Monitoring System π¦οΈ
## π Abstract
- **Objective**: Develop a Raspberry Pi-based weather observation system.
- **Features**: Measures temperature, humidity, and atmospheric pressure.
- **Alerts**: Activates alerts through email, LED signals, or auditory alarms upon threshold breaches.
- **Integration**: Utilizes AWS Lambda and AWS SNS for efficient email notifications.## π οΈ Prerequisites
- Raspberry Pi with internet access.
- DHT11 sensor (or compatible) for environmental readings.
- Python 3.
- An AWS account for AWS Lambda, AWS IoT Core, and AWS SNS.
- Required Python libraries: `Adafruit_DHT`, `awscrt`, `boto3`, `awsiot`.
- Terraform for infrastructure provisioning.## π¦ Installation
1. **Clone the Repository**:
```bash
git clone https://github.com/dragonscypher/Weather-Window.git
```
2. **Install Dependencies**:
```bash
pip install Adafruit_DHT awscrt boto3
```## βοΈ Configuration
- Fill in AWS IoT Core details and other AWS resource information in the Python script.
- Set email credentials as environment variables:
```bash
export MY_EMAIL_PASSWORD='your_secure_password'
```
- Terraform is used to create the required AWS infrastructure, including AWS IoT Thing, Lambda functions, and a DynamoDB table for storing sensor data.## π Usage
1. **Provision AWS Resources**:
Run Terraform to create the necessary AWS resources:
```bash
terraform init
terraform apply
```
2. **Start the System**:
```bash
python mqtt_email_notification.py
```
3. Monitor weather data, store it in DynamoDB, and receive alerts based on set thresholds.## π Project Overview
The Weather Monitoring System, "Weather Window," leverages AWS IoT Core to collect and send weather data (temperature and humidity) from a DHT11 sensor connected to a Raspberry Pi. The collected data is published to AWS IoT Core using MQTT, stored in a DynamoDB table, and notifications are sent using AWS Lambda functions and SNS.### Key Features:
- **AWS IoT Core Integration**: The system uses MQTT to publish sensor data to AWS IoT Core, ensuring real-time updates.
- **Data Storage**: Weather data is stored in DynamoDB for historical reference and analysis.
- **AWS Lambda**: Lambda functions are used to process messages, store data, and send alerts.
- **Notifications**: Email notifications are sent using AWS SNS based on threshold values for temperature and humidity.## πΊοΈ System Architecture
The system architecture for "Weather Window" involves multiple components working together to provide real-time weather monitoring and alerting. Below is a high-level overview:1. **Raspberry Pi**: Collects data from the DHT11 sensor and publishes it to AWS IoT Core using MQTT.
2. **AWS IoT Core**: Serves as the central messaging broker that receives data from the Raspberry Pi.
3. **AWS Lambda Functions**: Processes the incoming data, stores it in DynamoDB, and triggers alerts.
4. **AWS DynamoDB**: Stores weather data for historical reference and analysis.
5. **AWS SNS**: Sends email notifications when the data breaches the defined thresholds.![System Architecture Diagram](system_architecture.png)
## π‘ Contributing
Your contributions are welcome! Open an issue or pull request to suggest changes or additions.## π License
This project is under the [MIT License](https://choosealicense.com/licenses/mit/).