cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - When posting, your subject should be specific and summarize your question. Here are some additional tips on asking a great question. X

Delivering Arduino Collected Data to ThingWorx using MQTT

No ratings

ThingWorx provides multiple ways to deliver your data to the server. You can choose from the C based EMS to your own C application that uses the C SDK as well as SDKs for many popular languages but what can you do if the device you want to collect data on is so small that it need a very lightweight data delivery method. Normally you would consider using the REST web service interface and writing your own custom client to post your data by there is an alternative, MQTT. MQTT is a lightweight protocol that can be used from an Arduino with an Ethernet Shield that can stream real time data directly to ThingWorx by installing the MQTT Marketplace Extension on your server.

To learn more about how this kind of solution worked, I created this slide deck while building a hardware example:

DeliveringArduinoDataToThingworx.pdf

Hopefully, it can help others out who want to create this kind of solution as well.

Comments

Hi Bill, does it work to send data to Arduino too or only to get data from it?

Cheers

Ewerton

See: Arduino Client for MQTT

See: Arduino | MQTT

It appears you need certain Ethernet or WiFi Shields to accomplish the needed connection to the broker.

You can both pushing and subscribe to MQTT topics using the Arduino MQTT library.

Yes. A standard Arduino does not have any network support. You would need to have an ethernet shield to do this particular example.

Thanks Bill/Bruce.. I will pass this info on and see if we move fwd .

Great,What if i need to send using GPRS modem

Can anyone provide his Arduino Libraries used for this Project? I have a Problem with "SRAM" and I can not fix it...

Arduino MQTT Library for SIM800 GSM Modem | Random Codes - Elementz Tech Blog

talks about an MQTT library for use with the SIM800.

kt1

Hi Bill, what possible changes would have to be made if I want to do it with arduino wireless shield.

The big difference between an ethernet shield and a wifi shield is in how you connect. Wifi connections are much more complex than wired ethernet. You have to configure the SSID and likely, a WPA2 passphrase in order to make the connection. See whatever tutorials are supplied for your shield (there are several different ones available). Several of them use a serial connection to store the configuration on the board using programs on your PC to drive the process (for those of you who ever used a dialup modem, they use the same basic AT command approach that was used to configure the modem's behavior to configure the wifi module). See Arduino - ArduinoWiFiShield for details about how to use the Arduino wifi shield. It has code samples that show code-based connection to the network.

Version history
Last update:
‎Oct 31, 2015 05:52 PM
Updated by:
Labels (1)
Attachments