Skip to content

Open Source Weather and Air quality station for the Raspberry Pi

License

LGPL-2.1, MIT licenses found

Licenses found

LGPL-2.1
LICENSE
MIT
libgps-LICENSE
Notifications You must be signed in to change notification settings

mgrennan/oswabox

Repository files navigation

OSWABox - Ver. 0.0.7
================

This code is developed to read weather data from the Open Source Weather station.
OSWABox is based on the AirPi (AirPi.es) who's code is written in Python.

This code is written in C. It uses the wiringPi2 library (github.com/WiringPi/WiringPi2-Python)
also written in written in C. 

OSWABox has example programs for each of the OSWABox functions:


    blink - Blink the Green LED

    temperature - Read the tempiture and humity from the RHT03

    pressure - Read the air pressure, temp and altitude from the BMP085

    mcp3008 - Read the voltage on one pin of the mcp3008

    wind - Read the wind speed and direction fromt the wind sensors

    rain - Read the rain sensor

    gps-serial - Read GPS data from the serial port and print time, location and altitude

    gps-gpsd - Read GPS data from the gpsd daemon and print time, location and altitude

There are three programs to use as a production weather station depending on how
you want to operate. 

    oswabox - run as a client program program read all the guage and outputs
	the data into a number of formats.

    oswaboxd - is a daemon designed to continusly collect guage data. This allows for
	observations like daily temp hi/low and rainfall. You can controle the observation
        and reporting time.


Compile and execure
===================
After you download the source. Change to the source diretory.

To compile all the program and put them in the ./build directory.

    make

To compile an individual example

    cd src
    make {exampleName}

All resulting appliation are written to the build directory. For exampe, to read the
the current observations:

pi@station:~$  sudo build/oswabox -g d
       Date: 2014-02-05T17:46:43.290Z
  Longitude:    -95.6212
   Latitude:     37.5333
   Altitude:    399.9000
GPS Average:    401.9281
Temperature:     20.7000 C      =  69.26 F
   Humitity:     17.4000 %
   Pressure:    986.1500 hPa    =  29.12 inch of mercury
 Wind Speed:      9.2000 mph
  Direction:     19.0000 degrees
  Rain Fall:      0.0000 ipm
   Device 0:    731.5947 ohms
   Device 1:     21.5264 ohms
   Device 2:   2427.7175 ohms
   Device 3:  34114.6875 ohms
   Device 4:     38.9795 ohms
   Device 5:     27.6422 ohms
   Device 6:     26.8559 ohms


The same program can out SQL.

pi@station:~$  sudo build/oswabox -o s -g d -t obs -s TORKS

INSERT INTO obs (Station,Datetime,Longitude,Latitude,Temperature,Pressure,Relative_Humidity,
Wind_Speed,Wind_Direction,Rain,Device_1,Device_2,Device_3,Device_4,Device_5,Device_6,Device_7,
Device_8) values ("TORKS","2014-02-05T17:35:12.289Z",-95.6212,37.5333,20.5000,986.2800,17.6000,
0.0000,0.0000,0.0000,745.7983,21.5264,2157.4407,32126.1602,41.2002,28.2320,27.6422,41742.9688);


To continusly collect observation data for your weather station use - oswaboxd - The daemon.

To install this program run:

  make install

TODO:  Create and document how oswaboxd interfaces with programs like wView and WeeWx.


THANKS TOO
==========

I want to thank Walter Dal Mut for the gps library used here. https://github.com/wdalmut/libgps

About

Open Source Weather and Air quality station for the Raspberry Pi

Resources

License

LGPL-2.1, MIT licenses found

Licenses found

LGPL-2.1
LICENSE
MIT
libgps-LICENSE

Stars

Watchers

Forks

Packages

No packages published

Languages