-
Notifications
You must be signed in to change notification settings - Fork 466
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
CHAD-12653 Zigbee ColorTemperature: add dynamic range handling #1248
base: main
Are you sure you want to change the base?
Conversation
Invitation URL: |
Test Results 56 files 360 suites 0s ⏱️ Results for commit 887a07a. ♻️ This comment has been updated with latest results. |
Minimum allowed coverage is Generated by 🐒 cobertura-action against 887a07a |
function () | ||
test.socket.zigbee:__queue_receive({ | ||
mock_device.id, | ||
ColorControl.attributes.ColorTempPhysicalMinMireds:build_test_attr_report(mock_device, 555) -- ~1800 K |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe these are flipped, so a good test value for ColorTempPhysicalMinMireds
is 154 which is roughly 6500K and a good value for ColorTempPhysicalMaxMireds
is 555 which is roughly 1800K
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i.e. the min mireds corresponds to the max kelvin and vice versa
you are absolutely right. what cursed units
if min ~= nil and max ~= nil and min < max then | ||
device:emit_event_for_endpoint(endpoint_id, capabilities.colorTemperature.colorTemperatureRange({ value = {minimum = min, maximum = max}})) | ||
device:set_field(BOUND_RECEIVED..MAX, nil) | ||
device:set_field(BOUND_RECEIVED..MAX) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
device:set_field(BOUND_RECEIVED..MAX) | |
device:set_field(BOUND_RECEIVED..MIN, nil) |
50f127e
to
affde8b
Compare
Duplicate profile check: Passed - no duplicate profiles detected. |
Uses the PhysicalMax and PhysicalMin mired values from the color control cluster to dynamically set the min/max range for zigbee bulbs in the base driver.
c562ba0
to
887a07a
Compare
Uses the PhysicalMax and PhysicalMin mired values from the color control cluster to dynamically set the min/max range for zigbee bulbs in the base driver.