Using the Modern Radio IOT Stick With a Raspberry Pi

by MDRDIO in Circuits > Electronics

228 Views, 3 Favorites, 0 Comments

Using the Modern Radio IOT Stick With a Raspberry Pi

IMG_0227.jpeg

The Modern Radio IOT Stick is a BLE gateway that scans and return the readings from various other Modern Radio sensors within proximity. it uses a console program that is capable of running across multiple platforms. In this tutorial we will use the IOT stick with a raspberry pi along with a modern radio Environment Monitor and Smart Moisture probe. The environment monitor will relay temperature and humidity data back to the IOT Stick while the Smart Moisture probe will send temperature and a capacitance index value indicating the moisture level. The data will then be posted to Dweet.io where it can b tracked visually.

Supplies

Place Sensors

IMG_0237.png
IMG_0245.png
IMG_0243.png

Place your sensors where you would like to collect readings. I placed my Smart Moisture probe near a plant in my shrub bed and the environment monitor in my garage. Be sure the raspberry pi and the IOT Stick are in a central location to these sensors.

Copy Files

directory.png

Create a "bin" folder on your pi at "/home/pi/bin", and copy all of the files from the GitHub page to the "bin" directory on the pi.

Configure the Pi

656a14be-ba7e-476d-94ff-3dba02c4050e_Pi+ZERO+Angle+1.jpg

Use the following tutorials to install an MQTT client and broker that the IOT Stick console program will use for communication. In order to run the IOT stick console program on the pi we will also need to install mono.

Get Sensor Readings

run.png
confirmStart.png

To start collecting data from the environment monitor sensor, we will run the collector.py downloaded earlier. On the raspberry pi navigate to the the directory "/home/pi/bin/net472" and enter the command: "python3 /home/pi/bin/collector.py". The console program should start.

Retrieve the Readings From Dweet.io

dweetio.png
SMPDweet.png

From a web browser, navigate to Dweet.io and click on the discover link. Do a ctrl+f and enter the Mac address of your environment monitor. The data record for the sensor should be located. clicking on the record will display Temperature humid, RSSI, and battery voltage.