ESP8266 is a very popular and inexpensive WiFi-chip that can be a real contributor for taking small gadgets to the Internet. This post describes my first experiments with an Adafruit ESP8266-model.
With an Arduino and some servos lying around, I find it hard not to try out something robot-like. An obstacle-avoiding mini car is probably one of the easiest projects to get started with and as our house is abundant with Lego, the building blocks for the construction are readily available.
In my previous post, I experimented with sending measurements values from an Arduino UNO to a Raspberry Pi via a 433 MHz radio protocol. After testing the setup for a few days, I decided to make some improvements:
- Add an additional sensor for measuring outdoor temperatures. Now there will be four different sensor values transmitted from the Arduino to the Raspberry Pi.
- Add the possibility to send float values for more precision and, for adopting to the Swedish climate, allow negative values.
- On the receiver side (the Raspberry Pi), add storage of the values to a csv file so that the measurements can be visualized in graphs with Excel or a similar application.
- Improve the noise tolerance.
The Arduino computers are excellent for reading sensor data, and they are so inexpensive and consume very little power that you can use plenty of them in your home without breaking your wallet.
The Raspberry on the other hand, is more powerful, a bit pricier, but can easily be programmed to perform more challenging tasks like storing data and hosting a web server.
What if your Arduinos (the Major Toms) could report their sensor measurements to the Raspberry (Ground Control) in a simple way? Then you could access and analyze all measurements via a Web interface on the Raspberry (using a mobile phone e.g.)
This blog post describes my setup for sending sensor data via the 433 MHz band to the Raspberry.
In this post I will show how I have used a Raspberry Pi as a relay server that can be controlled via a web app on e.g. a mobile phone or via REST calls. The system consists of:
- A Raspberry Pi 2 with Raspbian
- A set of relays connected via the GPIO pins on the RPi
- Flask running a Python WebAPI on the RPi
There are many inexpensive kits available for controlling voltage outlets at home, but making your own is an opportunity for learning and tinkering, so let’s go!