Git Product home page Git Product logo

netatmo-data-downloader's Introduction

Netatmo Data Downloader

Code for downloading public weather data from the Netatmo API.

Setup

  1. Clone this repository to your local machine.
  2. If you haven't already, install a recent version of Node.js (needs to be a version with ES6 support), and NPM.
  3. Go into the root of the netatmo-data-downloader directory.
  4. Download the required packages with:

npm install

  1. In order to authenticate with the Netatmo API you will need to specify your Netatmo developer credentials. If you haven't already set up a Netatmo Developer Account.
  2. Once logged in the Technical Parameters section will list the Client id and Client secret you will need.
  3. Create a file called .env in the root of the netatmo-data-downloader directory.
  4. Enter your Netatmo username and password, along with the client id and secret, in this file as follows:
NETATMO_CLIENT_ID=YourClientIdHere
NETATMO_CLIENT_SECRET=YourClientSecretHere
[email protected]
NETATMO_PASSWORD=YourSuperSecretPassword
  1. The code will load these details into process.env in order to configure the code.
  2. This code is currently set up to just get temperature data for Amsterdam for Sept 2016. To do this run:

npm run get-amsterdam

  1. If you look at the package.json file you will see that all this is doing is running node tasks/get-amsterdam-data/get-data.js. If successful the data is saved to csv files in tasks/get-amsterdam-data/data.
  2. If you wish to edit the timeframe, location, variables, etc, then edit the file /tasks/get-amsterdam-data/get-data.js
  3. Alternatively create a new folder in the /tasks/ directory and use the Amsterdam code as a basis for your own custom script.

TODOs

  • At some point I'd like to update the code to use Promises instead of Callbacks as starting to see Callback Hell!.
  • Would also be nice if all the data wasn't held in memory, i.e. data should be continually piped into the csv rather than waiting till all the data has been retrieved from the API before saving.

netatmo-data-downloader's People

Contributors

sibell avatar

Stargazers

Yunfei Li avatar  avatar Matthias Demuzere avatar

Watchers

 avatar

netatmo-data-downloader's Issues

is this still usable?

Hi Si (sorry if mistake your name),
I have no experience with Javascript but I really need this tool for my research work. Yesterday I installed node.js and tried to run your code following your instructions, but it ended up with many errors which are beyond my ability to understand. I guess I need to learn a bit Javascript if I want to solve my problems.
However, since the last update was already 3 years ago, I am wondering if it is still compatiable with current netatmo API?

Thanks and best regards,
Yunfei

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.