Amazon Echo to Domoticz Bridge: switches, sensors & more
Moderator: leecollings
-
- Posts: 1571
- Joined: Friday 25 March 2016 17:43
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
hah
The friendlyName is just lifted from Domoticz - so i'm afraid you'd need to change them in Domoticz, delete the discovered devices in ALexa, then rediscover.
The friendlyName is just lifted from Domoticz - so i'm afraid you'd need to change them in Domoticz, delete the discovered devices in ALexa, then rediscover.
Native Alexa skill and Google app - register at https://www.controlicz.com - https://twitter.com/Controlicz
- heggink
- Posts: 972
- Joined: Tuesday 08 September 2015 21:44
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 12451
- Location: NL
- Contact:
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
Apologies if this was asked before but can I use this to trigger scenes and/of groups?
Sent from mTalk
Sent from mTalk
Docker in Truenas scale, close to latest beta
DASHTICZ 🙃
RFXCOM, zwavejs2mqtt, zigbee2mqtt,
P1 meter & solar panel
Google home, Wifi Cams motion detection
Geofence iCloud, Bluetooth & Wifi ping
Harmony hub, Nest, lots more :-)
DASHTICZ 🙃
RFXCOM, zwavejs2mqtt, zigbee2mqtt,
P1 meter & solar panel
Google home, Wifi Cams motion detection
Geofence iCloud, Bluetooth & Wifi ping
Harmony hub, Nest, lots more :-)
-
- Posts: 1571
- Joined: Friday 25 March 2016 17:43
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
Groups yes, Scenes no
Native Alexa skill and Google app - register at https://www.controlicz.com - https://twitter.com/Controlicz
-
- Posts: 74
- Joined: Thursday 24 September 2015 11:44
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
fergalom wrote:They are all dummy dimmers - Type: Light/switch - Switch: DimmerMadgeni wrote:1. Argh! This seems to be a very strange issue, where it seems fine for some people, and wrong for others. What type of Dimmers do you have out of interest?
2. I'll take a look - not sure what happens to the payload, as the integer seems to be there, so not sure why Alexa doesn't interpret it
3. I'm afraid that currently Alexa doesn't support asking via the Smart Home Skill. As soon as it does, i'll implement it. The only way to get this would be to rebuild it as a Custom skill (Alexa, ask 'Home' what the temperature is in the front room etc etc) - but would be a piece of work to do this. I'm loathe to whilst this is allegedly on Alexa's roadmap for Smart Home
4. Can you give me a couple of user stories for multi-selector switches to work with?
Using multi-selectors to enable various airplay speakers around the house, quickly set heating modes, select & play some radio channels.
Interestingly if you ask alexa to set a multi-selector switch to a percentage, it works sort of (the dimming issue skews it).
Coming back to this topic on dimmers, it seems there are 3 types
Dimmer - setlevel range 0-16
Dimmer - setlevel range 0-32
Dimmer - setlevel range 0-100
From a /json.htm?type=devices&rid=348 query, each dimmer lists a "MaxDimLevel:"
Can this be used in your code to implement the correct dimming scale?
-
- Posts: 10
- Joined: Saturday 10 January 2015 19:43
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
Take a look at this change - https://github.com/thosirl/alexa_domo/c ... c13480fd7cfergalom wrote:fergalom wrote:They are all dummy dimmers - Type: Light/switch - Switch: DimmerMadgeni wrote:1. Argh! This seems to be a very strange issue, where it seems fine for some people, and wrong for others. What type of Dimmers do you have out of interest?
2. I'll take a look - not sure what happens to the payload, as the integer seems to be there, so not sure why Alexa doesn't interpret it
3. I'm afraid that currently Alexa doesn't support asking via the Smart Home Skill. As soon as it does, i'll implement it. The only way to get this would be to rebuild it as a Custom skill (Alexa, ask 'Home' what the temperature is in the front room etc etc) - but would be a piece of work to do this. I'm loathe to whilst this is allegedly on Alexa's roadmap for Smart Home
4. Can you give me a couple of user stories for multi-selector switches to work with?
Using multi-selectors to enable various airplay speakers around the house, quickly set heating modes, select & play some radio channels.
Interestingly if you ask alexa to set a multi-selector switch to a percentage, it works sort of (the dimming issue skews it).
Coming back to this topic on dimmers, it seems there are 3 types
Dimmer - setlevel range 0-16
Dimmer - setlevel range 0-32
Dimmer - setlevel range 0-100
From a /json.htm?type=devices&rid=348 query, each dimmer lists a "MaxDimLevel:"
Can this be used in your code to implement the correct dimming scale?
It passes through MaxDimLevel as part of the additionalApplianceDetails, and then uses it to calculate a 'proper'' percentage based on the level range.
This works for my LightwaveRF dimmers, where they have a range of 0-32, so diving by 3.125 (100/32) gives me the proper percentage.
Let me know if this works for, and I can make a pull request.
-
- Posts: 74
- Joined: Thursday 24 September 2015 11:44
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
Thanks for this - will do.
-
- Posts: 1571
- Joined: Friday 25 March 2016 17:43
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
That's great thos- thanks
In my defence, i'm not sure MaxDimLevel is in the domoticz API doc
In my defence, i'm not sure MaxDimLevel is in the domoticz API doc
Native Alexa skill and Google app - register at https://www.controlicz.com - https://twitter.com/Controlicz
-
- Posts: 74
- Joined: Thursday 24 September 2015 11:44
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
Thos, had to do another minor change to domoticz.js to get all dimmers to work as you would expect.
https://github.com/fergalom/alexa_domo/ ... 70a6e39c34
https://github.com/fergalom/alexa_domo/ ... 70a6e39c34
-
- Posts: 10
- Joined: Saturday 10 January 2015 19:43
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
Cool, yes, works for me now too. (That'll teach me for testing remotely!)
Can you make a pull request, and I'll do same back to Madgeni and we can maybe get this all back together?
Can you make a pull request, and I'll do same back to Madgeni and we can maybe get this all back together?
-
- Posts: 74
- Joined: Thursday 24 September 2015 11:44
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: RE: Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
Will do this afternoon, thanks for your helpthos wrote:Cool, yes, works for me now too. (That'll teach me for testing remotely!)
Can you make a pull request, and I'll do same back to Madgeni and we can maybe get this all back together?
Sent from my SM-G930F using Tapatalk
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
Hi
I followed Madgeni's instructions and got the Lambda funtion to work. The discovery results in
If I try to discover the devices in the Alexa App I can see according Lambda log entries but the App doesn't find any devices
Any idea what I can do?
I followed Madgeni's instructions and got the Lambda funtion to work. The discovery results in
Code: Select all
{
"header": {
"namespace": "Alexa.ConnectedHome.Discovery",
"name": "DiscoverAppliancesResponse",
"payloadVersion": "2"
},
"payload": {
"discoveredAppliances": [
{
"applianceId": "509",
"manufacturerName": "Y-Hub",
"modelName": "RGBW",
"version": "Dimmer",
"friendlyName": "Wohnzimmer Stehlampe",
"friendlyDescription": "Lighting Limitless/Applamp",
"isReachable": true,
"actions": [
"incrementPercentage",
"decrementPercentage",
"setPercentage",
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "Dimmer",
"WhatAmI": "light"
}
},
{
"applianceId": "257",
"manufacturerName": "TRX",
"modelName": "AC",
"version": "On/Off",
"friendlyName": "Jonas Lampinons",
"friendlyDescription": "Lighting 2",
"isReachable": true,
"actions": [
"incrementPercentage",
"decrementPercentage",
"setPercentage",
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "On/Off",
"WhatAmI": "light"
}
},
{
"applianceId": "55",
"manufacturerName": "Temperatur Büro",
"modelName": "THR128/138, THC138",
"version": "temp",
"friendlyName": "Büro",
"friendlyDescription": "Temp",
"isReachable": true,
"actions": [
"setTargetTemperature"
],
"additionalApplianceDetails": {
"WhatAmI": "temp"
}
},
{
"applianceId": "17",
"manufacturerName": "Brauchwasserwärmepumpe",
"modelName": "AC",
"version": "On/Off",
"friendlyName": "Brauchwasserwärmepumpe",
"friendlyDescription": "Lighting 2",
"isReachable": true,
"actions": [
"incrementPercentage",
"decrementPercentage",
"setPercentage",
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "On/Off",
"WhatAmI": "light"
}
},
{
"applianceId": "477",
"manufacturerName": "TRX",
"modelName": "ELRO AB400",
"version": "On/Off",
"friendlyName": "Lichterkette DG",
"friendlyDescription": "Lighting 1",
"isReachable": true,
"actions": [
"incrementPercentage",
"decrementPercentage",
"setPercentage",
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "On/Off",
"WhatAmI": "light"
}
},
{
"applianceId": "199",
"manufacturerName": "Sauna",
"modelName": "SetPoint",
"version": "temp",
"friendlyName": "Sauna Temperatur",
"friendlyDescription": "Thermostat",
"isReachable": true,
"actions": [
"setTargetTemperature"
],
"additionalApplianceDetails": {
"WhatAmI": "temp"
}
},
{
"applianceId": "35",
"manufacturerName": "TRX",
"modelName": "RFY",
"version": "Venetian Blinds US",
"friendlyName": "Jonas",
"friendlyDescription": "RFY",
"isReachable": true,
"actions": [
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "Venetian Blinds US",
"WhatAmI": "blind"
}
},
{
"applianceId": "478",
"manufacturerName": "Harmony Hub",
"modelName": "AC",
"version": "Push On Button",
"friendlyName": "Alles aus",
"friendlyDescription": "Lighting 2",
"isReachable": true,
"actions": [
"incrementPercentage",
"decrementPercentage",
"setPercentage",
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "Push On Button",
"WhatAmI": "light"
}
},
{
"applianceId": "203",
"manufacturerName": "Brauchwasserwärmepumpe",
"modelName": "THR128/138, THC138",
"version": "temp",
"friendlyName": "Brauchwasser",
"friendlyDescription": "Temp",
"isReachable": true,
"actions": [
"setTargetTemperature"
],
"additionalApplianceDetails": {
"WhatAmI": "temp"
}
},
{
"applianceId": "523",
"manufacturerName": "Samsung Navibot",
"modelName": "Switch",
"version": "Push On Button",
"friendlyName": "Saugroboter Start/Stop",
"friendlyDescription": "Light/Switch",
"isReachable": true,
"actions": [
"incrementPercentage",
"decrementPercentage",
"setPercentage",
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "Push On Button",
"WhatAmI": "light"
}
},
{
"applianceId": "256",
"manufacturerName": "TRX",
"modelName": "AC",
"version": "On/Off",
"friendlyName": "Jonas Licht",
"friendlyDescription": "Lighting 2",
"isReachable": true,
"actions": [
"incrementPercentage",
"decrementPercentage",
"setPercentage",
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "On/Off",
"WhatAmI": "light"
}
},
{
"applianceId": "13",
"manufacturerName": "Keller-Temperatur",
"modelName": "THR128/138, THC138",
"version": "temp",
"friendlyName": "WP-Ablufttemperatur",
"friendlyDescription": "Temp",
"isReachable": true,
"actions": [
"setTargetTemperature"
],
"additionalApplianceDetails": {
"WhatAmI": "temp"
}
},
{
"applianceId": "202",
"manufacturerName": "Sauna",
"modelName": "THR128/138, THC138",
"version": "temp",
"friendlyName": "Sauna",
"friendlyDescription": "Temp",
"isReachable": true,
"actions": [
"setTargetTemperature"
],
"additionalApplianceDetails": {
"WhatAmI": "temp"
}
},
{
"applianceId": "34",
"manufacturerName": "TRX",
"modelName": "RFY",
"version": "Blinds Inverted",
"friendlyName": "Wintergarten horizontal",
"friendlyDescription": "RFY",
"isReachable": true,
"actions": [
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "Blinds Inverted",
"WhatAmI": "blind"
}
},
{
"applianceId": "488",
"manufacturerName": "Harmony Hub",
"modelName": "AC",
"version": "Push On Button",
"friendlyName": "Ambiente Beleuchtung",
"friendlyDescription": "Lighting 2",
"isReachable": true,
"actions": [
"incrementPercentage",
"decrementPercentage",
"setPercentage",
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "Push On Button",
"WhatAmI": "light"
}
},
{
"applianceId": "200",
"manufacturerName": "Sauna",
"modelName": "AC",
"version": "On/Off",
"friendlyName": "Sauna",
"friendlyDescription": "Lighting 2",
"isReachable": true,
"actions": [
"incrementPercentage",
"decrementPercentage",
"setPercentage",
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "On/Off",
"WhatAmI": "light"
}
},
{
"applianceId": "526",
"manufacturerName": "TRX",
"modelName": "ARC",
"version": "On/Off",
"friendlyName": "Heizlüfter Bad DG",
"friendlyDescription": "Lighting 1",
"isReachable": true,
"actions": [
"incrementPercentage",
"decrementPercentage",
"setPercentage",
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "On/Off",
"WhatAmI": "light"
}
},
{
"applianceId": "490",
"manufacturerName": "TRX",
"modelName": "ELRO AB400",
"version": "On/Off",
"friendlyName": "Luftbefeuchter",
"friendlyDescription": "Lighting 1",
"isReachable": true,
"actions": [
"incrementPercentage",
"decrementPercentage",
"setPercentage",
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "On/Off",
"WhatAmI": "light"
}
},
{
"applianceId": "33",
"manufacturerName": "TRX",
"modelName": "RFY",
"version": "Blinds Inverted",
"friendlyName": "Wintergarten vertikal",
"friendlyDescription": "RFY",
"isReachable": true,
"actions": [
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "Blinds Inverted",
"WhatAmI": "blind"
}
},
{
"applianceId": "460",
"manufacturerName": "TRX",
"modelName": "Alecto WS1700",
"version": "temp",
"friendlyName": "Wohnzimmer",
"friendlyDescription": "Temp + Humidity",
"isReachable": true,
"actions": [
"setTargetTemperature"
],
"additionalApplianceDetails": {
"WhatAmI": "temp"
}
},
{
"applianceId": "39",
"manufacturerName": "TRX",
"modelName": "Imagintronix",
"version": "temp",
"friendlyName": "Erdfeuchte Pflanzen DG",
"friendlyDescription": "Temp + Humidity",
"isReachable": true,
"actions": [
"setTargetTemperature"
],
"additionalApplianceDetails": {
"WhatAmI": "temp"
}
},
{
"applianceId": "36",
"manufacturerName": "TRX",
"modelName": "RFY",
"version": "Venetian Blinds US",
"friendlyName": "Charlotte",
"friendlyDescription": "RFY",
"isReachable": true,
"actions": [
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "Venetian Blinds US",
"WhatAmI": "blind"
}
},
{
"applianceId": "468",
"manufacturerName": "TRX",
"modelName": "Alecto WS1700",
"version": "temp",
"friendlyName": "Flur im DG",
"friendlyDescription": "Temp + Humidity",
"isReachable": true,
"actions": [
"setTargetTemperature"
],
"additionalApplianceDetails": {
"WhatAmI": "temp"
}
},
{
"applianceId": "491",
"manufacturerName": "Y-Hub",
"modelName": "RGBW",
"version": "Dimmer",
"friendlyName": "Schlafzimmer Nachtlicht",
"friendlyDescription": "Lighting Limitless/Applamp",
"isReachable": true,
"actions": [
"incrementPercentage",
"decrementPercentage",
"setPercentage",
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "Dimmer",
"WhatAmI": "light"
}
},
{
"applianceId": "236",
"manufacturerName": "FritzBox",
"modelName": "AC",
"version": "On/Off",
"friendlyName": "Anruf",
"friendlyDescription": "Lighting 2",
"isReachable": true,
"actions": [
"incrementPercentage",
"decrementPercentage",
"setPercentage",
"turnOn",
"turnOff"
],
"additionalApplianceDetails": {
"switchis": "On/Off",
"WhatAmI": "light"
}
}
]
}
}
Code: Select all
17:54:43
START RequestId: 87103a08-da82-11e6-9da3-3fb737760ad9 Version: $LATEST
START RequestId: 87103a08-da82-11e6-9da3-3fb737760ad9 Version: $LATEST
17:54:55
END RequestId: 87103a08-da82-11e6-9da3-3fb737760ad9
END RequestId: 87103a08-da82-11e6-9da3-3fb737760ad9
17:54:55
REPORT RequestId: 87103a08-da82-11e6-9da3-3fb737760ad9 Duration: 12433.59 ms Billed Duration: 12500 ms Memory Size: 512 MB Max Memory Used: 41 MB
REPORT RequestId: 87103a08-da82-11e6-9da3-3fb737760ad9 Duration: 12433.59 ms Billed Duration: 12500 ms Memory Size: 512 MB Max Memory Used: 41 MB
Any idea what I can do?
-
- Posts: 2260
- Joined: Monday 29 August 2016 22:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
Did you run the lambda function from US East (N. Virginia)? EU (Ireland) didn't work for me.
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
Yes, tried EU Ireland and N. Verginia. As I said, the Lambda test works and discovers my devices and I can see that searching the devices with the app results in a log entry for the Lambda function (also in EU). The alexa skill definitly triggers the Lambda function. The device dicovery takes 15s. Maybe that's a problem?
-
- Posts: 2260
- Joined: Monday 29 August 2016 22:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: RE: Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
The lambda test function indeed runs correctly in EU, but somehow the communication between Alexa Smarthome skill and a lambda function in EU goes wrong.Itschi wrote:Yes, tried EU Ireland and N. Verginia. As I said, the Lambda test works and discovers my devices and I can see that searching the devices with the app results in a log entry for the Lambda function (also in EU). The alexa skill definitly triggers the Lambda function. The device dicovery takes 15s. Maybe that's a problem?
Just to be sure (I've no other ideas): did you update the endpoint in the skill to the US East lambda function as well? And disabled and enabled the skill?
Verstuurd vanaf mijn SM-G800F met Tapatalk
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
What do I have to do to automatic start HA Bridge after reboot of my Pi?
These commands are used to start HA Bridge:
These commands are used to start HA Bridge:
cd habridge
sudo ./starthabridge.sh
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
It fails to return any devices if the last room in the plan has none. Temporary fix has it working locally; I'll follow up with a PR when I don't have to marshal children....
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
Hi Lokonli,
Yes, I change the endpoint as well and also disabled / enabled the skill. The only thing that is a bit wired is that in Virgina the Lambda logging doesn't work. It states "There was an error loading Log Streams.". That's why I don't see whether or not the Lambda function is really called like in EU. However, the Lambda test works in Virginia and EU but in Virgina it takes almost twice a s long.
Regards, Itschi
Yes, I change the endpoint as well and also disabled / enabled the skill. The only thing that is a bit wired is that in Virgina the Lambda logging doesn't work. It states "There was an error loading Log Streams.". That's why I don't see whether or not the Lambda function is really called like in EU. However, the Lambda test works in Virginia and EU but in Virgina it takes almost twice a s long.
Regards, Itschi
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
For me it works in the EU but although *testing* invocations take only 8s or so, the real invocations from Alexa to discover devices seem to take more than 20 seconds, and thus they time out and fail. I'm going to experiment with not using 'Connection: close', and more efficient ways to enumerate devices...
-
- Posts: 1571
- Joined: Friday 25 March 2016 17:43
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
Hi -
I feel i should defend the code and it's organic growth..
Originally, i was getting all devices, and depending on Type, discovering. PlanID isn't documented, and tbh I don't recall seeing it when I first started out on this. Whilst it is no doubt cleaner, as it's 1 API call, rather than several - i'm concerned at the time your discovery is taking, given I can discover 40 odd devices across several rooms in <5 sec via Alexa, so performance was acceptable, and the solution valid.
Saying that, happy with PlanID to be used as the control method, definitely easier to revert back to the original logic.
I feel i should defend the code and it's organic growth..
Originally, i was getting all devices, and depending on Type, discovering. PlanID isn't documented, and tbh I don't recall seeing it when I first started out on this. Whilst it is no doubt cleaner, as it's 1 API call, rather than several - i'm concerned at the time your discovery is taking, given I can discover 40 odd devices across several rooms in <5 sec via Alexa, so performance was acceptable, and the solution valid.
Saying that, happy with PlanID to be used as the control method, definitely easier to revert back to the original logic.
Native Alexa skill and Google app - register at https://www.controlicz.com - https://twitter.com/Controlicz
-
- Posts: 267
- Joined: Tuesday 14 January 2014 14:50
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Amazon Echo to Domoticz Bridge: switches, sensors & more
Hi. Just got my echo dot and would love to integrate it with my Domoticz. I have no programming skills whatsoever but I am pretty good at following instructions. I have been all through this thread and am still confused. Someone asked if there were any step by step instructions but I can't see any. Did anything come of this?
Running Domoticz on Pi3 with RFXtrx433e. LWRF power sockets and dimmer switches. Integrated my existing wirefree alarm PIRs and door contacts with domoticz. Geofencing with Pilot. Harmony Hub. Tado for Heating. Now playing with mysensors.
Who is online
Users browsing this forum: No registered users and 1 guest