openhab / openhab-google-assistant

openHAB Google Assistant: Actions on Google for openHAB
Eclipse Public License 2.0
176 stars 86 forks source link

Curtain commands from Assistant are incorrect #433

Open julesbike opened 1 year ago

julesbike commented 1 year ago

I have electric curtains set up as follows:

Rollershutter left_dining_curtain "Left Dining Curtain" { ga="Curtain" }

When I ask google to open or close I get either

2023-01-05 18:40:09.267 [INFO ] [openhab.event.ItemCommandEvent      ] - Item 'left_dining_curtain' received command MOVE
2023-01-05 18:41:38.020 [INFO ] [openhab.event.ItemCommandEvent      ] - Item 'left_dining_curtain' received command DOWN
2023-01-05 18:41:54.315 [INFO ] [openhab.event.ItemCommandEvent      ] - Item 'left_dining_curtain' received command UP

It's not a major issue as I can trap this in rules but I think TOGGLE OPEN CLOSE would seem more appropriate

michikrug commented 1 year ago

A bit unsure of what your problem is...

OpenHAB Rollershutter items do only know the UP/DOWN commands (besides move and stop).

What behavior would you expect in more detail?

julesbike commented 1 year ago

Ok I just read in the openhab Google assistant action documents that the traits open and close are supported. I guess I need to set them up as switches for this. What is sent back by Google , is it a number?

michikrug commented 1 year ago

Yes, Google responds with "openPercent" ranging from 0 to 100.