senorshaun / homebridge-radiora2

Lutron RadioRA2 plugin for homebridge
MIT License
10 stars 5 forks source link

Pico / Shades #17

Closed jfinestone closed 1 year ago

jfinestone commented 2 years ago

Hello.

Are PICO remote supported? It looks like someone developed a plug-in, but only for Caseta Pro https://github.com/rnilssoncx/homebridge-pico

would be great if we could have similar functionality, or at least capture a single button press of a PICO.

The PICO have some significant limitations when you try to build functionality in software, so it be great if we could access it through Homebridge to build automations etc.

Are shades supported in your plug in?

Thanks.

senorshaun commented 2 years ago

Try the pico out as a stateless keypad with the buttons. I think as far as integration protocol it works that way? That’s off the top of my head.

Shades, I haven’t gotten around to playing with as I don’t have a test motor

On Feb 20, 2022, at 11:53 AM, jfinestone @.***> wrote:

 Hello.

Are PICO remote supported? It looks like someone developed a plug-in, but only for Caseta Pro https://github.com/rnilssoncx/homebridge-pico

would be great if we could have similar functionality, or at least capture a single button press of a PICO.

The PICO have some significant limitations when you try to build functionality in software, so it be great if we could access it through Homebridge to build automations etc.

Are shades supported in your plug in?

Thanks.

— Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android. You are receiving this because you are subscribed to this thread.

jfinestone commented 2 years ago

Pico keypad shows up in Homekit And clicking on button in Home toggles between on/off in Home - but When stateless is false, sends a button press command to Lutron When stateless is true, does not send a button press to Lutron However, pressing the real Pico button does nothing to the button in Home (which is what I need it to do)

Could this have something to do with the fact that Picos do not have LEDs like Keypads do, and maybe the status in Home is using the integration with the LED component in the integration and not monitoring button presses?

In any case, don't spend time on this because homebridge-pico appears to work in RR2 (even though it says its just for CASETA PRO BRIDGE). Check it out if interested.

Thanks.

p.s. whats the correct options for DEBUG - and do they need to be in quotes or not. i tried a bunch of choices, and none seem to enable debug .

senorshaun commented 2 years ago

I took a second looking at this. Am I wrong in thinking that pico remotes are 'stateless' buttons? Like there is no on/off value for each button, only an on press event? Looking at the repo you sent, it looks like they are doing things the same way as me, with a stateless switch listener. I can update the stateless: true to accept button presses, thats not hard at all. I'm not readily seeing why stateless: true does not temporarily toggle the switch in the home app using this plugin. Hard for me to try to debug without a device (like a pico remote). I guess I could just rip out their code, but it would take some effort converting to all to my format. if that plugin is working for you, go for it. If I get my hands on a pico, I'll get around to incorporating it in to here after I can test.

As far as debugging, I believe you have to run HomeKit in debug mode for most of the low level stuff to show up. Not sure how to do that with HOOBS. Maybe try this?

jfinestone commented 2 years ago

It would be great to have this in your plug-in. For two reasons, first of all the other plug-in does not specifically say it will work with RR2, so it may break; and secondly I think it’s just better to have only one integration between the platforms.

I attached some screenshots to show you what the other plug-in looks like. On the home screen, it looks like a button/belly button. Pressing it takes you to the configuration page, it does not send anything back to the Lutron processor. When you press the actual Pico key, The image of it depresses just for a second and then it does whatever related HomeKit commands you have. To configure the HomeKit commands, you click on it and it takes you to that other page.

And yes, the pico is a stateless remote. It does have a tiny LED but it only is on when you are pressing the button it does not function like the LEDs on keypads.

Lastly it would be great if you could ever add shades to the mix. We would like to not have any integration using the native integration.

I run home bridge on a Nas at my house, we run Hoobs at my buddy’s house. I don’t ever get any debug or output from your plugin even though Debug is true (no quotes)

On Mon, Feb 21, 2022 at 4:27 PM senorshaun @.***> wrote:

I took a second looking at this. Am I wrong in thinking that pico remotes are 'stateless' buttons? Like there is no on/off value for each button, only an on press event? Looking at the repo you sent, it looks like they are doing things the same way as me, with a stateless switch listener. I can update the stateless: true to accept button presses, thats not hard at all. I'm not readily seeing why stateless: true does not temporarily toggle the switch in the home app using this plugin. Hard for me to try to debug without a device (like a pico remote). I guess I could just rip out their code, but it would take some effort converting to all to my format. if that plugin is working for you, go for it. If I get my hands on a pico, I'll get around to incorporating it in to here after I can test.

As far as debugging, I believe you have to run HomeKit in debug mode for most of the low level stuff to show up. Not sure how to do that with HOOBS. Maybe try this? https://github.com/hoobs-org/HOOBS/issues/709

— Reply to this email directly, view it on GitHub https://github.com/senorshaun/homebridge-radiora2/issues/17#issuecomment-1047317629, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAHS7I5XOHEHX3ALZYKIHY3U4LJ6ZANCNFSM5O4WUTDA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: @.***>

senorshaun commented 2 years ago

I just got a little pico delivered for amazon. I'll check out that plugin and see what I can get worked in to this one. To be clear, you want the pico, in HomeKit, to status when the physical button is pressed? Presumably to run automations off of. Also it looks like you can customize that plugins' buttons to execute HomeKit actions when pressed. Rather than the other way around, like pressing the button in the HomeKit remote acts the same as pressing the button on the pico. Now that I have it infront of me, and the plugin loaded up, let me know what you are wanting to be able to do

jfinestone commented 2 years ago

Correct. Pressing the button in HomeKit only brings up the configuration of what you want all the buttons to do. It’s only real purpose is so you can hit the physical button on the pico and then it launches something in HomeKit. Either for a single press, a double press, or a long press. You’ll see there’s a lot of different configurations of picos.

On Fri, Feb 25, 2022 at 3:44 PM senorshaun @.***> wrote:

I just got a little pico delivered for amazon. I'll check out that plugin and see what I can get worked in to this one. To be clear, you want the pico, in HomeKit, to status when the physical button is pressed? Presumably to run automations off of. Also it looks like you can customize that plugins' buttons to execute HomeKit actions when pressed. Rather than the other way around, like pressing the button in the HomeKit remote acts the same as pressing the button on the pico. Now that I have it infront of me, and the plugin loaded up, let me know what you are wanting to be able to do

— Reply to this email directly, view it on GitHub https://github.com/senorshaun/homebridge-radiora2/issues/17#issuecomment-1051369277, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAHS7IZUF7NACDFFDVJQCOTU5AH5XANCNFSM5O4WUTDA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: @.***>

senorshaun commented 2 years ago

I almost have a beta ready to test. Am I correct in saying that the Home app doesn’t display the names of buttons correctly?

jfinestone commented 2 years ago

Correct. They seem to all appear just as one button with no way to separate them let me know if you need some additional screenshots

On Fri, Mar 4, 2022 at 6:36 PM senorshaun @.***> wrote:

I almost have a beta ready to test. Am I correct in saying that the Home app doesn’t display the names of buttons correctly?

— Reply to this email directly, view it on GitHub https://github.com/senorshaun/homebridge-radiora2/issues/17#issuecomment-1059656744, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAHS7IZMDEUT3D4TGKOLDT3U6LCDPANCNFSM5O4WUTDA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: @.***>

senorshaun commented 2 years ago

as far as functionality goes, it seems silly to me to have a double press and long press action for the increase/decrease buttons on the pico? Right? What are your thoughts?

jfinestone commented 2 years ago

Interesting question. I think the long press is how you would capture if someone wanted to raise some thing. So I think it’s like you would be holding it until you’re happy with the level. Not sure how to process that programmatically. Let’s say I have zigbee lights and I want to use a Pico to control them I could see the rays lower being important. And it seems like a button that you would hold until you were happy with the level

On Mon, Mar 7, 2022 at 9:31 AM senorshaun @.***> wrote:

as far as functionality goes, it seems silly to me to have a double press and long press action for the increase/decrease buttons on the pico? Right? What are your thoughts?

— Reply to this email directly, view it on GitHub https://github.com/senorshaun/homebridge-radiora2/issues/17#issuecomment-1060942883, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAHS7I7Q7T4R6MHZGG2HTXTU6Y4QTANCNFSM5O4WUTDA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: @.***>

senorshaun commented 2 years ago

I get you. I think you would have to connect the button a shortcut that gets the light value, then increases on 1 and set the light valve. Then that would need to get pushed over and over again to 'raise' the level of a light. So I went ahead and made any buttons longAction a parameter which by default is 'click'. but if you set it, on a per button level, to 'repeat', the long press button will get pressed repeatedly, every half second, for up to 100 clicks (thats from 0 to 100, I didn't want to get in to a situation when it just got pressed for forever because of some quirk where the plugin doesn't receive the release notification of the pico button). I think that should accomplish what you're wanting. Press once to go up 1%. Press and hold for 5 seconds to go up 10%. etc

jfinestone commented 2 years ago

That’s great. Looking forward to trying it.

On Thu, Mar 10, 2022 at 2:23 PM senorshaun @.***> wrote:

I get you. I think you would have to connect the button a shortcut that gets the light value, then increases on 1 and set the light valve. Then that would need to get pushed over and over again to 'raise' the level of a light. So I went ahead and made any buttons longAction a parameter which by default is 'click'. but if you set it, on a per button level, to 'repeat', the long press button will get pressed repeatedly, every half second, for up to 100 clicks (thats from 0 to 100, I didn't want to get in to a situation when it just got pressed for forever because of some quirk where the plugin doesn't receive the release notification of the pico button). I think that should accomplish what you're wanting. Press once to go up 1%. Press and hold for 5 seconds to go up 10%. etc

— Reply to this email directly, view it on GitHub https://github.com/senorshaun/homebridge-radiora2/issues/17#issuecomment-1064565714, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAHS7I6XMHHH7PZFKU3QZWLU7JY4VANCNFSM5O4WUTDA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: @.***>

senorshaun commented 2 years ago

ok I have a beta tested and released. I reloaded my normal config with it, nothing changed or broke with it, so you should be good to test it out.

npm install (-g if you use it) homebridge-radiora2@beta

"keypads":[{ "name": "Pico", "id": 39, "stateless": true, "buttons":[{ "name": "On", "id": 2 },{ "name": "Off", "id": 4, "longpressrepeat": true }] }] Making a keypad stateless is set on creation, so you have to remove the keypad from HomeKit and add it back if you want to change that. Buttons are built on keypad creation so you have to remove the keypad from HomeKit and add it back if you want to add/remove buttons or change their name. Other than name and id, all button config parameters are NOT set on creation, they are set the first time that button is pressed after homebridge has been started up. so you can make a change in your config and then just restart homebridge to see it.

name - obvious id - obvious longpressrepeat - default: false. set to true if you want the long press button in HomeKit to get pressed repeatedly when you hold the pico button clicktime - default 500 this is how long the plugin will listen to determine single/double/hold. in milliseconds repeattime - default 500 this is how often the plugin will press the button when repeating (only used when longpressrepeat = true). in milliseconds repeatmax - default 100 this is how many times the plugin will press the held button

Let me know how it works out for you

senorshaun commented 2 years ago

@jfinestone did you test this?

jfinestone commented 2 years ago

Waiting for Custom PICOs to arrive… Thank you!

On Mon, May 16, 2022 at 6:46 PM senorshaun @.***> wrote:

@jfinestone https://github.com/jfinestone did you test this?

— Reply to this email directly, view it on GitHub https://github.com/senorshaun/homebridge-radiora2/issues/17#issuecomment-1128314345, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAHS7I5GQPVRUACSXSWS5CTVKL3ARANCNFSM5O4WUTDA . You are receiving this because you were mentioned.Message ID: @.***>

senorshaun commented 2 years ago

do you have any regular ones you can test with? so I can push from beta to prod?

jfinestone commented 2 years ago

I'll order one. Thanks.

senorshaun commented 2 years ago

Sorry I thought you already had them and were using them with the caseta plugin?

jfinestone commented 2 years ago

I had one at another house - they are gone right now. So I just ordered one for my place (since the custom ones are 3-4 months out I found out last week ugh). Thanks. What version of the module should I have loaded to test these and what should the config be? thanks.

On Mon, May 16, 2022 at 7:37 PM senorshaun @.***> wrote:

Sorry I thought you already had them and were using them with the caseta plugin?

— Reply to this email directly, view it on GitHub https://github.com/senorshaun/homebridge-radiora2/issues/17#issuecomment-1128338686, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAHS7I3FQIVCB6NYW2DFS3LVKMA4ZANCNFSM5O4WUTDA . You are receiving this because you were mentioned.Message ID: @.***>

senorshaun commented 2 years ago

check this comment https://github.com/senorshaun/homebridge-radiora2/issues/17#issuecomment-1065984532

senorshaun commented 1 year ago

these are working in 1.5.1