Skip to content

Add support for frient/Develco Smart Button (SBTZB-110)#4974

Open
marcintyminski wants to merge 5 commits intozigpy:devfrom
marcintyminski:smart-button
Open

Add support for frient/Develco Smart Button (SBTZB-110)#4974
marcintyminski wants to merge 5 commits intozigpy:devfrom
marcintyminski:smart-button

Conversation

@marcintyminski
Copy link
Copy Markdown
Contributor

@marcintyminski marcintyminski commented May 6, 2026

Proposed change

The quirk has been made to extend functionality of the following frient/Develco Smart Buttons:

  • frient Smart Button with model no. SBTZB-110
  • Develco Smart Button with model no. SBTZB-110

The quirk contains following changes:

  • Change the entity showing button state
  • Add setting for the duration of press for the button to take action
  • Add setting allowing to change the LED color

Additional information

After changes

Device diagnostics

zha-01KJYXWD9VV3FMNDJEFN115MC4-frient A_S SBTZB-110-1c1b8495e7c58cfb8b38f32b44383248 (4).json

Checklist

  • The changes are tested and work correctly
  • pre-commit checks pass / the code has been formatted using Black
  • Tests have been added to verify that the new code works
  • Device diagnostics data has been attached

marcintyminski and others added 2 commits May 6, 2026 10:32
Co-authored-by: Copilot <copilot@github.com>
Copilot AI review requested due to automatic review settings May 6, 2026 09:57
@codecov
Copy link
Copy Markdown

codecov Bot commented May 6, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 93.08%. Comparing base (3bfbd04) to head (12ab9bb).

Additional details and impacted files
@@           Coverage Diff           @@
##              dev    #4974   +/-   ##
=======================================
  Coverage   93.07%   93.08%           
=======================================
  Files         401      401           
  Lines       13305    13323   +18     
=======================================
+ Hits        12384    12402   +18     
  Misses        921      921           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Copy Markdown

Copilot AI left a 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 updates the Develco/frient Smart Button (SBTZB-110) v2 quirk to expose additional configuration options and adjust how button state is represented in Home Assistant.

Changes:

  • Adds a custom OnOff cluster with manufacturer-specific attributes for button configuration.
  • Exposes new HA entities for press-action delay (number) and LED color (enum), and changes button state to an enum sensor.
  • Adds a dedicated test module asserting the new v2 entity metadata and cluster/enum definitions.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.

File Description
zhaquirks/develco/smart_button.py Adds a custom cluster and new v2 entity definitions for button configuration/state, and expands matching to Develco manufacturer string.
tests/test_develco_smart_button.py Adds tests for the new quirk’s v2 entity metadata and basic enum/cluster metadata.

Comment on lines 51 to +59
(
QuirkBuilder("frient A/S", "SBTZB-110")
.applies_to("Develco Products A/S", "SBTZB-110")
.replaces(CustomOnOff, endpoint_id=32, cluster_type=ClusterType.Client)
.prevent_default_entity_creation(
endpoint_id=32,
cluster_id=OnOff.cluster_id,
function=lambda entity: entity.device_class == "opening",
)
Comment thread zhaquirks/develco/smart_button.py Outdated
class CustomOnOff(CustomCluster, OnOff):
"""Custom OnOff cluster to prevent entity creation."""

cluster_id = 0x0006
Comment thread zhaquirks/develco/smart_button.py Outdated
Comment on lines +28 to +41
button_press_blink_led: Final = ZCLAttributeDef(
id=0x8002,
type=t.enum8,
access="rw",
manufacturer_code=0x1015,
)

class LedColors(t.enum8):
"""LED color options."""

OFF = 0
RED = 1
GREEN = 2
YELLOW = 3
Comment on lines +37 to +40
assert ("frient A/S", "SBTZB-110") in {
(metadata.manufacturer, metadata.model)
for metadata in quirk.manufacturer_model_metadata
}
marcintyminski and others added 2 commits May 6, 2026 14:29
Co-authored-by: Copilot <copilot@github.com>
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.

2 participants