Skip to content

MQTT Demystified: Inside the "Post Office" of the IoT World

MQTT is the de facto IoT messaging protocol, designed in 1999 for low-bandwidth, unreliable networks like oil-pipeline monitoring. Unlike HTTP’s request/response model, it uses a lightweight publish/subscribe architecture where devices connect to a central broker, enabling efficient cloud-to-device push without public IPs. Key mechanisms include three QoS levels (at most once, at least once, exactly once), retained messages for late subscribers, Last Will for abnormal disconnects, keep-alive heartbeats, and clean sessions. MQTT 5.0 adds reason codes, shared subscriptions, message expiry, and topic aliases. Compared with HTTP, CoAP, and WebSocket, MQTT offers minimal overhead, flexible reliability, and strong suitability for massive device fleets, low-power sensors, smart homes, industrial IoT, and connected vehicles. The article also provides a runnable Python example using public brokers, helping readers implement their first MQTT publish/subscribe cycle quickly. Readers gain both conceptual understanding and practical starter knowledge.

Published on 2026-07-23

Open-Source Three-Phase Energy Meter: Simplifying Home Electricity Monitoring

An open-source three-phase power meter for home energy monitoring uses three PZEM-004T modules with an ESP32-C3 running ESPHome, uploading voltage, current, power, power factor, and energy data to HomeAssistant over Wi-Fi. It measures 80–260V per phase, up to 100A, with 0.5% accuracy. Design files, firmware, and enclosure models are provided.

Published on 2025-02-15

Open-Source Smart Electronic Load Based on CH32V307, Embedded Competition Project Open Source

An open-source smart electronic load based on the CH32V307VCT6 microcontroller is presented, developed as a national second-prize entry in the 2023 embedded design competition. It supports constant current, voltage, resistance, and power modes, with 100V/10A/200W ratings. Schematics, PCB files, source code, and reports are freely available for learning and reference.

Published on 2025-02-06

STM32F407-Based LVGL Project Template for MSP3526 Screen (FreeRTOS and Bare Metal Editions)

Article presents porting LVGL to STM32F407 with a 3.5-inch MSP3526 LCD (ST7796, FT6336U) using SPI+DMA, providing FreeRTOS and bare-metal project versions. It covers wiring, performance figures (~9 FPS full-screen, >30 FPS partial after overclocking), code examples, and download resources, helping readers implement embedded GUI displays effectively.

Published on 2024-11-12

STM32 based OLED screen driver with software or hardware I2C support (HAL library)

This article presents a complete STM32G474 HAL library driver for 0.96-inch SSD1306 OLED displays with 4-pin I2C interface, supporting both hardware and software I2C via simple macro configuration. It enables displaying English, integers, floating-point numbers, Chinese characters, images, binary and hex values, plus drawing points, lines, rectangles, circles, ellipses, and triangles with multiple fonts. Step-by-step STM32CubeMX setup instructions for both I2C modes are included, making integration straightforward.

Published on 2024-11-12

Synchronous Rectification Buck-Boost Digital Power Supply Based on STM32

This article presents an open-source four-switch Buck-Boost digital power supply based on STM32G474, supporting Type-C PD and DC input up to 48V10A and 450W. It includes schematic, PCB, firmware, and 3D model files. The design offers adjustable output, OLED display, protections, and host monitoring, achieving up to 94.3% efficiency and low ripple. Users can access calculations and source code.

Published on 2024-11-12