Skip to content

fxwiegand/rustberry-weather

Repository files navigation

rustberry-weather

A weather station for the raspberry pi written in rust

What you need

  • A raspberry pi with rust installed
  • A Bosch bme280 sensor with breakout board
  • Some jumper cables for the connection between the pi and the sensor

Setup your weather station

  • Connect the vcc, gnd, scl and sda pins of your bme280 sensor to the corresponding pins of your raspberry pi
  • Clone the repository
  • Configure the Rocket.toml so the website is running on your desired adress, port etc.
  • Setup an Postgres database and export your database url with export DATABASE_URL=postgres://username:password@domain:5432/yourdatabase
  • Install diesel_cli with cargo install diesel_cli or cargo install diesel_cli --no-default-features --features postgres if you only wish to use it with PostgreSQL
  • Either grant yourself access to /dev/i2c-1/ for letting the program connect to the sensor to run with cargo run server or build the executable with cargo build --release and run as sudo with sudo target/release/rustberry-weather server

Built with

  • Rocket - A web framework for Rust
  • Tera - A powerful, easy to use template engine for Rust
  • bme280 - A rust device driver for the Bosch BME280
  • Vega/Vega-Lite - A visualization grammar

Authors

License

This project is licensed under the MIT License - see the LICENSE.md file for details

About

A weather station for the raspberry pi

Resources

License

Stars

Watchers

Forks

Packages

No packages published