Control light from Google Home with Node RED

Hello

I am new to the party...
My question is : Can i control a Light with Node RED which is connected in the Google Home app ?
I found much stuff about controlling lights in Google Home which are connected in the Node RED, but nothing in the other direction.

Thx in advance

Hi,
Normally you're controlling the light direct and not over google home.
What kind of light do you want to control?

No, Google do not offer any API that would let you do this

My workaround for Alexa is to use a Pi to speak to a spare Alexa device
Same approach should work for Google Home setups I'd thought

https://simplesi.net/control-any-alexa-device-using-node-red/

Not sure if you know about the 'textCommand' in the Alexa Routine node ?

inject what you would otherwise say as plain text, and Alexa will do it :wink:

I didn't until recently but unfortunately (like all of these Alexa/Google home things) it has issues.

Actually getting a Pi to speak a command has been working very reliably

Except if loud background noise when speaking of course :slight_smile:

I Must get round to putting it in the cupboard under the stairs :slight_smile:

Make a small anechoic chamber with egg boxes :wink:

3 Likes

Thx for all ideas.
I saw a way with smart home i will try it!

@DeWoAlliSeged7 - Could you explain in a little more detail what you are trying to achieve, giving an example would help.
Also, what are you using to switch the lighting... A Shelly, sonoff or something else?

I successfully control lighting using either voice commands or by commands issued by node-RED flows, using node-red-contrib-google-smarthome

I have a switch named Elesion: Luminea Home Control Lichtschalter: 4er-Set WLAN-Lichttaster, App, komp. zu Siri, Alexa, Google Assistant (Smart Home Lichtschalter)

The switch is connected with the Elesion App and with Google Home.

I would like to controle the switch with a node red command.

There isn't a lot of information in the link, but it does say "Also relevant or suitable for: TUYA", so if it is, you could;

  1. disable the google home connection to the switch
  2. send/receive switch commands from/to your node-RED flow using node-red-contrib-tuya-smart-device
  3. install node-red-contrib-google-smarthome and also build that into your node-RED flow to handle voice commands

Then you could control the switch by voice using google smarthome > tuya node > switch and programmatically by node-RED > tuya node > switch

2 Likes

Thx i can connect!
I have to figure out how to turn it on and off but i connected! THX!

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.