diff --git a/google_assistant/CHANGELOG.md b/google_assistant/CHANGELOG.md new file mode 100644 index 0000000..6e78532 --- /dev/null +++ b/google_assistant/CHANGELOG.md @@ -0,0 +1,7 @@ +# Changelog + +## 1.0 +- Update Google Assistant SDK 0.4.4 +- Update Google Assistant Library 0.1.1 +- Use new Hass.io Audio System +- Use now a ubuntu based image diff --git a/google_assistant/Dockerfile b/google_assistant/Dockerfile index 837696f..9f1403b 100644 --- a/google_assistant/Dockerfile +++ b/google_assistant/Dockerfile @@ -13,7 +13,6 @@ RUN apt-get update \ # Copy data COPY run.sh / COPY *.py / -COPY asoundrc /root/.asoundrc RUN chmod a+x /run.sh diff --git a/google_assistant/asoundrc b/google_assistant/asoundrc deleted file mode 100644 index 21e0a3f..0000000 --- a/google_assistant/asoundrc +++ /dev/null @@ -1,17 +0,0 @@ -pcm.!default { - type asym - capture.pcm "mic" - playback.pcm "speaker" -} -pcm.mic { - type plug - slave { - pcm "hw:%%MIC%%" - } -} -pcm.speaker { - type plug - slave { - pcm "hw:%%SPEAKER%%" - } -} diff --git a/google_assistant/build.json b/google_assistant/build.json index 73a1107..af48e00 100644 --- a/google_assistant/build.json +++ b/google_assistant/build.json @@ -1,6 +1,6 @@ { "build_from": { - "armhf": "multiarch/debian-debootstrap:armhf-stretch", - "amd64": "multiarch/debian-debootstrap:amd64-stretch" + "armhf": "multiarch/ubuntu-core:armhf-xenial", + "amd64": "multiarch/ubuntu-core:amd64-xenial" } } diff --git a/google_assistant/config.json b/google_assistant/config.json index b460279..bcc8797 100644 --- a/google_assistant/config.json +++ b/google_assistant/config.json @@ -1,6 +1,6 @@ { "name": "Google Assistant", - "version": "0.0.3-p5", + "version": "1.0", "slug": "google_assistant", "description": "A virtual personal assistant developed by Google", "url": "https://home-assistant.io/addons/google_assistant/", @@ -8,19 +8,15 @@ "boot": "auto", "arch": ["armhf", "amd64"], "map": ["share"], - "devices": ["/dev/snd:/dev/snd:rwm"], + "audio": true, "ports": { "9324/tcp": 9324 }, "webui": "http://[HOST]:[PORT:9324]", "options": { - "mic": "0,0", - "speaker": "1,0", "client_secrets": "google_assistant.json" }, "schema": { - "mic": "str", - "speaker": "str", "client_secrets": "str" }, "image": "homeassistant/{arch}-addon-google_assistant" diff --git a/google_assistant/run.sh b/google_assistant/run.sh index cdd1e8c..a23d80b 100644 --- a/google_assistant/run.sh +++ b/google_assistant/run.sh @@ -6,15 +6,6 @@ CLIENT_JSON=/data/client.json CRED_JSON=/data/cred.json CLIENT_SECRETS=$(jq --raw-output '.client_secrets' $CONFIG_PATH) -SPEAKER=$(jq --raw-output '.speaker' $CONFIG_PATH) -MIC=$(jq --raw-output '.mic' $CONFIG_PATH) - -echo "[Info] Show audio device" -aplay -l - -echo "[Info] Setup audio device" -sed -i "s/%%SPEAKER%%/$SPEAKER/g" /root/.asoundrc -sed -i "s/%%MIC%%/$MIC/g" /root/.asoundrc # check if a new assistant file exists if [ -f "/share/$CLIENT_SECRETS" ]; then