Help with Amazon Alexa Integration

I have successfully integrated a windows based OpenHAB 2.1 server with a test KNX installation I have, I can turn on/off the lights, dim them and control the thermostat.

I am trying to integrate Alexa to control the KNX system, so I far I have gotten everything working fine.

I can tell Alexa to switch or dim lights fine.

I also tried integrating the thermostat and it worked fairly well, I can ask Alexa about the current temperature and the target temperature, I can ask her to set the temperature to a certain degree and ask her to increase/decrease it.

the only problem I have is with her response, specifically the target temperature. here is an example.

Good Response
Alexa, what is the Living Room Thermostat Temperature?
Reply, the Living Room Thermostat Temperature is xx.x degrees.

Bad Response
Alexa, what is the Living Room Thermostat Set to?
Reply, Unknown Mode is set to xx.x

Alexa always replies to the target temperature question with Unknown Mode even though she gets the number right in her response.

I was wondering if anyone else encountered this, is it a problem with Alexa, the Homekit tagging or my code, I will include here.

Group GF_Living_TH “Living Room Thermostat” [ “Thermostat” ]

Number TH_GF_Temp “Living Room Temperature” (GF_Living_TH) [ “CurrentTemperature” ] { knx=“0/0/5” }

Number TH_GF_Set “Living Room Target Temperature” (GF_Living_TH) [ “TargetTemperature” ] { knx=“0/0/7” }

what am I doing wrong?

Please follow the readme at
http://docs.openhab.org/addons/io/homekit/readme.html
You need to have ALL itemsin the group, so out of your example, I don’t see the mode item.

Thank you for your reply.

I added the mode item even though I don’t use it because my thermostat is always set to cool mode (I live in a hot country so no need for heating).

Now the code looks like this,

Group GF_Living_TH “Living Room Thermostat” [ “Thermostat” ]

Number TH_GF_Temp “Living Room Temperature” (GF_Living_TH) [ “CurrentTemperature” ] { knx=“0/0/5” }

Number TH_GF_Set “Living Room Target Temperature” (GF_Living_TH) [ “TargetTemperature” ] { knx=“0/0/7” }

String TH_GF_HCMode “Living Room Heating/Cooling Mode” (GF_Living_TH) [ “homekit:HeatingCoolingMode” ]

Alexa changed her response but it’s still wrong, now if I ask.

Alexa, what is the living room thermostat set to?
Answer, null is set to xx.x.

I still don’t get why this is happening, do I need to link the mode item to something in my KNX system something to give value? but shouldn’t it be a switch instead of a string? because the heat/cool mode in most KNX thermostats are usually 1 bit.

I think I figured it out, even though I defined the mode item I did not give it a value.

To do that from KNX I think I need to setup some rules to convert the KNX byte string to ASCII strings which then I link to the Mode items.

can someone confirm yes or no? has anyone done it before that can help me with the rules?

I have a similar problem with my thermostate:
What is the voice command to switch the HeatingCoolingMode?

Dear all,

I worked on the issue:

“Alexa, turn the heating to 22 degrees” - > “Thermostat heating is set to 22 degrees”
“Alexa, switch the heating off” -> “Thermostat heating does not support this”
(from German)

Can anyone help? Please check Thermostat works well in Google Home, but not with Alexa