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

Matter 1.3 Driver Release #1640

Merged
merged 10 commits into from
Sep 27, 2024
Merged

Matter 1.3 Driver Release #1640

merged 10 commits into from
Sep 27, 2024

Conversation

hcarter-775
Copy link
Contributor

@hcarter-775 hcarter-775 commented Sep 17, 2024

Check all that apply

Type of Change

  • WWST Certification Request
    • If this is your first time contributing code:
      • I have reviewed the README.md file
      • I have reviewed the CODE_OF_CONDUCT.md file
      • I have signed the CLA
    • I plan on entering a WWST Certification Request or have entered a request through the WWST Certification console at developer.smartthings.com
  • Bug fix
  • New feature
  • Refactor

Checklist

  • I have performed a self-review of my code
  • I have commented my code in hard-to-understand areas
  • I have verified my changes by testing with a device or have communicated a plan for testing
  • I am adding new behavior, such as adding a sub-driver, and have added and run new unit tests to cover the new behavior

Description of Change

New Device Types Included:

Water Valve
Rain Sensor
Leak Detector
Freeze Detector
Water Valve
Electrical Sensor
EVSE
Laundry Dryer
Extractor Hood
Microwave Oven
Oven
Cooktop

Also includes:
Embedded Matter 1.3 clusters, cluster utils
Updated .luacov file (CI support)
Small updates to Refrigerator, Dishwasher drivers
Small updates to resolve changes since this PR's creation
See Completed Testing and Updates of Non-driver specific work here:
https://smartthings.atlassian.net/wiki/spaces/CHIP/pages/3434446937/Matter+1.3+Release+Preparations

Summary of Completed Tests

Sorry, something went wrong.

Copy link

github-actions bot commented Sep 17, 2024

Duplicate profile check: Warning - duplicate profiles detected.
plug-power-energy-powerConsumption.yml == power-energy-powerConsumption.yml

Copy link

github-actions bot commented Sep 17, 2024

Test Results

   63 files    395 suites   0s ⏱️
1 932 tests 1 932 ✅ 0 💤 0 ❌
3 356 runs  3 356 ✅ 0 💤 0 ❌

Results for commit f125ceb.

♻️ This comment has been updated with latest results.

Copy link

github-actions bot commented Sep 17, 2024

matter-appliance_coverage.xml

File Coverage
All files 63%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-dishwasher/init.lua 29%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-microwave-oven/init.lua 82%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-oven/init.lua 84%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-refrigerator/init.lua 26%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-laundry/init.lua 63%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-cook-top/init.lua 85%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/init.lua 68%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-extractor-hood/init.lua 98%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/embedded-cluster-utils.lua 45%

matter-evse_coverage.xml

File Coverage
All files 79%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-dishwasher/init.lua 29%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-microwave-oven/init.lua 82%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-oven/init.lua 84%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-refrigerator/init.lua 26%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-laundry/init.lua 63%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-cook-top/init.lua 85%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/init.lua 68%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-extractor-hood/init.lua 98%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/embedded-cluster-utils.lua 45%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-evse/src/embedded_cluster_utils.lua 78%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-evse/src/init.lua 79%

matter-sensor_coverage.xml

File Coverage
All files 87%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-dishwasher/init.lua 29%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-microwave-oven/init.lua 82%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-oven/init.lua 84%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-refrigerator/init.lua 26%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-laundry/init.lua 63%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-cook-top/init.lua 85%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/init.lua 68%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-extractor-hood/init.lua 98%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/embedded-cluster-utils.lua 45%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-evse/src/embedded_cluster_utils.lua 78%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-evse/src/init.lua 79%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-sensor/src/init.lua 92%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-sensor/src/embedded-cluster-utils.lua 42%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-sensor/src/air-quality-sensor/init.lua 91%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-sensor/src/smoke-co-alarm/init.lua 83%

matter-switch_coverage.xml

File Coverage
All files 93%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-dishwasher/init.lua 29%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-microwave-oven/init.lua 82%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-oven/init.lua 84%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-refrigerator/init.lua 26%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-laundry/init.lua 63%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-cook-top/init.lua 85%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/init.lua 68%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-extractor-hood/init.lua 98%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/embedded-cluster-utils.lua 45%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-evse/src/embedded_cluster_utils.lua 78%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-evse/src/init.lua 79%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-sensor/src/init.lua 92%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-sensor/src/embedded-cluster-utils.lua 42%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-sensor/src/air-quality-sensor/init.lua 91%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-sensor/src/smoke-co-alarm/init.lua 83%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-switch/src/init.lua 96%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-switch/src/embedded-cluster-utils.lua 38%
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-switch/src/eve-energy/init.lua 91%

