Skip to content


Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

Google Assistant to work with respeakerd

Build Status Pypi

Adapt google assistant's gRPC sample app for working with respeakerd.

About Google Assisant Service

Please refer to Google Assistant's documentations.

Setup Guide

Configure a Developer Project and Account Settings

Please refer to here.

Register the Device Model

Please refer to here.

Install the SDK and Sample Code

In this step, it's a little bit different from the Google's guide. Since we will use the pydbus library, which depends on the gi.repository library, it's not easy to install gi.repository in a python virtual env. But the system of ReSpeaker has this library builtin. So here we're going to skip the python virutal env setup from the Google's guide.

sudo apt-get install portaudio19-dev libffi-dev libssl-dev
git clone
cd googleassistant_respeakerd
sudo python install
sudo cp script/io.respeaker.respeakerd.conf /etc/dbus-1/system.d/
# set respeakerd to pulse mode
sudo vim /etc/respeaker/respeakerd.conf 
# reboot to make it work
sudo reboot

# oauth
google-oauthlib-tool --scope --save --headless --client-secrets /path/to/credentials.json

You should see a URL displayed in the terminal:

Please visit this URL to authorize this application: https://...

Copy the URL and paste it into a browser (this can be done on any machine). The page will ask you to sign in to your Google account. Sign into the Google account that created the developer project in the previous step.

After you approve the permission request from the API, a code will appear in your browser, such as "4/XXXX". Copy and paste this code into the terminal:

Enter the authorization code:

If authorization was successful, you will see a response similar to the following:

credentials saved: /path/to/.config/google-oauthlib-tool/credentials.json

If instead you see InvalidGrantError, then an invalid code was entered. Try again, taking care to copy and paste the entire code.

Run the Sample Code

Please refer to here, except that you should replace the googlesamples-assistant-pushtotalk command with googlesamples-assistant-respeakerd. That is,

googlesamples-assistant-respeakerd --project-id my-dev-project --device-model-id my-model

Known Limits

  • Can not be interrupted (waked) when the assistant's speaking something


Adapt google assistant's gRPC sample app for working with respeakerd







No packages published