Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/lilanga/smartmeternano
IoT smart meter using ESP32 chipset
https://github.com/lilanga/smartmeternano
aws-iot-core esp32 freertos home-assistant mqtt platformio smart-metering
Last synced: 15 days ago
JSON representation
IoT smart meter using ESP32 chipset
- Host: GitHub
- URL: https://github.com/lilanga/smartmeternano
- Owner: Lilanga
- Created: 2023-11-28T11:56:20.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2023-11-28T12:36:02.000Z (about 1 year ago)
- Last Synced: 2024-11-27T21:13:09.955Z (2 months ago)
- Topics: aws-iot-core, esp32, freertos, home-assistant, mqtt, platformio, smart-metering
- Language: C
- Homepage:
- Size: 31.3 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# Smart meter nano
Smart meter nano is a tiny smart meter solution to measure electricy power consumption in a building.
Device is designed to be installed in a DIN rail box and is powered by a 5V USB power supply or a 5V power supply from the DIN rail box. We are using Emonlib to measure the power consumption and a ESP32 micro controller to send the data to a MQTT broker. Here we are using AWS IoT Core as MQTT broker. The device is also capable of sending data to Home Assistant MQTT broker. Firmware is written utilizing FreeRTOS.
## Hardware
Here we are using Lilygo TTGO T-Display ESP32 micro controller. It has a 1.14 inch LCD display and a 5V USB power supply. It is also possible to power the device with a 5V power supply from the DIN rail box. We are utilizing the onboard LED to display measurements and connection status to MQTT brokers.
## Configuration
Configuration is done by editing the `config.h` file. You need to set the following parameters:
* `WIFI_NETWORK`: SSID of the WiFi network
* `WIFI_PASSWORD`: Password of the WiFi network
* `AWS_IOT_ENDPOINT`: AWS IoT Core endpoint address
* `AWS_IOT_TOPIC`: AWS IoT Core topic to publish the data### Home Assistant
If you are using Home Assistant you can use the configuration definde in config.dist.h to enable Home Assistant mqtt support. You can turn off AWS IoT core data forwarding by setting `AWS_IOT_ENABLED` to `false`. You can also turn off Home Assistant mqtt support by setting `HOME_ASSISTANT_ENABLED` to `false`.
## Iot Core certificates
To communicate with AWS IoT Core you need to create a thing and download the certificates.
In the `certificates` folder you need to place the following certificate files:* `amazonrootca1.pem`
* `certificate.pem.crt`
* `private.pem.key`