Mycroft with Google AIY Voice kit disk image

Heja there,

was trying to bring up my voicekit with the picroft image too. What about an shell script with the needed steps on the enclosure-picroft grithub?

Also i cant get it to work on clean raspbian stretch. Guessing it has something to do with the new audio implementation of raspbian there?

best regards,
Markus

Though about that too. I made this image with the default jessie image mentioned here:
https://github.com/MycroftAI/enclosure-picroft/wiki/Script-for-building-Picroft-image

Updated the kernel, and took the steps are mentioned in the other thread here:
https://community.openconversational.ai/t/picroft-issue-with-pairing/2386

I also tried installing on stretch some time back, ran into some ssl problems in python. But even when I fixed those problems, one still has to deal with the fixed versions in the requirements.txt of mycroft. I ran into python problems and I could not get it working.

I didn’t even got that far! Was still trying to get output and input working on stretch.
On jessie i at last got all up and working… after a reboot i was back on output only. Currently trying out your image to figure out the errors.

hmm… in your image what aiyproject branch you are using?
also, i initialy used the prebuild mycroft image instead of building it freshly. There has to be some difference but i cant nail it.

Ah. I’m stopping that for today. Now i have everything up but mycroft isn’t resolving the intends while it’s hearing and translating me perfectly. #NotMyDay

I did a git clone of https://github.com/google/aiyprojects-raspbian
then sudo scripts/configure-driver.sh
and sudo scripts/configure-driver.sh

Hmmm, could be the modules not loading?

Also check the /boot/config.txt
I posted mine in the other thread,

So just the output is working right?

Starting with the default picroft, you should be able to do this:

# Install google AIY voicehat for use with mycroft 
# https://github.com/google/aiyprojects-raspbian/blob/voicekit/HACKING.md

#Install prereqs
sudo apt-get -y install alsa-utils rsync libttspico-utils ntpdate

#Clone git
git clone https://github.com/google/aiyprojects-raspbian.git voice-recognizer-raspi

#connect the hardware
cd /voice-recognizer-raspi
sudo scripts/configure-driver.sh
sudo scripts/install-alsa-config.sh
sudo reboot

#Update kernel version to 4.9
sudo apt-get update
sudo apt-get upgrade

sudo apt-get install rpi-update
sudo rpi-update
sudo reboot

# aplay -l and arecord -l should now both be seeing the voicehat

# load mic default

sudo vi /etc/modules
# /etc/modules: kernel modules to load at boot time.
#
# This file contains the names of kernel modules that should be loaded
# at boot time, one per line. Lines beginning with "#" are ignored

i2c-dev


sudo vi boot/config.txt

# Uncomment some or all of these to enable the optional hardware interfaces
dtparam=i2c_arm=on
dtparam=i2s=on
dtparam=spi=on

# Uncomment this to enable the lirc-rpi module
#dtoverlay=lirc-rpi

# Additional overlays and parameters are documented /boot/overlays/README

# Enable audio (loads snd_bcm2835)
#dtparam=audio=on
dtoverlay=i2s-mmap
dtoverlay=googlevoicehat-soundcard


sudo vi /etc/pulse/default.pa
uncomment and change:
load-module module-alsa-sink device="hw:0"
load-module module-alsa-source device="hw:0,0"

kind regards, Tjoen

Thx again. Will try it again. I used the voicemail branch while you’re using the master branch as it seems. Maybe that’s the problem.
Meanwhile I think there is definitely some issues with stretch and new audio implementation there. Raspbians docs are pretty detailed about those changes but hadn’t time to play around.
Any word from Mycroft team on that case?

I’m having some trouble with this image as well. I think the failure to identify intent has to do with the skills re-loading on boot. If you wait a few minutes for that to complete it seems to work fine.

I’m pretty excited about this and took some time to build one, flash the image over and test it out. I also added some vinyl stickers just for fun.

Works pretty well all in all.

Steve is looking at pulling support for AIY into Picroft Master so, hopefully, this will work out of the box in the next couple of weeks.

3 Likes

I installed MyCroft via the image above on my Google AIY Voicekit.
I got some “problems” understanding the activation code out of that what MyCroft did say.
Maybe for other new users it could be displayed on the console of the Pi?
I didnt see also the code if I did connect my Tablet to the Wifi-Accesspoint of MyCroft, because he brought me to the registering url on the web, but didnt fill in the code for himself :frowning:

