• Stars
    star
    136
  • Rank 262,554 (Top 6 %)
  • Language
    JavaScript
  • Created over 8 years ago
  • Updated about 8 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Web server using a Raspberry Pi and DHT22 sensor to graph the humidity and temperature in my apartment over time.

Introduction

Web server using a Raspberry Pi and DHT22 sensor to graph the humidity and temperature in my apartment over time. The data can be accessed over a web browser.

Skills I learned during this project:

  • Setup the minimal Raspbian operating system to the RPi, called Minibian
  • Install and use Python, and the Python virtual environment
  • Install and use Flask, a Python-based web micro-framework
  • Install and use uWSGI as the application server for Flask
  • Install and use Nginx light-weight web server
  • Use Skeleton to make the web UI look better
  • Use the RPi GPIOs as digital input and outputs
  • Use a DHT22 humidity and temperature sensor
  • Install and use the SQLite database to store sensor data
  • Add a cron job to store sensor data every so many minutes
  • Use the Google Chart API to create visual representations of the sensor data
  • Use Javascript/JQuery to add interactivity to web pages
  • Use Plotly for graphical analysis of sensor data

Summary

The lab_app folder contains the code for the project (The html folder, button.py, and blink.py were just for testing purposes).

Inside lab_app you will find the main python server, lab_app.py. This uses a cronjob to take a temperature and humidity reading every so many minutes, and stores it in a sqlite database. The web server has 2 views, lab_temp.html and lab_env_db.html, which I refer to as current view and historic view respectively.

Current

In the current view, the current temperature and humidity taken from the sensor is displayed on the web page. This page updates every 10 seconds, and has a link to the historic view.

Historic

The historic view has a couple features. The first is a to and from date input, which uses a date time picker plugin. Combined with a submit button, this allows you to view the temperature and humidity data within any date time range easily. The next feature are four radio buttons, to easily see the last 3, 6, 12, and 24 hours of data. There are two links, one to the current view, and another to export the data to Plotly. Clicking this link will send you to plotly and show you a graph of Temperature vs Humidity.

The main view are 2 tables combined with Google Charts graphs. The tables both scroll, and the charts display data across the time selected. The times are displayed in your own time zone, as it is determined from your browser.

YouTube

YouTube: https://www.youtube.com/watch?v=hFqNiZ4p0Ss

Circuit Diagram

Circuit Diagram

More Repositories

1

LiFi-Music

Transmit music file over the visible light spectrum using LiFi (Visible Light Communication) to a speaker.
23
star
2

LEDStrip

Various scripts for LED strips, mostly for NeoPixel or DotStar, written in C/Arduino
Arduino
16
star
3

Dash-Button

Having fun with the Amazon Dash Button
Python
10
star
4

LeapMotion-Arduino

Leap Motion projects involving the Arduino
JavaScript
9
star
5

AdaBox001

Example projects that I created based on components received with Adafruit's Adabox001.
Arduino
6
star
6

Geotify

Test app for learning iOS CoreLocation and Geofences with Notifications
Swift
6
star
7

LeapMotion-PhilipsHue

Leap Motion projects with Philips Hue lights
JavaScript
5
star
8

Mini-Processor-Simulator

Core part of a mini processor simulator called MySPIM using the C language on a Unix/Linux platform. MySPIM demonstrates some functions of the MIPS processor as well as the principle of separating the data-path from the control signals of the MIPS processor. The MySPIM simulator reads in a file containing MIPS machine code (in a specified the format) and simulates what MIPS does cycle-by-cycle (single-cycle data path).
C
4
star
9

Arduino-Step-by-Step

Arduino code for various sensors, from step by step Arduino
Arduino
3
star
10

AdaBox002

BLE controlled robot using the Adafruit Feather 32u4 Bluefruit board.
Arduino
3
star
11

MagicLamp

Cool light fixture made out of Qi wireless charging technology, Arduino Trinket Pro, Neo Pixel LED Ring, 3D printed base, and a crystal ball (for light diffuser).
Arduino
3
star
12

Hello-World-iOS

Hello World Application for iOS with Swift
Swift
3
star
13

Hue-Button

Button that will use a Raspberry Pi to turn on Philips Hue Lights
JavaScript
2
star
14

LeapMotion

Generic repo to test applications of Leap Motion, especially using cylon.js to connect with Arduino, Raspberry Pi, and various other interfaces.
JavaScript
2
star
15

ArduinoMotionDetection

Uses an Arduino, and PIR (passive infrared) sensor to detect motion and light up an LED. Further expanded to make an alarm sound when motion is detected.
C
2
star
16

WebBased-Technology-FinalProject

Final Project website for CIS4004 class at UCF, Web Based IT.
HTML
2
star
17

Fade

Changes brightness of an LED manually, and then going from full brightness and fading to off.
Arduino
1
star
18

ComputerScience1

Data Structures and Algorithm Analysis, with an emphasis on C programming.
C
1
star
19

PotentiometerBrightness

Uses an Arduino, and a potentiometer to increase and decrease an LED through analog, instead of digital.
Arduino
1
star
20

TouchPoint-Simulation

A simulation of a Touch Point found at Walt Disney World Resort, through an Arduino Uno, color sensor, proximity sensor, and Neo Pixel rings.
Arduino
1
star
21

Permanent-Storage

iOS app for testing the storage of user data on the phone
Swift
1
star
22

RaspberryPi

Repo for cool python scripts to use for Raspberry Pi
C
1
star
23

losant-kit-builder

Source code required for the Losant Builder Kit.
Arduino
1
star
24

ComputerScience2

Data Structures and Algorithm Analysis, with an emphasis on Java programming.
Java
1
star
25

Pokemon-Ornament

Using the Neomatrix library, constructed a 8x8 LED matrix Christmas ornament, that scrolls through some of my favorite Pokemon from Gen 1.
C++
1
star
26

RFID-Reader

Using an RFID-RC522 sensor with an Arduino Uno to read different RFID chips. Depending on the UID read, I change the color of a Neo Pixel ring.
Arduino
1
star
27

Programming-Languages

Various assignments in programming languages that range from High-level to functional. From Programming Languages class at UCF.
Racket
1
star
28

UNTZtrument

UNTZtrument: a Trellis MIDI Instrument. Created using an Arduino Leonardo, translucent button pads, driver boards, diffused white LEDS, and a custom laser cut enclosure. This box turns into a USB MIDI device that works with any computer and has 64 buttons with individually-controllable LEDs.
Arduino
1
star
29

LeapMotion-Eyesbot

Leap Motion projects with Eyesbot robot
JavaScript
1
star
30

Navigation-Bar

An iOS app to demonstrate the use of a Navigation Bar
Swift
1
star