Giter Site home page Giter Site logo

firebase-sensor's Introduction

Firebase based temperature / humidity logger

Build Status Coverage Status

The idea

The idea came from Tim Hodson who blogged about it some time ago. So huge thanks to him.

Firebase

My goal

My goals were simple:

  • No limit in the number of sensors.
  • Adding a new sensor should only mean to modify a little the database and upload the readings but never change a single line of the Web UI.

Structure

It was kind of hard for me to structure the base as I'm more used to relationnal databases. I ended up doing this :

root
  errors
    GUID
      time
      message
  readingCategories
    [hum|lum|temp]
      fractionSize
      label
      order
      unit
  readings
    room_id
      GUID
        time
        temp
        hum
        lum
  rooms
    room_id
      label
      color
      icon
      readings
        temp
        hum
        lum

Security

TODO

Todo

I'll probably add the battery level of some sensors, that will mean changing the database structure and the Web UI.

The Web UI

How does it look ?

Image

How do I make this work

Easy :

  • Get latest release and decompress it on your webserver
  • Deploy it to you firebase hosting.
  • Access it.

Sending values to Firebase

TODO

Monitoring

I wanted to make sure to be notified if no new data are added to Firebase (because I lost my Internet connection or a crash happenned).

So I created a Cloud function monitor to check the time of the last child of most of my reading . I simply compare the node's date with the current date and output a JSON object with the status.

The only thing left is to add a keyword monitor to UptimeRobot.

Licence

As stated in the LICENCE file, everything here is licensed under the GPL V2

firebase-sensor's People

Contributors

seblucas avatar

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.