How to create a cloud gateway convert Sigfox to MQTT

This tutorial shows how to create a simple node gateway on IBM BlueMix in order to receive sigfox-backend HTTP callback, JSONified and send it to MQTT broker.

Step 1: Create a Node Js Application on IBM Bluemix:

1Step 2: Write a simple web service to get parameter in HTTP callback from sigfox-backend server. This information will be encapsulate in MQTT payload and publish to MQTT broker. We can use publish broker provided by Mosquito company at address: ‘mqtt://test.mosquitto.org:8080’.

2

Step 3: On sigfox-backend site, we define a call back following the form:

http://[YourAdd]:[yourport]/sigfox?device={device}&time={time}&signal={signal}&avgSignal={avgSignal}&station={station}&lat={lat}&lng={lng}&rssi={rssi}&data={data}

3

Step 4: Create a HTML page subscribe to broker in order to display sigfox’s converted message. We use the Paho JavaScript Client which is a browser-based library to connect to an MQTT server.

4

Step 5: Open HTML web page after turning on sigfox device, we will see the receiving messages

5

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

<span>%d</span> bloggers like this: