Coder Social home page Coder Social logo

luuuuk / home-data Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 2.17 MB

A Flutter application to display environmental data collected in and around your home.

Kotlin 0.27% Swift 0.87% Objective-C 0.08% Dart 70.09% HTML 8.43% Ruby 2.90% Python 10.98% JavaScript 6.38%

home-data's Introduction

Home Data

A data visualisation project for data collected at home, such as Temperature, Humidity, Air Pressure and Air Quality.

Project Structure

The project offers the following main components:

  • python script to collect data (in folder sensor_script)
  • Flutter application to visualize data (in folder home_data_flutter)
  • Node JS server to make data available to flutter application (in folder server)

Data collection

The project includes a script (based on this example) to collect data for example on a Raspberry Pi, using a BME680 sensor. Said script is written in python. After cloning the project and setting up the connection to the sensor, the script can be started using the following command: python3 bme680_com.py

It will first conduct a burn in, to set the baseline for the Air Quality Index computation. More info here.

After the 5 min burn in, data will be collected every 10 minutes and sent to a MongoDB server on the local network. Basic setup instructions for MongoDB on a RaspberryPi can be found here.

Node JS Server

A simple node js server with express js is being used to query the MongoDB database on the same device upon request and answer with the data that has been collected in the last 24 hours.

The server can be started from within the server folder with the following command: node index.js

You'll need the following packages to run the server:

  • expressjs
  • mongoose

The server will connect to the MongoDB database and then accept requests on port 3001.

Flutter Application

The flutter application provides a simple interface to display the data of the last 24 hours. A server request at serverIP:3001/recentData will return the data needed. This request will be fired upon start of the app and upon pull-to-refresh inside the app. NOTE: the server IP address in the project files is in a local network, remember to change it accordingly.

Screenshots of the app:

home-data's People

Contributors

luuuuk avatar

Watchers

 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.