Curtain gen2 add new private clusters #4482
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Proposed change
This PR added added 2 additional private clusters
1.total_cycle_times: The large curtain descends from the top tightening point to the bottom, and then rises to the top tightening point in a loop. The total number of cycles is how many times this behavior can be cycled, and the battery will run out of power. The maximum power failure of 81 inch curtains after 220 cycles is 210 times, so this attribute value defaults to 210 times.
2.last_remaining_battery_percentage: The percentage of battery remaining from the last time the curtain was powered on until the power was cut off. Calculated based on the distance traveled by the curtains and the maximum distance they can travel.
Additional information
Device diagnostics
Checklist
pre-commitchecks pass / the code has been formatted using Black