0

I am looking for a way for my ESP8266 Arduino device to subscribe to the IBM Watson IoT platform to receive device management messages (reboot, update etc.). I have located examples that use the PubSubClient library (https://developer.ibm.com/recipes/tutorials/run-an-esp8266arduino-as-a-iot-foundation-managed-device/) to do this, however, I have not yet found a working example of PubSubClient using TLS1.2 (a requirement for this project). As such I am currently using the Adafruit_MQTT_Client which can connect and publish to Watson using TLS1.2, but I have not had success subscribing to the platform. If anyone could suggest a way to connect, publish and subscribe to IBM Watson IoT platform using TLS1.2, it would be much appreciated!

mactro
  • 518
  • 7
  • 13
JC_123
  • 1
  • If you can successfully connect and publish to IoT Platform using TLS1.2, then IMO the problem isn't the connection from your ESP8266 to the IoT Platform, i.e. the problem isn't TLS because the same TCP connection is used for both publishing device data and for subscribing to management commands to the device. Maybe your subscription to the command topics for your device isn't correct, or maybe you haven't specified to IoTP that your device accepts commands. – DisappointedByUnaccountableMod Oct 09 '16 at 08:51
  • The docs for IoTP are available in bluemix here: https://new-console.ng.bluemix.net/docs/services/IoT/index.html look below Developing Devices->Device Management Protocol and Device Management Requests. Can't be any more specific with the information you have provided: "have not had success". – DisappointedByUnaccountableMod Oct 09 '16 at 08:52
  • Thank you for your response. After updating to esp8266 2.3.0 using the boards manager, I was successfully able to get the PubSubClient library using TLS 1.2 to connect, publish and subscribe to Watson IoT. I am now able to to successfully receive the requests I previously had not with the Adafruit_MQTT_Client. – JC_123 Oct 11 '16 at 13:18
  • @JC_123 would you mind proving the summary of how you resolved this as an Answer to the question to help others facing similar problems. It seems your device needed an update to use TLS 1.2 – ValerieLampkin Nov 03 '16 at 21:01

1 Answers1

0

The Arduino ESP8266 2.3.0 core provided TLS v1.2 support. Simply upgrade to this core using the boards manager in the Arduino IDE.

JC_123
  • 1