What do you need for personal smart home based on the Matter network?

As technology advances, smart homes have become an integral part of our lives. Among all the smart home solutions, those based on the Matter network are gaining popularity due to their openness, interoperability, and security. So, what do we need to set up a Matter-based smart home system?


When it comes to creating a Matter system in your home, the process generally includes the following steps:

Step 1: Analyze your system requirements.

Step 2: Design the network topology.

Step 3: Choose the right devices.

Step 4: Install and configure your devices.

Step 5: Design and deploy the application services.


System requirements analysis

When designing a home smart system, we should meticulously plan the following aspects to ensure the system's functionality:


1. Functional Requirements:

· Garden Management: The system should be capable of monitoring soil moisture levels and have intelligent features for automatic and scheduled watering to ensure that plants are well cared for.

· Appliance Monitoring: Monitor household electricity usage in real-time, offer detailed electricity usage statistics, and alert for unusual consumption to promote rational energy use.

· Front Door Security: Ensure family safety by monitoring the front door area in real-time, supporting video recording and playback, and providing remote notifications in case of anomalies.

· Indoor Comfort: Create a comfortable living environment by integrating control of indoor lighting, air conditioning, water heaters, and curtains through a smart central system.

· Pet Care: Includes smart feeders and self-cleaning litter boxes to ensure pets are well taken care of even in the owner's absence.


2. User Interface Requirements:

· Intuitive Operation: Provide a modularly designed user interface that allows for easy setup and management of devices.

· Cross-Platform Experience: Whether it's iOS, Android, or the Web platform, users should have a consistent and efficient experience.

· Timely Feedback: Ensure the user interface promptly displays updates to device status, keeping users well-informed about changes at home.


3. Scalability Requirements:

· Smart Scenarios: Allow users to set automation scenarios based on personal habits, such as 'Away Mode' or 'Night Mode', to enhance the interactivity and personalization of the smart home.

· Voice Interaction: Integrate mainstream voice assistants like Amazon Alexa, Google Assistant, or Apple Siri to achieve seamless voice control.

· Open APIs: Provide open API interfaces to encourage and support third-party developers to bring more innovation and services to the system.

· Cloud Service Integration: Extend system functions through cloud services, offering data backup, remote access, and advanced analytics.


4. Security and Privacy Requirements:

· Data Encryption: Use end-to-end encryption to ensure secure communication between all devices and protect user data from being leaked.

· Privacy Protection: Implement strict data protection policies to ensure the privacy and personal information of users is fully respected and protected.

· Timely Updates: The system should automatically check and install the latest security patches to prevent and fix potential security vulnerabilities.


5. Reliability and Stability Requirements:

· Backup Mechanisms: Build failover mechanisms to maintain basic operations in the event of critical component failures.

· Outstanding Performance: Optimize system performance to reduce response times, ensuring the smoothness and timeliness of user operations.

· Continuous Monitoring: Conduct comprehensive system monitoring to promptly identify and resolve performance bottlenecks or system failures, ensuring long-term stable operation of the system.


Network topology design



Device selection

Node Selection

Various manufacturers have launched many mature products that support the Matter protocol. I've noticed that many existing smart home products can be upgraded to support Matter through software updates. We need to pay attention to the technical specifications of the products because the way to connect to the Matter network differs for IP/WiFi, Zigbee/BLE, and Thread devices.


1. IP/WiFi End

For Matter devices that support the IP/WiFi connection protocol, we can simply use a mobile app to scan the QR code on the device's packaging to add it to the Matter smart home network.