Minimum allowed coverage is 90%

Generated by 🐒 cobertura-action against f125ceb

@hcarter-775 hcarter-775 mentioned this pull request Sep 17, 2024
12 tasks
Copy link

github-actions bot commented Sep 18, 2024

Channel deleted.

@ctowns
Copy link
Contributor

ctowns commented Sep 18, 2024

@nickolas-deboom can we get the unit test coverage for extractor-hood above 90%?

/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-extractor-hood/init.lua 76%

@hcarter-775
Copy link
Contributor Author

@nickolas-deboom in your latest commit, you removed the setting of the CURRENT_CONFIGURED_UNIT field. Was this purposeful?

@nickolas-deboom
Copy link
Contributor

After some discussion with the team, we realized that the logic in matter-oven to emit the capabilities with degF would allow the proper temperature units to display for hubs that are on firmware lower than 54. I added it back, with a check for the RPC version. Note that RPC >= 5 corresponds to hubcore FW >= 54. Sorry for the confusion.

Copy link
Contributor

@samadDotDev samadDotDev left a comment

Choose a reason for hiding this comment

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

Great work @hcarter-775, @ctowns, @nickolas-deboom and @HunsupJung!

Since the commit history is being squashed (+building upon original PR) and this is a multi-member effort, let's attribute the authors (Cooper, Nick, Hunsup and any others who I'm missing) appropriately in the final commit

https://docs.github.com/en/pull-requests/committing-changes-to-your-project/creating-and-editing-commits/creating-a-commit-with-multiple-authors

Copy link
Contributor

@ctowns ctowns left a comment

Choose a reason for hiding this comment

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

This may not be needed for MVP, but each of the matter appliance drivers should be updated to use a version of the find_default_endpoint() function rather than using the MATTER_DEFAULT_ENDPOINT value for all the endpoint defaults. The return value from the find_default_endpoints() function should return the the first endpoint that supports one of the device type's mandatory clusters. This is important for cases where the device is bridged and the default endpoint is not 1.

You can see an example in the matter-thermostat driver here:

local function find_default_endpoint(device, cluster)

cc: @HunsupJung

Copy link
Contributor

@ctowns ctowns left a comment

Choose a reason for hiding this comment

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

I left some comments but I do not think they are anything that should block moving forward with the beta release next week. Consider this my approval pending resolution of the following item:

There is still a pending discussion around handling the temperatureSetpoint that needs to be resolved that could impact how we move forward with the appliance drivers that support this capability.

@nickolas-deboom
Copy link
Contributor

nickolas-deboom commented Sep 27, 2024

I left some comments but I do not think they are anything that should block moving forward with the beta release next week. Consider this my approval pending resolution of the following item:

There is still a pending discussion around handling the temperatureSetpoint that needs to be resolved that could impact how we move forward with the appliance drivers that support this capability.

As discussed, we decided to only emit the temperatureSetpointRange capability for hubs on FW >= 54 (see d2d8e85). Hubs on 53 will still be able to make use of the temperatureSetpoint capability (not temperatureSetpointRange), because we plan to enable the scripting_engine.capabilities_to_convert_temp LD flag with temperatureSetpoint in its value field to enable conversion for this capability. These changes were tested on both firmware versions. On FW 54, the temperatureSetpoint and temperatureSetpointRange capabilities both function as expected. On FW 53, temperatureSetpoint functions as expected. The temperature range allowed in the plugin is larger than what any real device would support, but the driver still enforces the range supported by the device. This means that the setpoint cannot be set outside of what the device supports, even if the temperatureSetpointRange capability is not emitted.

hcarter-775 and others added 10 commits September 27, 2024 17:09
Signed-off-by: Hunsup Jung <[email protected]>
Signed-off-by: Hunsup Jung <[email protected]>
handling

* The setpoint range capability is gated on the RPC version to ensure
  that it is only emitted for hubs on firmware 54 or above. Temperature
  conversion is not supported for lower firmware versions.

* Remove degF handling.
@hcarter-775 hcarter-775 merged commit 7821a5d into main Sep 27, 2024
15 checks passed
@hcarter-775 hcarter-775 deleted the matter-v1.3-release branch September 27, 2024 22:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants