Alexa V3 skill - Blind Control Inverted Values

Hey All,

I am trying to implement the integration between Openahb and Alexa V3 Metadata. All is working normally and smoothly except the RollerShutter item where the Open and Close commands send inversed values to Openhab.

In another way when I say Alexa “Open Kitchen Blind” Openhab receives the 100 value which shows that the Blind is Closed on the app. And when we send a command “Close Kitchen Blind” Openhab receives the 0 Value which shows the Blind is Open.

Here is the Item that I use for this purpose.

Rollershutter Kitchen_Blind “Kitchen Blind” (gBlinds) {alexa=“Blind”}

Please advise how we can change the default values that Alexa Skill send to Openhab or any other solution to solve this issue.

Thank you,

See https://www.openhab.org/docs/ecosystem/google-assistant/#google-assistant-action, pay special attention to the [ inverted=true ] on the Rollershutter examples.

Such option is not supported with the Alexa skill as of yet but there are plan to do so.

You will have to invert the semantic extension settings of the actual metadata configuration associated with blind metadata label. It’s the not the cleanest but this is the only solution currently.

Rollershutter Blind "Blind" {alexa="RangeController.rangeValue" [category="INTERIOR_BLIND", friendlyNames="@Setting.Opening", supportedRange="0:100:10", unitOfMeasure="Percent", actionMappings="Close=100,Open=0,Lower=(+10),Raise=(-10)", stateMappings="Closed=100,Open=0:99"]}
1 Like

Thank you @jeshab, tried it and works perfectly.

Regards,

I just tried that but for me it still does it wrong. No matter how I change it it is always inverted.
I should add I tried this in german.

Thanks @jeshab

This just worked for me :slight_smile:

1 Like

Hello to all,

I have a similar behaviour than salexes. With the invertet settings of the post, my shutters go only into the open direction (to 0%). It doesn´t matter what I use.
When I use “Lower” (“niedriger”) the shutter goes into 0% direction. -> Wrong
When I use “Raise” (“erhöhen”) the shutter goes into 0% directtion. -> Correct

When I use “close” (“zu”) the shutter goes to 100%. -> Correct
When I use “open” (“auf”) the shutter goes to 0% -> Correct

For your information this is a part of my items, is the Rollershutter the problem and I am located in Germany too.

Rollershutter    KNXDeviceKnxRollladenGaestezimmer                  "Rollladen Gästezimmer [%d %%]"                               <rollershutter>     (GF_Shutter, GF_GuestRoom, gShutter)                                                          {channel="knx:device:bridge:KnxRolladenEg:KnxRollladenGaestezimmer", alexa="RangeController.rangeValue" [category="INTERIOR_BLIND", friendlyNames="@Setting.Opening", supportedRange="0:100:10", unitOfMeasure="Percent", actionMappings="Close=100,Open=0,Lower=(+10),Raise=(-10)", stateMappings="Closed=100,Open=0:99"]}

It seems that we are currently two guys in Germany that have this behaviour, maybe a translation error?

Regards Köchi

Based on your item definition, the lower action should actually be increasing your item state by 10% and raise action should be decreasing by 10%. So most likely, it is the way you are formulating your request that is preventing the proper action from being trigger.

According to the utterance examples listed for this interface, it appears that you should be using the term “runter” for lower and “hoch” for raise.

You are right. When I use the specified german sentence it works as expected.

image

Thanks for your help and for the link.

I have used now the same syntax for a Group

Is this allowed because it does not start with {alexa=“Endpoint.Other” … ?

Group:Rollershutter:OR(UP, DOWN)    GF_Kitchen_Shutter         "Alle Rollläden in der Küche [(%d)]"                           <rollershutter>      (Home, GF_Kitchen)          {alexa="RangeController.rangeValue" [category="EXTERIOR_BLIND", friendlyNames="@Setting.Opening", supportedRange="0:100:25", unitOfMeasure="Percent", actionMappings="Close=100,Open=0,Lower=(+25),Raise=(-25)", stateMappings="Closed=100,Open=0:99"]}

In the documentation I do not find some details:

The group triggered with the utterances from above works only the “raise” goes into the wrong direction.

Is the a specific utterances for Groups?

Yes, groups with a defined item type are considered as a standard item and in your case as a Rollershutter. On a side note, related to your item definition, I don’t think your group state aggregation function is valid OR(UP, DOWN) since UP and DOWN aren’t valid states for that item type. There are few threads on this forum if you search for “rollershutter group” that give more details on how to set these up properly.

There are no difference as your group item is considered as a single endpoint from the skill perspective. It comes down to how you modeled your item and the utterances you are using. As far as I can see, your item definition looks fine. You can check your event logs to see which command the skill is sending to your server and confirm what was understood on the Alexa side by looking at your voice history.

Hi, thank you for the information.
But I didn’t get how to make this changes it in OpenHAB v3.0 ?

EDIT:
I tired this setting but it doesn’t do anything…

value: Blind
config:
actionMappings: Close=100,Open=0,Lower=(+10),Raise=(-10)
category: INTERIOR_BLIND
stateMappings: Closed=1:100,Open=0

Could you please provide some more information on what you are trying to achieve and what you mean by “it doesn’t do anything”?

Hi, sorry, you right. here my configuration:


Openhab Controls from screenshot works as expected: up=up, down=down.
Google Assist is also ok (inverted=false): “go down/close”=goes down

But I have to say “Alexa, move Arbeitszimmer Fenster to 100 %” to go down. If I say go down, it goes up :confused:

I have official openhabian wit OH 3.0 and created all things/items via Main UI. (no text-files at all).
My problem is now: I don’t where to put this line to get it work:

Rollershutter Blind “Blind” {alexa=“RangeController.rangeValue” [category=“INTERIOR_BLIND”, friendlyNames="@Setting.Opening", supportedRange=“0:100:10”, unitOfMeasure=“Percent”, actionMappings=“Close=100,Open=0,Lower=(+10),Raise=(-10)”, stateMappings=“Closed=100,Open=0:99”]}

If I click (in my screenshot) on Amazon Alexa, I can got to code and there I put this code in:
image
But, it does nothing. That means, Alexa still runs blinds in the wrong direction…

1 Like

Have you run a discovery after making the configuration change? Also, what command are you receiving from the skill in your OH event logs?

2 Likes

Thx, that was the thing! Now it works :slight_smile:

Hey all, I have the same problem and could fix it with the picture of the config that Adminius posted.

It’s working partially now.
If I say “Alexa, öffne/schließe Rolladen”/“Alexa, open/close shutter” it does work correct after the fix.

However “Alexa, Rolladen runter/hoch”/“Alexa, raise/lower shutter” is still switched.

Metadata:

value: Blind
config:
  supportedRange: 0:100:10
  unitOfMeasure: Percent
  friendlyNames: "@Setting.Opening"
  actionMappings: Close=100,Open=0,Lower=(+10),Raise=(-10)
  category: INTERIOR_BLIND
  stateMappings: Closed=1:100,Open=0

events.log

2021-10-28 14:30:25.985 [INFO ] [openhab.event.ItemCommandEvent      ] - Item 'RolladenGamingRoomStrasse_Rollershutter' received command 70
2021-10-28 14:30:26.399 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'RolladenGamingRoomStrasse_Rollershutter' changed from 80 to 75
2021-10-28 14:30:30.565 [INFO ] [openhab.event.ItemCommandEvent      ] - Item 'RolladenGamingRoomStrasse_Rollershutter' received command 65
2021-10-28 14:30:31.427 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'RolladenGamingRoomStrasse_Rollershutter' changed from 75 to 70

It looks like it is receiving percentage commands with steps of 5 and responds with a different range bit still step of 5.
And that despite the metadata setting it to 10.

Is my Syntax incorrect or am I missing something else?
Everytime I change something I delete the Item inside Alexa app and discover the updated version.

Thanks in advance.
Neithari

Not that it would have any impact, it should be stateMappings="Closed=100,Open=0:99". Otherwise, the rest looks good.

As far as your observation, the binding controlling your blind is the culprit. As you can see, the skill sent command 70 and the state, controlled by your binding, only decreased to 75. Therefore, on the subsequent request, it used that state to determine the command value of 65.

Anyway, a new metadata syntax for the skill will be released shortly, including new door/window covering capabilities. This implementation will switch to using the UP/DOWN/STOP commands, opposed to specific percentage, on semantic actions for Rollershutter items.

But even with my enocean binding responding with a step of 5 to the step of 10 from alexa it is still responding in a wrong direction, despite me changing that. +10 when it should be -10 and vice versa.

Thank you so far :slight_smile:

Hi all I don’t understand if I have to wait or I have to change my configuration.
With this configuration my roller are working opposed:

value: RangeController.rangeValue
config:
  supportedRange: 0:100:10
  unitOfMeasure: Percent
  friendlyNames: "@Setting.Opening"
  actionMappings: Close=100,Open=0,Lower=(+20),Raise=(-20)
  category: EXTERIOR_BLIND
  stateMappings: Closed=100,Open=0:99

If I say “close” it open and viceversa.
Have I to wait a fix or have to map wrong to have the right commands?