-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
[shelly] Enhance support for Plus RGBW and add Pro RGBW #19227
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
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Markus Michels <markus7017@gmail.com>
Signed-off-by: Markus Michels <markus7017@gmail.com>
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.
Pull Request Overview
This PR enhances support for Shelly Plus RGBW devices and adds support for the new Shelly Pro RGBW PM device. The changes improve device compatibility and provide better channel control for RGBW lighting devices.
Key changes include:
- Added new Shelly Pro RGBW PM device support with proper thing type definitions
- Enhanced existing Shelly Plus RGBW PM configuration with additional channel groups
- Refactored light status handling to extract reusable components for better maintainability
Reviewed Changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 4 comments.
Show a summary per file
File | Description |
---|---|
ShellyThingCreatorTest.java | Added test cases for new Pro RGBW PM device type |
shellyGen2_lights.xml | Enhanced Plus RGBW PM configuration and added Pro RGBW PM thing type definition |
shelly.properties | Updated device descriptions for Plus RGBW PM |
ShellyLightHandler.java | Refactored light update logic to use extracted component method |
ShellyComponents.java | Added reusable updateLights method extracted from handler |
Shelly2ApiRpc.java | Enhanced light status handling for multiple light channels |
Shelly2ApiJsonDTO.java | Extended data structures to support additional light configuration options |
Shelly2ApiClient.java | Added light settings and status handling for new device types |
ShellyDevices.java | Added device type constants and mappings for Pro RGBW PM |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Arguments.of("shellyprorgbw-" + DEVICE_ID, "", "", THING_TYPE_SHELLYPRORGBWPM); | ||
return Stream.of( // |
Copilot
AI
Aug 30, 2025
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.
This Arguments.of() call is not inside the Stream.of() method call. It should be moved inside the Stream.of() on line 75 to be included in the test cases.
Arguments.of("shellyprorgbw-" + DEVICE_ID, "", "", THING_TYPE_SHELLYPRORGBWPM); | |
return Stream.of( // | |
return Stream.of( // | |
Arguments.of("shellyprorgbw-" + DEVICE_ID, "", "", THING_TYPE_SHELLYPRORGBWPM), // |
Copilot uses AI. Check for mistakes.
<label>@text/channel-group-type.shelly.rgbw2Channel4.label</label> | ||
</channel-group> | ||
<channel-group id="channel5" typeId="rgbw2Channel"> | ||
<label>@text/channel-group-type.shelly.rgbw2Channel4.label</label> |
Copilot
AI
Aug 30, 2025
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.
Channel 5 is incorrectly labeled with channel 4's label. This should reference channel 5: @text/channel-group-type.shelly.rgbw2Channel5.label
<label>@text/channel-group-type.shelly.rgbw2Channel4.label</label> | |
<label>@text/channel-group-type.shelly.rgbw2Channel5.label</label> |
Copilot uses AI. Check for mistakes.
<label>@text/channel-group-type.shelly.iXChannel4.label</label> | ||
</channel-group> | ||
<channel-group id="status5" typeId="ixChannel"> | ||
<label>@text/channel-group-type.shelly.iXChannel4.label</label> |
Copilot
AI
Aug 30, 2025
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.
Status channel 5 is incorrectly labeled with channel 4's label. This should reference channel 5: @text/channel-group-type.shelly.iXChannel5.label
<label>@text/channel-group-type.shelly.iXChannel4.label</label> | |
<label>@text/channel-group-type.shelly.iXChannel5.label</label> |
Copilot uses AI. Check for mistakes.
<label>@text/channel-group-type.shelly.meter4.label</label> | ||
</channel-group> | ||
<channel-group id="meter5" typeId="meter"> | ||
<label>@text/channel-group-type.shelly.meter4.label</label> |
Copilot
AI
Aug 30, 2025
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.
Meter channel 5 is incorrectly labeled with meter 4's label. This should reference meter 5: @text/channel-group-type.shelly.meter5.label
<label>@text/channel-group-type.shelly.meter4.label</label> | |
<label>@text/channel-group-type.shelly.meter5.label</label> |
Copilot uses AI. Check for mistakes.
Enhance support for Shelly Plus RGBW
Add Shelly Pro RGBW
Closes #19216