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

Dimming sensor #99

Merged
merged 8 commits into from
Nov 8, 2024
Merged

Dimming sensor #99

merged 8 commits into from
Nov 8, 2024

Conversation

derjoerg
Copy link
Collaborator

@derjoerg derjoerg commented Nov 8, 2024

Add device support for DimmingSensor

closes #92

kingsleyadam
kingsleyadam previously approved these changes Nov 8, 2024
Comment on lines 62 to 64
if output.get("pairingID") == Pairing.AL_RELATIVE_SET_VALUE_CONTROL.value:
self._longpress = output.get("value") == "9" or output.get("value") == "8"
return True
Copy link
Owner

Choose a reason for hiding this comment

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

Would it be useful to have a long press up and a long press down?

If this is the possible values.

  • longpress down: 1
  • longpress down release: 0
  • longpress up: 9
  • longpress up release: 8

You could have a state with an enum with the 4 possible options. In Home Assistant they'd appear as one of the 4 options. That way a user can create automations based on one of the 4 options.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Let me try it

@kingsleyadam kingsleyadam added enhancement New feature or request Semver-Minor New Features labels Nov 8, 2024
@kingsleyadam kingsleyadam merged commit d2d6529 into kingsleyadam:main Nov 8, 2024
2 checks passed
@derjoerg derjoerg deleted the DimmingSensor branch November 8, 2024 15:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Semver-Minor New Features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement new device - DimmingSensor
2 participants