IBM has launched IBM developerWorks Recipes, a platform for developers to share tutorials around the IBM Bluemix platform and the IoT Foundation. Bluemix is IBM’s integration platform for cloud applications. For Reactive Blocks, Bluemix can serve as backend for IoT applications.
Three Ways From Reactive Blocks into Bluemix
To send data between a Reactive Blocks gateway and Bluemix, we have several options, all supported by specific building blocks:
IoT Foundation: IoT Foundation is a service from IBM to send event data into Bluemix, and control devices via commands. IoT Foundation uses MQTT in its core. It adds a specific topic structure to manage devices, events and commands. It also stores all events, so that they are available as historic data. IoT Foundation is ideal for sending sensor readings and similar data. Since you send it to IBM’s broker, you do not have to setup your own MQTT broker. We have two tutorials on how to use the IoT Foundation: Without setup of Bluemix in Reactive Blocks to IoT Foundation (Part 1: Quickstart), and a more elaborate tutorial in Reactive Blocks to IoT Foundation (Part 2: IoT Device).
MQTT: You can also use ‘raw’ MQTT, in case IoT Foundation is not suitable for your kind of data. Simply use one of our MQTT building blocks, setup your own MQTT broker, and start publishing.
HTTP: You can send data via HTTP. Simply use the HTTP Post block and build an HTTP Post request. We use that in the tutorial Intrusion Detection to Twitter via IBM Bluemix to send images into Bluemix.
Within Bluemix, you have different options to build and run applications. One of them is Node-RED. That’s a pretty neat way to quickly plug together some logic, and perfect for prototyping. Each of the blocks on the gateway have a correspondence in Node-RED on Bluemix, which makes things work nicely together with our gateway programmed in Reactive Blocks.
The IBM developeWorks Recipes
We have the following recipes ready:
Reactive Blocks to IoT Foundation (Part 1: Quickstart) This tutorial explains how you can send data into the IBM Internet of Things Foundation. This first part uses the Quickstart service, which does not require a sign up for Bluemix or the IoT Foundation Service.
Reactive Blocks to IoT Foundation (Part 2: IoT Device) This tutorial explains how you can send data into the IBM Internet of Things Foundation. This second part registers a device and builds a simple application in the cloud on Node-RED.
Intrusion Detection to Twitter via IBM Bluemix This tutorial explains how you can use the camera module to detect an intruder, forward the data via HTTP, post into Node-RED on Bluemix and forward it from there as a tweet to Twitter.