But without installing any additionally skills (by now) it did work fine :slight_smile:

1 Like

Yes, loading the skills seems to take some time, and it also checks for updates on boot.
On the console you can see that happening.

Maybe it would be handy to have some "skills.loaded"
message so you show a visual cue with the button that all skills are loaded?

I now start the button with custom_setup.sh, which listens to the websocket.
I could then use the skills loaded message and change the button light indicating that it is ready and all skills have been loaded…

I love that fact that you build the device and tried the image!

And great news that Steve is going to look at AIY support!

kind regards, tjoen

Yes, I will look in to this some more. In some tests the wifi setup does not reboot. After a manual reboot, it does speak the code, but no indication on the terminal.

Not sure if the wifi setup also copies the registration code. I don’t think it does,

I always installed the skills with msm from the commandline, either through ssh or on the terminal.
That does actually work,

pi@picroft:~ $ msm install https://github.com/tjoen/skill-dutchradio.git
Searching for for 'https://github.com/tjoen/skill-dutchradio.git'...installing
Installing from: https://github.com/tjoen/skill-dutchradio.git
Cloning into 'skill-dutchradio'...
remote: Counting objects: 39, done.
remote: Total 39 (delta 0), reused 0 (delta 0), pack-reused 39
Unpacking objects: 100% (39/39), done.
Checking connectivity... done.
Installed: skill-dutchradio

You should be able to install new skills this way,

Hi tjoen,
I’m having issues unzipping the image file - keep getting CRC errors like the download is corrupt. Have downloaded several times :frowning: any chance you could post an md5 of the zip file or maybe double check the uploaded zip please?
Thank you in advance! am really looking forward to having a look at this!

Thank you for your work! :slight_smile:

1 Like

Ouch, sorry about that. I’ll check the zip, reupload and check the md5.
Give me about an hour, google drive upload is terribly slow.

Kind regards,
Tjoen

Uploaded the new image file. The MD5 checksum of the .img file is 06f45d0c3e1c1397c78aa0f1d02c38f8
Took about an hour and a half. Google throttles the upload to force you into a paid account, that’s evilcorp in action for you.

I might be a bit biased, our Youtube channel just got kicked out the partner program (again) for not having enough subscribers and hours viewed. Google seems be orchestrating a huge coverup to hide what’s happening, this blogpost gives you some more background info on this matter.

It surely made me see the real evilness of this huge company,
and the real need to move your data and services elsewhere fast.

Ah well, I will stop ranting now before they sue me. :wink:

Kind regards,
Tjoen

1 Like

Thank you so much!! I will be putting this on all my kits! :smiley:

2 Likes

Perfect, thank you! :smiley:

2 Likes

Here is a short video I put up on our YouTube channel.

Thanks.

3 Likes

Hey @tjoen this is great! I apologize if you already posted but I’m having trouble finding the github link for Picroft/AIY. I’d like to experiment with some of the new skills you added with the release.

Thanks for making this!

Hi @kaiservonarctic,

I wanted to make a repo for the aiy version, but support for the AIY will probably be incorporated in the picroft version soon, and I actually did not have time to set it up properly.

The skills however are all online:

sarcasm fallback skill - https://github.com/tjoen/fallback-sarcasm
dutch radio skill - https://github.com/tjoen/skill-dutchradio
better joke skill - https://github.com/tjoen/skill-better-jokes can now be installed through mycroft-skills
numbers skill - https://github.com/tjoen/mycroft-skill-numbers

The sonos chromecast streaming is not really a skill, but a python script. Still needs a wrapper to be started from mycroft.

Sonsos and Chromecast streaming - https://gist.github.com/tjoen/b503c4366803e21c809a929b8d183f99

The image backup script is not yet online, if your interested in that one, let me know, I will create a repo.

Currently making progress on a speechclient that adds a virtual character with mouthshapes, and working on a trivia skill, that does not work properly yet. I just had contact with a german dev, who lets us use his soccer api, so a soccer skill will probably be added in the near future.

I still have to add the skills to the official mycroft skills repo.

Kind regards,
Tjoen

2 Likes

Thank you for all your hard work. Thanks to you, in a few days when I get my Google AIY kit, I’ll have my first Mycroft device to assemble! I’ve been watching Mycroft for over a year, but now is a good time to get started. I plan to install Mycroft on my Linux Mint desktop, and Android devices.

1 Like