Embedded systems are nearly ubiquitous in our lives, affecting both developers and everyday users. Almost every electronic and electrical device around us relies on embedded systems, from smartwatches and phones to modern vehicles like electric cars, electric buses and rental bikes.
The widespread presence of these systems introduces a critical requirement: network communication capability. Many of these devices, integral to our daily routines, need to communicate with other devices or even cloud services to enhance our comfort and efficiency in daily tasks. Consequently, network communication capability - whether local or over the Internet has become a fundamental requirement for embedded systems solutions.
This article explores one of the most popular and scalable methods to allow embedded systems' communication over the network: MQTT. It covers from TCP sockets fundamentals to a practical example on how to communicate to an ESP32-S2 SoC using MQTT communication protocol.
MQTT OVERVIEW
A good start point is to define what MQTT is. MQTT stands for Message Queuing Telemetry Transport, and it was created by IBM in the late 90s. MQTT uses TCP/IP as a layer for transferring data, and has been designed to be a lightweight and simpleto-use network protocol, working with the publish-subscribe paradigm, as seen in the MQTT simplified diagram shown in Figure 1.
Every node in a MQTT communication (usually called MQTT client) is connected to a central MQTT server called an MQTT broker and sends and receives messages to other nodes addressed by MQTT topics. When a node publishes a message, it sends the desired payload addressed to a specific MQTT topic, and each node that subscribes to this referred MQTT topic will receive this message. In terms of communication possibilities, any MQTT client can be subscribed to N topics and publish to N topics simultaneously, making MQTT a very versatile communication protocol.
Diese Geschichte stammt aus der August 2024-Ausgabe von Circuit Cellar.
Starten Sie Ihre 7-tägige kostenlose Testversion von Magzter GOLD, um auf Tausende kuratierte Premium-Storys sowie über 8.000 Zeitschriften und Zeitungen zuzugreifen.
Bereits Abonnent ? Anmelden
Diese Geschichte stammt aus der August 2024-Ausgabe von Circuit Cellar.
Starten Sie Ihre 7-tägige kostenlose Testversion von Magzter GOLD, um auf Tausende kuratierte Premium-Storys sowie über 8.000 Zeitschriften und Zeitungen zuzugreifen.
Bereits Abonnent? Anmelden
New TI MCUs Enable Edge AI and Industry-Leading Real-Time Control to Advance Efficiency, Safety, and Sustainability
Texas Instruments (TI) introduced two new series of real-time microcontrollers that deliver advancements to help engineers achieve more intelligent and secure processing in automotive and industrial applications.
Using Amazon Alexa to Control Custom IoT Gadgets
In part two of his article, Brian describes integrating custom IoT gadgets with Amazon Echo using emulation to receive spoken alarms. In part one, he used emulation and Arduino Cloud services as a middleman.
Holiday Hangover Hardware Hacking
Having too much cheer during the holidays? In this month's article, Colin offers a diversion from the jolly season by urging developers to retreat to the basement to brush up on hardware hacking skills. He shows how a low-cost Raspberry Pi Pico and a TP-Link Tapo C200 smart IP camera could become the next automated bird deterrent or a home automation server.
Datasheet: Microamps Per Megahertz Ultra-Low Power MCUs Minimize Current Consumption
How do chip makers differentiate if many ultra-low power MCUs on the market feature the same processor core? The peripherals and different power states offer various ways to manage current consumption down to microamps per megahertz.
Smart Home Lock Down Matter Provides Security Blanket
As more devices in the smart home connect to the Internet, they become increasingly vulnerable to outside attacks. Developers can now add the latest security measures to their Smart Home devices through Matter.
Basic Pulse Circuits
In part one of a three-part series, Wolfgang wrote how basic pulse circuits help digital circuits, such as embedded boards with ARM processors, deal with pulse trains or bursts of pulses from the outside. In Part 2, he dives into enabling flip-flops, timing parameters, and synchronization, design tasks needed to capture, detect, and filter pulses.
Building a Wi-Fi Router Watchdog
Dev created a watchdog for a Wi-Fi extender using a Raspberry Pi Pico. This monitors Wi-Fi connectivity for his smart home lighting system, which would require a reset twice a year due to rapid power interruptions.
Create Your Own PCBs with a CNC Milling Machine
Using KiCad, CopperCAM, and Candle Software
Performance Bottlenecks in Embedded Linux Solutions Analysis, Identification, and Mitigation
Good performance is a requirement for every technology, and system designers rely on operating systems to ensure fast and smooth transitions in critical applications. Fortunately, Pedro writes, the embedded Linux OS offers ways for finding, analyzing and mitigating performance bottlenecks so embedded systems can deliver the speed and efficiency that end users expect.
Renesas New RA8 Entry-Line MCU Groups Brings High Performance of Arm Cortex-M85 Processor to Cost-Sensitive Applications with Market-Leading CoreMark Performance
Renesas Electronics Corp., a premier supplier of advanced semiconductor solutions, introduced the RA8E1 and RA8E2 microcontroller (MCU) groups, extending the industry's most powerful series of MCUs.