(From Google Next Hub Max's Connectivity Protocol)


(From YouTuber: Smart Home Solver)


2. Zigbee, BLE, Thread End

If you need to use Thread, Zigbee, or Bluetooth devices, you must purchase the corresponding Thread border routers and Zigbee/BLE bridges. In the Matter ecosystem, Zigbee/BLE devices can act as "bridged device" nodes, completing the mapping between Zigbee/BLE and the Matter protocol through Zigbee/BLE bridges, thereby communicating with other Matter devices in the system.


(Diagram of Zigbee and Matter communication from Espressif)


In addition to acting as protocol "translators" , Zigbee/BLE bridging devices can also have native Matter functions. For example, a smart thermostat device can serve as a bridge to facilitate communication between Zigbee/BLE and the Matter ecosystem, and it can also act as a standard Matter smart thermostat device, sending control commands to the HVAC system via the Matter protocol. 


Thread is a low-power mesh network protocol based on IPv6, commonly used in IoT products. The Thread protocol is based on IEEE 802.15.4 technology, so devices in a Thread network cannot communicate directly with Wi-Fi or Ethernet devices. The Thread border router is responsible for forwarding IP frames between Wi-Fi and Thread networks.


(Diagram of Thread and Matter communication from Espressif)


3. Board 

Hardware such as ESP32 and Raspberry Pi can also be integrated into the Matter network. ESP32, developed by Espressif Systems, is a low-power microcontroller with built-in Bluetooth and WiFi, and it has GPIOs for connecting and controlling various peripherals. Once integrated with the Matter protocol, the ESP32 can become a node in the smart home network, communicating with other Matter protocol-supported devices to achieve interoperability. This means that ESP32-based devices can be used to build and expand our smart home system. As shown below, ESP32 series products can serve as Wi-Fi end devices, Thread end devices, Thread border routers, and Matter bridges for Zigbee device Matter connectivity. For specific deployment steps, please refer to the project references provided at the end of the article.


(From Espressif)


Matter Applications

We can control and manage devices through Matter applications, with popular mobile apps including Google Home and Apple Home. By scanning the QR code on the product packaging with an app, you can integrate devices into your smart home system effortlessly.



Matter Cloud Platform

Home Assistant

Home Assistant acts as a "controller" within the Matter ecosystem, meaning it can control devices based on Matter. Other examples of Matter controllers include Google Nest products, Apple HomePod speakers, Samsung SmartThings Station, and some of the newer Amazon Echo devices. The Matter protocol enables various smart devices to communicate with each other, while Home Assistant is a platform that integrates and manages these devices. It offers device management, data storage, remote control, and more. For advanced hobbyists, Home Assistant can be deployed on hardware such as NAS, soft routers, and Raspberry Pi to directly control and manage devices supporting the Matter protocol, creating a more secure and private smart home control system.




Optional Hardware Needed:

1 LattePanda
1 Raspberry Pi 4B
1 NAS (Network Attached Storage)


ESP RainMaker

ESP RainMaker is a comprehensive AIoT platform that allows for the rapid development of AIoT products, building secure, stable, and customizable AIoT solutions. It bridges the gap from underlying chips to upper-layer software applications, encompassing all Espressif chips and modules, device firmware, integration with third-party voice assistants, mobile apps, and cloud services.


(From Espressif)


Device installation and configuration

Using Home Assistant as an example, let's go through the system configuration steps:

1. Home Assistant Cloud Platform Installation

There are several methods to install Home Assistant, as provided in the official documentation:

· Direct installation on hardware devices;

· Installation via container platforms like Docker;

· Manual installation on traditional Linux distributions;

· Installation within a Python virtual environment.


Each of these approaches has its pros and cons. The first method is more suitable for Raspberry Pi, while the second is better for NAS (or routers that support Docker and have robust performance). The former allows for direct installation on Raspberry Pi by flashing an SD card, while the latter can be installed directly through a NAS's Docker manager or via a virtual machine. Both are ready to use upon installation, saving time on environment setup and avoiding most errors. Note that running Matter on Home Assistant Core installations is currently not supported.


For the Raspberry Pi, you'll need a Raspberry Pi 3B or 4, a card reader, and an Ethernet cable. Home Assistant requires decent device performance, so it's advisable to opt for a higher-spec Raspberry Pi 4, paired with a high-speed SD card of 16GB or more for system storage, to ensure smoother operations. Next, download the corresponding image from the Home Assistant OS's GitHub release page and flash it onto the SD card using balenaEtcher on your computer.


For the NAS, if you're running Home Assistant on a NAS, you can run a Matter server's Docker image. The requirements and instructions for the host setup are described on the GitHub page. You could also use a Lattepanda as a NAS + Home Assistant platform, as it has additional SSD interfaces for installing hard drives.


2. Add the Matter (BETA) integration to the Home Assistant

· Browse to the Home Assistant instance.

· Go to Settings > Devices & Services.

· In the bottom right corner, select the Add Integration button.

· From the list, select Matter (BETA).

· Follow the instructions on the screen to complete the setup.


3. Add a device using the ios companion app

This will use the Bluetooth connection of the phone to add the device.

· Open The Home Assistant app on the phone.

· Go to Settings > Devices & Services.

· On the Devices tab, press the Add Device button.

· Choose Add Matter device at the top of the list.

· Scan the QR code of the Matter device with the phone camera or press More options… to manually enter the Commission code.

· Select the Add to Home Assistant button which will start the commissioning process which may take up to a few minutes.

· If you’re adding a test board or beta device, you might get a prompt about an “Uncertified Accessory”. In this dialog, select Add Anyway.

· Once prompted, you can enter a custom Accessory Name, this is just an internal reference and not visible in Home Assistant. You can type whatever you like here.

· Once the process is complete and you press the Done button, you are redirected to the device within Home Assistant. It is ready for use.


4. Share a device from Apple home

Find the device in Apple Home and press the jog wheel to edit it. On the page with detailed descriptions and settings for the device, scroll all the way down and press the button Turn On Pairing Mode.

You are now given a Setup code, copy this to the clipboard.

Follow the Add a device using the iOS Companion app directions above to add the device to Home Assistant where you paste the code you just received from Apple Home.


5. Experiment with Matter using an ESP32 dev board

We have prepared a page for you where you can easily flash Matter firmware to a supported ESP32 development board. We recommend the M5 Stamp C3 device running the Lighting app.

· Make sure you use Google Chrome or Microsoft Edge browser.

· Open https://nabucasa.github.io/matter-example-apps/

· Attach the ESP32 device using a USB cable.

· Select the radio button next to the example you like to set up, in case of an M5 Stamp, click Lighting app for M5STAMP C3.

· Select Connect.

· In the popup dialog that appears, choose the correct serial device. This will usually be something like “cu-usbserial” or alike.

· Click Install Matter Lighting app example and let it install the firmware on the device. This will take a few minutes.

· Once the device is flashed with the Matter firmware, connect to the device again but this time choose Logs & console.

· You are presented with a console interface where you see live logging of events. This is an interactive shell where you can type commands. For a list of all commands, type matter help and press enter.

· To add the device, we need the QR code. In the console, type in matter onboardingcodes ble and copy/paste the URL into your browser.

· Use the QR code to add the device using one of the above instructions on your phone, e.g. using the Home Assistant Companion app.


Application service design and deployment

After setting up the server, installing, and configuring nodes and gateways, we can design the application logic based on actual needs, develop application functions, including developing user interfaces, configuring alarms or trigger rules, integrating with other systems, and more. Finally, we deploy the application services to the server to complete the entire system setup.


This article mainly introduces the selection of personal smart home systems based on the Matter network. Next, we will start by connecting the basic node ESP32 to the Matter network and gradually complete the deployment of the system. For details, please view the series of articles: How to Connect ESP32-C6 to the Matter Network: https://community.dfrobot.com/makelog-313735.html


In the future, as more devices start to support the Matter protocol, we have reason to believe that smart home systems based on the Matter network will become increasingly prevalent. They are set to become a part of our lives, making our lives smarter and more convenient.



- Photo credit for Home Assistant goes to r/home.assistant

All Rights