Exploring Custom Cluster Implementation in Matter

I’ve been diving into the world of Matter and custom cluster development, and it’s been quite the journey! While the documentation provides a solid foundation, I’ve encountered a few bumps along the way that I’d love to share and get some insights on from the community.

First off, I followed the official guide to create a custom cluster, but ran into an issue with the zap-gui tool. The --clusters parameter simply didn’t exist as mentioned, which was a bit perplexing. After some troubleshooting, I realized that manually adding the XML file to the ZAP GUI was the way to go, but even then, device types became unavailable. It was like the GUI lost all its options, which was definitely not the intended behavior.

I also explored Google’s documentation, only to find that parts of it were outdated. For instance, the all.xml file referenced in their guide no longer exists at the specified path. This made me question whether I was following the correct approach or if there was a newer, more efficient method I wasn’t aware of.

To add to the challenge, the Matter documentation, while comprehensive, lacks specific implementation details. It’s great for understanding the big picture but leaves room for confusion when diving into the nitty-gritty of code generation and cluster integration.

So, here’s what I’m curious about:

  1. Best Practices for Custom Cluster Creation: What’s the most reliable method to create and integrate a custom cluster in Matter today? Are there any updated tutorials or guides that the community recommends?
  2. ZAP GUI Workflows: Is there a known issue with the zap-gui tool regarding cluster inclusion? And if so, are there any workarounds or alternative approaches to achieve the desired outcome?
  3. Code Generation Challenges: For those unfamiliar with the Matter codegen process, what are the common pitfalls, and how can they be avoided? Are there any resources or community-shared examples that could serve as a starting point?

I’m really excited about the potential of custom clusters in Matter, especially for niche use cases that aren’t covered by existing standards. But navigating the implementation process has been a bit of a hurdle. I’d love to hear from others who’ve tackled similar projects—what worked for you, and what lessons did you learn along the way?

Let’s keep the conversation going and help each other overcome these challenges! :rocket: