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

Feature Request: Double Press #124

Closed
Cesco117 opened this issue Dec 1, 2021 · 12 comments
Closed

Feature Request: Double Press #124

Cesco117 opened this issue Dec 1, 2021 · 12 comments
Assignees
Labels
enhancement New feature or request stale

Comments

@Cesco117
Copy link

Cesco117 commented Dec 1, 2021

Problem

Double press option

Solution

It's not particularly a problem, but I have a device that need 1 press to power on, but 2 presses to power off (Xiaomi projector).
It would be nice if, for the same SwitchBot, we could have 2 switches : 1st one for single press and 2nd one for double press.
It's the only thing missing for my HomeKit scene to be perfect :)
Thanks a lot !

Alternatives

No response

Additional context

No response

@Cesco117 Cesco117 added the enhancement New feature or request label Dec 1, 2021
@github-actions github-actions bot added the stale label Dec 16, 2021
@OpenWonderLabs OpenWonderLabs deleted a comment from github-actions bot Dec 16, 2021
@donavanbecker donavanbecker moved this to Todo in Homebridge Dec 26, 2021
@donavanbecker donavanbecker moved this from To Do to Feature Requests in Homebridge Dec 27, 2021
@donavanbecker
Copy link
Collaborator

I have add this option into the latest beta if you can give it a try. Currently it is for all push changes where it will push the change twice.

@donavanbecker donavanbecker moved this from Feature Requests to In Progress in Homebridge Dec 28, 2021
@donavanbecker donavanbecker added stale and removed pinned labels Jan 6, 2022
@donavanbecker donavanbecker moved this from In Progress to Done in Homebridge Jan 6, 2022
@donavanbecker
Copy link
Collaborator

I have release v1.7.0 with this included.

@Cesco117
Copy link
Author

Cesco117 commented Jan 6, 2022

Oh, thanks !

I didn’t make tests yet, but I guess that I have to put “2” into the “do you want to simulate a double press ?” ?

If I want to be able to alternate between single and double, the better is to create a switch with single press, and one with double press, right ?

and 3rd question, is it possible to set the time between the 2 press ?

thanks again for your consideration and your work !

@donavanbecker
Copy link
Collaborator

but I guess that I have to put “2” into the “do you want to simulate a double press ?” ?

That is correct.

If I want to be able to alternate between single and double, the better is to create a switch with single press, and one with double press, right ?

I want to be able to alternate between the two but wasn't able to the right code needed, I can keep trying.

and 3rd question, is it possible to set the time between the 2 press ?

This also was an issue that I was having. Let me keep trying.

@donavanbecker donavanbecker reopened this Jan 6, 2022
@donavanbecker donavanbecker moved this from Done to In Progress in Homebridge Jan 6, 2022
@github-actions github-actions bot removed the stale label Jan 6, 2022
@Cesco117
Copy link
Author

but I guess that I have to put “2” into the “do you want to simulate a double press ?” ?

That is correct.

👍

If I want to be able to alternate between single and double, the better is to create a switch with single press, and one with double press, right ?

I want to be able to alternate between the two but wasn't able to the right code needed, I can keep trying.

It will be awesome to have 2 switches, to be able to make scenes with single, and other scenes with double.

and 3rd question, is it possible to set the time between the 2 press ?

This also was an issue that I was having. Let me keep trying.

👍

Whatever you succeed to do, thanks A LOT for your effort, your replies and your work 👍

@cs-banane
Copy link

I use the v1.14.1 and the double press still doesn't work

@jeroen020
Copy link

I have an Optoma projector which requires a double press of the off button to turn it off. I don't see where I can add this in the config file or the plugin configuration?

Also I'd be very happy if you can have separate switches for on/off.

@donavanbecker
Copy link
Collaborator

Can you try the latest beta:

npm version

Click here to find out how to install Beta

@donavanbecker
Copy link
Collaborator

@alvst has implemented this in a different way with #628

@alvst
Copy link

alvst commented Dec 27, 2022

Yea, #628 should will accomplish this but you should really have a wrapper Accessory that uses a cURL to call Switchbot-Homebridge. The wrapper can maintain the power state of the accessory and, if it’s on, automatically instruct the bots to press twice times and once when off. This is similar to my use case (a thermostat). Then you can hide the Switchbot switches in the Home/within Homebridge app.

Alternatively, one could develop and add additional functionality onto of this repo that updates that allows for multiple presses in some instances (for example lights), this way you could do a double press when turning lights off. (This is probably the easiest and best path and most worth implementing.)

One problem you may have is it not being able to double press fast enough because you have to wait for the refresh interval which may be too long for the projector to instruct it to turn off. How quickly does the bot need to double press?

@github-actions
Copy link
Contributor

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@github-actions github-actions bot added the stale label Jan 26, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Feb 1, 2023

This issue has been closed as no further activity has occurred.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Feb 1, 2023
@github-project-automation github-project-automation bot moved this from In Progress to Done in Homebridge Feb 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request stale
Projects
Status: Done
Development

No branches or pull requests

5 participants