Bluetooth Weather Station



In my 5th semester at college, I took the course 310244, "Database Management Systems Applications", which involved a "mini" project to be submitted at the end of the course demonstrating use of MongoDB.

I decided to add an IoT angle to it by adding some hardware. Taking cue from my previous project, involving sensing and ZigBee, I decided to build a "Wireless Weather Station" using Bluetooth

I had a new MSP430F5529 Launchpad with the Sensor Hub Booster Pack. The Booster Pack has a whole lot of sensors on it, allowing me to sense the ambient Light, Temperature, Pressure and Humidity.

The Booster Hub communicates with the launchpad through I2C, and I attached an HC-05 Bluetooth module to the available UART port. I encoded the data from the sensors into JSON format and passed it to the HC-05 On my laptop, I paired the HC-05 and created a serial port to read data from the launchpad. A python script was implemented to read the JSON data from the serial port and store it onto my MongoDB database. The same python script had another thread to read data from the database and refresh a MatPlotLib graph, if there was any new reading available. All code for the launchpad was written in energia and is compatible with the arduino. The entire code is available on my github account