IoT & Salesforce

Last Dreamforce, my esteemed colleague Swaroop Shere and I worked on a unique integration of IoT devices with Salesforce.com. We were inspired to work on this project at the IoT zone which was a huge focus during that year’s conference (..certainly a prefix to the new IoT cloud, that Salesforce announced at DF 2015). The motivation for this project was to explore the power of Raspberry pi and the immense potential that the Salesforce platform provides to develop IoT based solutions.

This blog post will talk about the project in high level. I will write a follow-up on the nitty-gritty details about the actual setup and various moving parts involved.

What is Internet of Things?

Quoting wikipedia — “The Internet of Things (IoT) is the interconnection of uniquely identifiable embedded computing devices within the existing Internet infrastructure”

Imagine a world where innumerable devices, sensors, and appliances are connected wirelessly, constantly transferring data to intelligent systems that collect and analyse this data to establish trends in a way that provides great opportunities for businesses to connect with their consumers.

To drive this concept home, we designed and implemented this working prototype integrating small hardware devices with the cloud using Raspberry Pi; and subsequently using the versatility and power of Salesforce platform to perform meaningful actions on that data collected from the sensors. Our project consisted of an end-to-end simulation of a Greenhouse Monitoring and Management application with tight integration with Salesforce.com and a partner app exchange app called SMS Magic.

Use Case and Project Setup

Consider a Greenhouse which employs a number of sensors in order to monitor environmental conditions like temperature, soil moisture, air humidity and light, in order to protect sensitive plants, gardens and greenhouses while the farmer is away.

We designed our setup in a way that when temperature values reported by the sensors go beyond a specified threshold, notifications are sent out to a smartphone signifying a fire alert.

The various moving parts of our project setup consist of :

  1. A Rasberry Pi board with serial connector and breadboard
  2. Temperature and Luminosity control sensors
  3. Salesforce.com developer org
  4. A smartphone with Salesforce1 app downloaded
  5. App exchange package SMS Magic installed in the developer org

The following flow diagram depicts the functionality of the project -

In a nutshell, our set up consisted of mounting of sensors on a motherboard and transferring float values from sensors using serial port into Rasberry Pi. On the Pi, a python script executes that sends data into our Salesforce developer org using REST API. This data is organized within Salesforce into custom object records. Using flow triggers on top of this data, we fire a Chatter post on the users profile in addition to sending a text message on his smartphone every time the temperature goes beyond a specified threshold.

I will post details soon :)

Like what you read? Give Chitra Gulabrani a round of applause.

From a quick cheer to a standing ovation, clap to show how much you enjoyed this story.