Coder Social home page Coder Social logo

molepage / airthingsmqtt Goto Github PK

View Code? Open in Web Editor NEW

This project forked from sabeechen/airthingsmqtt

1.0 0.0 1.0 17 KB

An ESP32 arduino sketch that searches for a compatible Airthings device and publishes the radon level, temperature, and humidity to an MQTT server.

License: MIT License

C++ 100.00%

airthingsmqtt's Introduction

My modifications:

Original README below.

Airthing MQTT Bridge via an ESP32

  • Author: Stephen Beechen
  • Copyright (C) 2019 Stephen Beechen.
  • Released under the MIT license.

An ESP32 arduino sketch that searches for a compatible Airthings device and publishes the radon level, temperature, and humidity to an MQTT server.

The sketch was created with the intention to allow Airthings devices to cheaply integrate with Home Assistant.

How to Use

  • Set up your Airthings following the manufacter's instructions.
  • Install the PubSubClient library.
  • Set your WiFi credentials in the sketch.
  • Set your MQTT server/credentials in the sketch.
  • Update the published topics in the sketch, if desired.
  • Flash to any ESP32 board. NOTE: The Bluetooth library is HUGE, so in the Arduino IDE you might need to change "Tools" -> Partition Scheme" to something like "No OTA" to create enough space for the compiled sketch.
  • Watch the Serial output to make sure it works.

Usage Details

  • The Airthings only reports the 24 hour and lifetime average radon concentrations over Bluetooth.
  • The library runs once an hour to take a reading and deep sleeps in between, so feasibly this could run on a battery for a very long time.
  • The library will attempt to find any airthings device to read from, picking the first it finds. The Airthings BLE API is unauthenticated so no device configuration or pairing is necessary on the Airthings.
  • The library will not interfere with your Airthings' normal upload to a phone or the cloud.
  • If it fails to read, it will attempt again after 30 seconds.
  • I only have an Airthings Wave to test this with, though presumably it would also work with the Wave Plus.
  • The ESP32's bluetooth stack is a little unstable IMHO so expect this to hang for a few minutes, restart prematurely, and report errors often.

License

MIT License

Copyright (c) 2019 Stephen Beechen

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

airthingsmqtt's People

Contributors

molepage avatar

Stargazers

 avatar

Forkers

sycophantic

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.