ProtoCentral Kalam v3 IOT platform - Starter Kit


This kit includes all the basic components required to get your Kalam-based IoT project up and running.

Posting Data to ThingSpeak

This document guides you through the various steps required to put the basic blocks togther and get your first program up and running.

If you have not already setup Arduino for use with Kalam, please refer the previous document.

Step 1 - Setting up ThingSpeak

The Internet of Things (IoT) provides access to a broad range of embedded devices and web services. ThingSpeak is an IoT platform that enables you to collect, store, analyze, visualize, and act on data from sensors or actuators.The primary element of ThingSpeak activity is the channel, which contains data fields, location fields, and a status field. After you create a ThingSpeak channel, you can write data to the channel, process and view the data and react to the data. We like Thingspeak because it's easy to use and flexible.

Sign-up for ThingSpeak

ThingSpeak requires a user account and a channel. A channel is where you send data and where ThingSpeak stores data. Each channel has up to 8 data fields, location fields, and a status field. You can send data every 15 seconds to ThingSpeak.

First, sign up for new User Account – https://thingspeak.com/users/sign_up

signup

Create a ThingSpeak channel

A channel on ThingSpeak is where a "Thing" posts data to. You can create a new Channel by selecting Channels, My Channels, and then New Channel

newchannel

You can change the name to fit your need and you can add a description corresponding to the channel. You can add any other useful description into the metadata field. In the same page, you should see the fields for Latitude, Longitude and Elevation. Also, you can make the channel as "Private" or "Public".

Once you have edited the fields, click on ‘Save Channel’ button.

Step 2 - Wiring up the Kalam

If you have followed the steps mentioned in the previous document, you should have a breadboard set-up.

You will need a pushbutton, an LED and some breadboard jumper wires for this part of the experiment. The breadboard has to be set up in the following manner.

newchannel

Step 3 - Setup Arduino Sketch

Download the "Example1-HelloThingSpeak" code from the Kalam Github site.

This example program connects to the internet via your local wireless network (Wi-fi) and updates the data in the ThingSpeak channel. You need to configure your Wi-Fi connection first by editing the following lines in the example code:

const char* ssid = "********"; // your network id const char* password = "*********"; // passcode

newchannel

To make the examples work with your ThingSpeak channel, you will need to configure the myChannelNumber and myWriteAPIKey variables. Located he following line in the code and change the API key.

const char* tokenid = "OFZEOKCL95S8HRNI"; // your channel token id

Load the example in the Arduino IDE. Make sure to select the board as "Sparkfun ESP8266 Thing Dev" and the COM port. Then, upload the code to your Kalam board.

Step 4 - See the action

If all goes well, you should be able to see one data point added to your Thingspeak plot each time you press the button.

newchannel