Official Alexa Smart Home Skill for openHAB 2

Yes, I also get a 21.1 temperature format, but I’m not as far as you to get this strange spelling :wink:
My item is tagged with [ “CurrentTemperature” ], as described by you. I don’t have a extra weather skill activated.
At the moment I have no further idea, how to solve this.

@staehler67 All other tagged items are running with Alexa, but the Temperature?

Correct, almost every item is meanwhile controlled by alexa, which works pretty fine. Just this thermostat group(s) won’t work :frowning:

@staehler67 Could you please post your complete itemgroup?

I tested it once again with only 1 thing-channel linked to an item: (similar like your case, because you don’t have a “real” thermostat:

Group GF_KitchenThermostat "Küche Thermostat" (gGF) [ "Thermostat" ]
String GF_Kitchen_maxMode    "M:" 				<climate>	 (gMAX, GF_Kitchen, GF_KitchenThermostat) [ "homekit:HeatingCoolingMode" ] 
Number GF_Kitchen_maxActual  "IST Temperatur  [%.1f °C]" <temperature>	(gMAX, GF_Kitchen, Temperature1, GF_KitchenThermostat) [ "CurrentTemperature" ]	{channel="max:thermostat:LKF0025489:MEQ1442698:actual_temp"}
Number GF_Kitchen_maxSetTemp "SOLL Temperatur K [%.1f °C]" <temperature>  (gMAX, GF_Kitchen, GF_KitchenThermostat) [ "TargetTemperature" ] 

…and it’s running fine!!
I also linked my itemgroup “Küche Thermostat” to an Alexa-Group “Heizung Küche”.

Now I can ask:

"Alexa, wie ist die Temperatur von ‘Heizung Küche’?“
or
"Alexa, wie ist die Temperatur von ‘Küche Thermostat’?”

answer (in both cases!!): “Die Temperatur von Küche Thermostat ist 19ter 5 Grad”

Requesting the current temperature is not supported yet in German according to the docs:

GetTemperatureReadingRequest *US and UK
GetTemperatureReadingResponse *US and UK
GetTargetTemperatureRequest *US and UK
GetTargetTemperatureResponse *US and UK

As soon as Amazon enables this, our skill should just work.

@digitaldan But I use it in german and it is running!! It is only spelled a little wrong. Alexa is telling: “Die Temperatur von Wandthermostat ist 21ster 1 Grad”. It better should be: “ist 21 Komma 1 Grad” or “21 Punkt 1 Grad”. But at the moment this don’t bother me.

see also this topic: Complete list of ALL supported english/german voice commands of "Official Alexa Smart Home Skill for OH2"?

I am pretty sure that dan knows that you can use this feature in german and alexa answers in a wrong way, based on this issue :wink:

As Amazon expects a float value I would assume the “bug” is on their side which is may why they don’t officially support it yet, even if the request is already working in someway in german…

Btw. you can make a rule with a second item to round it.

Hi There,

I have a bit of a luxery problem, I tagged the Xiaomi Temp sensor to my Amazon Echo aka Alexa with the tag
[ “CurrentTemperature” ] and this works brilliant: When i Ask:

Alexa What is the Bedroom Temperature? , she answers “The Bedroom Temperature is 24 point 75634786679657647877 degrees”

And yes this is very accurate :+1:, but a bit to much detail for me!:joy: “The Bedroom Temperature is 24 point 7 degrees” would be more than enough for me!

Anyone know how to fix that?
Ray

@X-Ray181

see posting before:

Thanks Alex,
But i’m new to OH and would’nt know how to do that, in basicUI the figure is correct (24.7) so thats not the problem, how can a rule make Alexa round up the figure OH gets from the sensor?
In the log you also see the figure with the too many decimals…

Make a second dummy/proxy item with rounded values and make a rule to update the item when the original temperature item received an update:

Number zwaveLivingMotion_1_Temp_rounded "Inside [%.1f °C]" [ "CurrentTemperature" ]
rule "Round Temperature Motion Sensor 1"
when
    Item zwaveLivingMotion_1_Temp received update
then
if (zwaveLivingMotion_1_Temp.state != NULL){
    val roundedNumber = (Math::round((zwaveLivingMotion_1_Temp.state as DecimalType).floatValue()* 10)).floatValue() /10
    sendCommand(zwaveLivingMotion_1_Temp_rounded,roundedNumber)
    }
end

Note: zwaveLivingMotion_1_Temp is the name of the zwave temperature channel which actually measures the temperature

This comes from the label "Inside [%.0f C]" the part in the brackets determines in which way it is displayed but the true value still remains untouched.

2 Likes

Hello Rick,
It’s working! :clap::smiley: thanks man, really happy with that.

There is a small difference between the way she answers:
When I ask: “What is the Office Temperature?” i get: “The Office Temperature is 24 point 856651896232629 degrees” and with your rule: “What is the inside temperature?” she just answers: “24 point 9”

1 Like

Maybe because @Rickecho forgot the degree symbol in the item definition.

Mhm I not quite sure. I don’t know if the symbol is need, I don’t think so. Btw there is a typo it should be [%.1f °C]

Edit: There were two typos. The missing ° and it should be .1

Ok, you mean the little °, you’re right, i forgot to add that, but here’s something strange, I added the rule and item changes for my 6 temp/humid sensors, and restarted OH, and it now works perfect’!, even without adding the °.
And she now answers as before: "The Office Temperatue is 24 point 9 Degrees"
So for now I say: If it aint broke, don’t fix it…
Thanks

It works perfect! with the typos, so there not really typos! :smile:

:smiley: Gald you got it working.
Yes they don’t affect alexa but they affect the way it is displayed in paper ui, simple ui or habpanel!

Can someone please explain in detail(step-by-step) how to add tags to items that have been discovered by paperUI?

I understand I need to use the REST api to add the tags, but I don’t want to screw it up. Also, are there any alternative ways to add tags?

Is item tagging in PaperUI being worked on?

Quick questions related to Rollershutters:

I’ve got this in .items file:
Rollershutter BlindNorth “North Blind [%d %%]” [ “Lighting” ] {channel=“somfytahoma:exteriorvenetianblind:a3ab5cd5:f4e907c6-b809-416b-9b92-ead71e07764f:control”}
Dimmer BlindNorthPos “North Blind position [%.1f]” [ “Lighting” ] {channel=“somfytahoma:exteriorvenetianblind:a3ab5cd5:f4e907c6-b809-416b-9b92-ead71e07764f:position”}

setting the position via Alexa works like a charm, however the simple turn on/turn off control (“turn on North Blind”) ends up with “North Blind doesn’t support this”.
Any hint, what am I doing wrong?

Thx

b72

My tip is to delete the database and readd your items with config files.
I was in the same situation. Everything was set up via paperui and I needed to add tags. The whole process is uncomfortable, a bit confusing as you have long lists and gets really annoying when you want to make changes. So trust me, use config files instead.

Anyway here is how you could do it:

Avoiding the terminal

  • Get Rest API Documentation (Paper UI-> Addons->Misc->Rest API Documentation->Install)
  • Get Name of item (the name not the label) via paper ui (or even via rest api)
  • Go to Resp API Doc: http://<ip>:8080/doc/index.html
  • Go to Items, “PUT /items/{itemname}/tags/{tag}”
    – Enter itemname and desired tag
    – Click “Try it out!”

More sophisticated way:

  • Open a terminal (on osx/linux you are good, using windows curl is needed to be downloaded first) and send the command:
curl -X PUT --header "Content-Type: application/json" --header "Accept: application/json" "http://<ip>:8080/rest/items/<itemname>/tags/<tagname>"

(replace <ip>,<itemname>,<tagname> with your values)

2 Likes