Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add temperature-measurement.zap file to temperature-measurement-app #3882

Merged
merged 1 commit into from
Nov 24, 2020

Conversation

vivien-apple
Copy link
Contributor

Problem

This PR contains the .zap configuration that maps the the current configuration of the gen/ folder fore the temperature-measurement-app demo.

This is similar to #3610. Reviewers may notice that there is no absolute path anymore.

For example, one may generate the content of gen/ folder running:

./scripts/tools/zap_generate.sh examples/temperature-measurement-app/esp32/main/temperature-measurement.zap

At some point, we will get rid of the code of the gen/ folder. And the code should be generated from this file.

Summary of Changes

  • Add temperature-measurement-app.zap into examples/temperature-measurement-app/esp32/main

"package": [
{
"pathRelativity": "relativeToZap",
"path": "../../../../../third_party/zap/repo/zcl-builtin/silabs/zcl.json",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

when will these become parameters to compilation?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think those paths really matters when you are just generating the file fwiw. I have used files with hardcoded path to @jepenven-silabs hard drive and it was working.

The issue was while I was trying to edit the file and then save it. It was complaining about the path in this case.

"deviceTypeName": "CBA-tempsensor",
"deviceTypeCode": "0x0302",
"deviceTypeProfileId": "0x105",
"clusters": [
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm. This has Basic client and Basic server on the same endpoint. Is that expected?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's because the file format is misleading and contains a lot of noises sadly.

In fact all the clusters you have mentioned appears in this configuration file because there are part of the default set of clusters for a regular "CBA-tempsensor".

But in this particular configuration file, most clusters are not enabled. There is a json field named "enabled" that controls if a particular cluster is enabled by setting it to 1 or 0.

The only clusters that are enabled for this configuration file are the one that are used in the current temperature-measurement-app:

  • Basic Cluster Server
  • Temperature Measurement Server

@andy31415 andy31415 merged commit ddac4b1 into project-chip:master Nov 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants