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

feat(matter): new Matter Endpoint for Thermostat #10755

Open
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

SuGlider
Copy link
Collaborator

Description of Change

Adds a new Matter Endpoint for Thermostat with example.

Tests scenarios

ESP32-C6 using the provided examples

Related links

related to PR #7432

@SuGlider SuGlider added the Area: Libraries Issue is related to Library support. label Dec 18, 2024
@SuGlider SuGlider added this to the 3.1.0 milestone Dec 18, 2024
@SuGlider SuGlider self-assigned this Dec 18, 2024
Copy link
Contributor

github-actions bot commented Dec 18, 2024

Warnings
⚠️ Please consider squashing your 10 commits (simplifying branch history).

👋 Hello SuGlider, we appreciate your contribution to this project!


Click to see more instructions ...


This automated output is generated by the PR linter DangerJS, which checks if your Pull Request meets the project's requirements and helps you fix potential issues.

DangerJS is triggered with each push event to a Pull Request and modify the contents of this comment.

Please consider the following:
- Danger mainly focuses on the PR structure and formatting and can't understand the meaning behind your code or changes.
- Danger is not a substitute for human code reviews; it's still important to request a code review from your colleagues.
- Resolve all warnings (⚠️ ) before requesting a review from human reviewers - they will appreciate it.
- To manually retry these Danger checks, please navigate to the Actions tab and re-run last Danger workflow.

Review and merge process you can expect ...


We do welcome contributions in the form of bug reports, feature requests and pull requests.

1. An internal issue has been created for the PR, we assign it to the relevant engineer.
2. They review the PR and either approve it or ask you for changes or clarifications.
3. Once the GitHub PR is approved we do the final review, collect approvals from core owners and make sure all the automated tests are passing.
- At this point we may do some adjustments to the proposed change, or extend it by adding tests or documentation.
4. If the change is approved and passes the tests it is merged into the default branch.

Generated by 🚫 dangerJS against 6ec7207

Copy link
Contributor

github-actions bot commented Dec 18, 2024

Test Results

 62 files   62 suites   5m 43s ⏱️
 21 tests  21 ✅ 0 💤 0 ❌
154 runs  154 ✅ 0 💤 0 ❌

Results for commit 6ec7207.

♻️ This comment has been updated with latest results.

Copy link
Contributor

github-actions bot commented Dec 19, 2024

Memory usage test (comparing PR against master branch)

The table below shows the summary of memory usage change (decrease - increase) in bytes and percentage for each target.

MemoryFLASH [bytes]FLASH [%]RAM [bytes]RAM [%]
TargetDECINCDECINCDECINCDECINC
ESP32S30⚠️ +3080.00⚠️ +0.02000.000.00
ESP32S20⚠️ +3080.00⚠️ +0.02000.000.00
ESP32C3000.000.00000.000.00
ESP32C6000.000.00000.000.00
ESP320⚠️ +3240.00⚠️ +0.02000.000.00
Click to expand the detailed deltas report [usage change in BYTES]
TargetESP32S3ESP32S2ESP32C3ESP32C6ESP32
ExampleFLASHRAMFLASHRAMFLASHRAMFLASHRAMFLASHRAM
Matter/examples/MatterColorLight⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterCommissionTest⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterComposedLights⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterContactSensor⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterDimmableLight⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterEnhancedColorLight⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterFan⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterHumiditySensor⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterMinimum⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterOccupancySensor⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterOnIdentify⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterOnOffLight⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterOnOffPlugin⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterPressureSensor⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterSmartButon⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterTemperatureLight⚠️ +3080⚠️ +30800000⚠️ +3080
Matter/examples/MatterTemperatureSensor⚠️ +3080⚠️ +30800000⚠️ +3240
Matter/examples/MatterThermostat----------
Matter/examples/WiFiProvWithinMatter⚠️ +3080⚠️ +30800000⚠️ +3080

@SuGlider SuGlider added the Status: Review needed Issue or PR is awaiting review label Dec 19, 2024
@me-no-dev
Copy link
Member

Air Conditioners, which are in effect Thermostats also have a FAN-ONLY mode. Can this be done with Matter?

@SuGlider
Copy link
Collaborator Author

Air Conditioners, which are in effect Thermostats also have a FAN-ONLY mode. Can this be done with Matter?

The Thermostat is about temperature range and setpoint control. It could control any other endpoint through the Matter Controller or by using bindings. The same for the temperature sensor of the Thermostat, it can be an internal one or a remote one bound to this enpoint.

All necessary binding clusters are there. It depends on the Matter Controller to bind it and the Matter Accessory code to use it.

@SuGlider SuGlider requested a review from me-no-dev December 19, 2024 12:48
@SuGlider
Copy link
Collaborator Author

SuGlider commented Dec 19, 2024

Air Conditioners, which are in effect Thermostats also have a FAN-ONLY mode. Can this be done with Matter?

There is other endpoint for AC, room_air_conditioner, which has a thermostat cluster inside it.

All possible Operating modes are (including FanOnly, Dry, Sleep, EmergencyHeat and Precooling):

// Enum for SystemModeEnum
enum class SystemModeEnum : uint8_t
{
    kOff           = 0x00,
    kAuto          = 0x01,
    kCool          = 0x03,
    kHeat          = 0x04,
    kEmergencyHeat = 0x05,
    kPrecooling    = 0x06,
    kFanOnly       = 0x07,
    kDry           = 0x08,
    kSleep         = 0x09,
    // All received enum values that are not listed above will be mapped
    // to kUnknownEnumValue. This is a helper enum value that should only
    // be used by code to process how it handles receiving and unknown
    // enum value. This specific should never be transmitted.
    kUnknownEnumValue = 2,
};

@me-no-dev - please test it with HA. It may display all those options. Using Alexa, I just see the first 4.
The whole list is know part of the code 1d4e150

@me-no-dev
Copy link
Member

Both Apple and HA show only the main 4 modes. Works as expected and probably requires FAN endpoint for the others?

@SuGlider
Copy link
Collaborator Author

Both Apple and HA show only the main 4 modes. Works as expected and probably requires FAN endpoint for the others?

Matter Fan endpoint is already in place (implemented).

@SuGlider SuGlider added Status: Pending Merge Pull Request is ready to be merged and removed Status: Review needed Issue or PR is awaiting review labels Dec 19, 2024
@SuGlider SuGlider modified the milestones: 3.1.0, 3.1.1 Dec 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Libraries Issue is related to Library support. Status: Pending Merge Pull Request is ready to be merged
Projects
Status: In Review
Development

Successfully merging this pull request may close these issues.

4 participants