Whichever way you go you’ll need to use an older version of the Google Home app too, I set up Ha-Bridge today and used this link for the old apk http://www.apkmirror.com/apk/google-inc/google-home/google-home-1-19-29-release/google-home-1-19-29-android-apk-download/
Hi,
I have successfully setup Google Home app with emulated_hue I had to create a hue account and then paired to the Broadlink RM Pro.
I am using Google Home v1.24.37.7
Why do I need to use 1.19.29?
How do you setup HA-Bridge? what are the steps?
Thanks
Hi,
I like the idea of firing of scripts by Google Home voice commands, if I wanted to perform the following with script(s) what would I do:
Turn Boys Aircon on
Turn Boys Aircon off
Can you provide an example of the script that would do this I suppose would need to include a state flag to determine if I have already issued the command to determine if the aircon is already on or off?
The configuration.yaml file I have at present with emaulated hue and broadlink as follows:
switches:
boys_aircon:
friendly_name: “Boys Aircon”
command_on: ‘JgBAAAABF4oSNRISExETEhE1EhITERMREhISExESExESEhIRExESEhI2EhISERM1EhISEhI1EhISNhISEjUSNhIADQUAAAAAAAAAAA==’
command_off: ‘JgBAAAABFosTNBISEhMREhI1EhISEhISEjUSNhISEhISEhISEhESEhISEhISEhISExESNRITETYTERIRExESNhIADQUAAAAAAAAAAA==’
For that you already have a switch. No need for a script. Once you have installed the Ha Bridge add on…
Open the Ha-Bridge web interface.
Click on the Bridge Control Tab
Scroll down and add your Hass Server details.
Save
Go to the new HomeAssistant Devices Tab
Add devices… Save and go to Bridge devices tab to test.
Thanks how do I install HA Bridge on Hass.io? sorry I am getting more familiar each hour but cant find how to install.
Took me a lot more than a few hours to get as far as you have so well done. First you need to add this repository.
Instructions are in the first post of thread.
Then you will see it listed with the other hassio addons
Thanks, glad I am making good progress. I hit a road bump, I have installed HAbridge, removed the emulated_hue code from the configurations file so only got broadlink. I went into the HAbridge web UI now I am stuck.
Where do I go to add the disable discovery?
discovery:
ignore:
- philips_hue
What do I do next? when I go into Google Home to add devices I don’t see HAbridge?
I feel like I am going backwards from where I was with emulated_hue but I am sure I just need to do a few more things but what?
Please help.
In your configuration.yaml just put
discovery:
ignore:
- philips_hue
Doesn’t matter where.
Once you have configured and tested a device as working, like say a simple light you will probably need to unlink the hub you linked earlier. I reinstalled habridge today and had to unlink my previous philips hue hub in the google home app before I could add the new one.
Okay fell like I am starting to get back on track:
Q - Do you have to restart HA everytime you update the configuration.yaml?
Sorry looking back at your post:
Do you mean the section: HomeAssistant Names and IP Addresses?
If so what do I put in Name? I have installed hass.io vanilla.
What do I choose for Dim Controls currently set to none do I change this to pass thru?
I have managed to get through with name HomeAssistant and added and tested the three switches.
I unlinked as you said which worked but there is 6 devices switch.boys_aircon x2 switch.boys_foxtel and 2 x switch.boys_tv
Why is this? is it one for on and one for off?
How do I delete these and start again?
Thanks for your help I think I am getting close.
Edit: Sorry I assume I select Philips Hue in Google Home and pair which works. Then I get double ups.
Yes. You can sometimes do this from the configuration tab and just reload core.
You can put whatever you want in name, useful if you have multiple home assistant setups, which I do but am testing hassio at the moment. Here’s mine currently.
On the devices tab where you can click test and edit you can also delete. I don’t know why you have two for each, what happens when you test them in the tab? You can also rename them, and this name is what you will use to call your action. Turn on ‘boys aircon’ is a lot easier to say than turn on ‘switch dot boys underscore aircon x two’.
Thanks.
The name thing is good.
I have renamed in HAbridge which is okay, I have two for each in Google Home. If I leave them alone and ask Google to Turn Boys Aircon On, it says sorry I do not know which one you want. If I go into each and give a different nickname for example Boys Aircon and Boys Aircon 2 and I say to Google Home Turn on Boys Aircon it works.
How do I delete a device from Google Home?
Edit: What I have done does not work, now if I say google turn on boys aircon 2 it does not first time but then I repeat and it works. (I think this is because I have two devices). I say google turn off boys aircon 2 it does not work first time as it says it does not know which one to choose. Then I repeat google turn off boys aircon 2 and it works.
The problem is that I have duplicate devices in Google Home? I might try to uninstall then re-install as I cannot seem to delete the duplicates.
Are there duplicates due to the on and off switch in the configuration.yaml?
I don’t know sorry, don’t have an aircon. If you unlink the hue in the google home app it should delete devices. Is it possible you still have emulated hue running as well as habridge?
Hi
Sorry did not get back to you it was late. How do I uninstall emulated_hue?
Something slightly different. Is it possible to combine more than one ir command together?
I want boys tv to switch on and change source to be hdmi 3 which is 5 remote button presses.
Where do I go to create a script and do you know how to code a toggle variable?
Made some awesome progress in a short space of time yesterday thanks to your help cheers.
Hi, when you installed Google Home 1.19.29 did it force you to upgrade to newest version mine did !!!
Defeats the purpose of installing an older version if the app forces you to newest. This happend when I went into Google Home device settings.
Did you get this?
Go to play store on your device.
Go to settings.
Adjust auto update apps to not auto update.
Uninstall new home app, reinstall old app.
I use an older device for this stuff and use the newer apps on my phone, I have been having compatibility problems with a few things since putting Android 8 on my phone.
Late for me too, I typed that on my phone in bed. To uninstall you just open your configuration.yaml and comment out the emulated hue section and restart hass. You can delete it entirely or put a # in front of it so it gets ignored.
# emulated_hue:
# host_ip: 192.168.1.7
# listen_port: 80
# emulated_hue 1:
# type: alexa
If the service has toggle, like the light component you put that in the action of your automation…
action:
service: light.toggle
entity_id: light.bedroom_ceiling
For scripts see…
For use with voice you would create two different scripts and map one script to the ON call and one script to the OFF call, a script is simply run, it doesn’t get turned off. So for your TV setup you would probably need to run a sequence of actions to turn on, change input etc and have delays if needed. I use a harmony remote so haven’t ventured into this.
As an example of another way to do things here is an automation I have for turning my yamaha AV reciever on and changing to the correct input automatically if my chromecast starts playing something.
- alias: khonsu begins playing
trigger:
- platform: state
entity_id: media_player.khonsu
to: 'playing'
from: 'idle'
- platform: state
entity_id: media_player.khonsu
to: 'playing'
from: 'off'
- platform: state
entity_id: media_player.khonsu_2
to: 'playing'
from: 'idle'
- platform: state
entity_id: media_player.khonsu_2
to: 'playing'
from: 'off'
action:
- service: media_player.turn_on
entity_id: media_player.kitchen_avr
- service: media_player.select_source
data:
entity_id: media_player.kitchen_avr
source: AUDIO1
Great lots to absorb here I will read the script syntax first wont get anywhere without this.
Just want to check the workflow for HAbridge versus Emulated_hue:
- HAbridge:
- Add device in configuration.yaml under broadlink / switch with on and off ir codes (this is for HA to communicate with broadlink) makes availble manually in state section of HA.
- Build HA device configure as required (add multiple in one if required Boys TV and Boys Foxtel together) and update bridge (this makes devices visible to Google Home?)
- Google Home app add device and nickname (used for voice command? or is it the name of the HAdevice in Bridge that Google Home uses?)
- Emulated_hue: (uninstall HABridge addon)
- Add device in configuration.yaml under broadlink / switch with on and off ir codes (this is for HA to communicate with broadlink) makes availble manually in state section of HA.
- Enable Emulated_hue in configuration.yaml
- How do I create a script that for example turns on Boys TV and Boys Foxtel at the same time and associate it with HA so that it is available to Google Home? how does it work?
- Does the script then call what is in configuration.yaml that then passes it to Broadlink RM Pro?
Just can’t get me head around the Emulated_hue end to end approach?
I’m not really sure about most of that. I don’t use emulated hue.
For almost everything I build the switch or script in home-assistant. The exceptions are non home assistant things, like my harmony bridge which allows me to call an activity much like your tv, foxtel input setup.
So,for your activity first you need to be able to turn on the TV. Work that out. You will need to enable the specific component that works with your TV. This will come under media_player.
Then you need to turn on foxtel. Work that out. Also media_player? Or maybe you will need some sort of remote like a harmony or rf to reach it? Search forums for foxtel perhaps.
Then you need to select the correct inputs. Work that out. Media-player services.
Once you have all the pieces you can then call them in sequence with a script or automation.
Until you have each device available as a component in hass and can control it you can’t even begin to pass this control on to google home.
Ha-Bridge can then pull the info required for light, switch, script and so on directly from hass and very little is needed to be done to expose these as Hue light switches to google home or alexa.
The name you call each device in habridge is what google will pull the device in as. I have never used google nicknames so am unsure. You can do this same thing with Emulated hue.
I think you can use both ha-bridge and emulated hue at the same time but google home requires port 80, alexa uses different ports. I don’t think both emulated hue and habridge can use port 80. The docs for emulated hue would be worth reading through as well as all the threads on here.
For your specific devices I would search the forums for these and see what other people have done as well as read the component instructions. You want these working in Hass first.
And lastly I’m not sure but it sounds like you are trying to leap into the deep end. It would be worthwhile doing some basic automation’s and so on first to connect all the dots. Take it slowly and build everything up. A great resource here are the examples people have shared on git hub, even sharing their entire configuration setups.
Great thanks I will have a read through thanks VERY much for your guidance.
In the script syntax section is does not really say in laymans terms what a service is and why to use it?
To acelerate my learning, can I walk an Automation example through with you:
- When my mobile (for example is 192.100.100.2) is in range of wifi turn on boys aircon if boys aircon is not on already.
I have added device tracker to configuration.yaml but what do I do next?: I have ‘the boys aircon’ in HAbridge:
device_tracker:
- platform: nmap_tracker
hosts: 192.100.100.1/24
home_interval: 10
What do I add next?
Cheers
Each domain has corresponding services. See here https://home-assistant.io/docs/automation/
So the domain is the component part but at the top of the hierarchy, for example I have three different types of lights. The domain is light. But I have limitlessled, lifx and xiaomi lights which all have different abilities.
The light domain allows for the services ‘turn_on’ , ‘turn_off’ , and ‘toggle’ on all of these.
In an action part of an automation you define the service call as domain.service
action:
service: light.turn_on
entity_id: light.foyer
See https://home-assistant.io/components/light/
If you click on the little remote looking icon at the bottom of the hamburger menu you can explore the domains and services you have available. It will also show additional data commands you can send along with the call.
Would be well worthwhile following some basic tutorials to get the gist. Bruh automation on you tube has a lot of this stuff covered in easy to follow tutorials with examples. https://www.youtube.com/channel/UCLecVrux63S6aYiErxdiy4w
This is SO exciting stuff. Okay things are starting to make a bit more sense.
To really get it can you show me the end to end code syntax and where it is located for example:
For above: can you show me your configuration.yaml to follow the syntax for this.
Next:
Above: did you create the service to turn on, off etc or are these out of the box where are they located in configuration.yaml?
Next:
Above: where do you set the entity_id, surely light.foyer must resolve to an ip adress or something?
Once I get it I think it will prepare me to think through how it all hangs together, at the moment I am trying to stitich it together and need an end to end walkthrough with literal syntax and where to put the code.
Sorry this must be tedious for you but you are really helping me accelerate my practical learning.