Lesson 4 – Reading buttons and controlling LEDs over MQTT

Overview

In the layer above transport protocols, there are many different application protocols provided by the nRF Connect SDK to use for cellular communication in your application. In this lesson, we will cover the TCP-based protocol, MQTT. We will explain the principles of MQTT communication and how the MQTT Library in the nRF Connect SDK is used. We will also learn how to use MQTT over TLS to provide a secure end-to-end connection to another client.

In the exercises section, you will practice how to use the MQTT protocol and library to connect to an MQTT broker and send data back and forth to another MQTT client to remotely control the LEDs and monitor the status of buttons on your board.

Objectives

  • Understand the basics of the MQTT protocol and learn how to use the MQTT library in nRF Connect SDK.
  • Practice through hands-on exercises how to utilize MQTT in an application to establish a bidirectional communication. channel with another MQTT client.
  • Practice how to use TLS to create a secure connection between your device and the other end.
Register an account
Already have an account? Log in
(All fields are required unless specified optional)

Forgot your password?
Enter your email address, and we will send a link to reset your password.