Mycroft Community Forum

Google AIY v1 with Mycroft 20.08-no mic

I am getting really confused and frustrated with this.

First, I cannot find any way of downloading and testing prior images to 20.08. I’m not sure if anyone is aware, but if you go to a previous Github release page and click on either the stable or unstable it always redirects to this current Picroft_v20.08_2020-09-07.img.

If I install this image I can run Picroft, but the mic does not work. It acts like it sees it, but the dB level is always stock at 7 or something. I did not install the AIY skillset at this point, and wasn’t able to get very far audio troubleshooting.

I then installed the current Google AIY voice image and the mic worked, but recorded in low audio. This proved to me that my mic is functional. When this Raspbian version completed its first system update the mic stopped working.

After these failed attempts, I installed this found in the forums: Mycroft with Google AIY Voice kit disk image . The mic worked just fine. Mycroft could hear and respond to me. I didn’t like the idea though, since it was based on the Mycroft 9.14 image and was 2 years old. Anyway, after I rebooted, this final Mycroft image decided to do a forced upgrade to 20.08. It was taking extremely long after the unpacking, so I just turned off the system and back on. At that point I had killed the installation.

So what gives?? I thought the AIY was confirmed as working? And I thought the AIY skill install for 20.08 would only be for the top button. Why is the mic not working in the newest release? And, should I just use this hacked release from the forums and give it more time to update?

I’d try and let the update complete. Stopping it certainly won’t leave it in a happy place, and seems to be the best option you have at the moment.

I don’t understand what that means. Are you saying that the newest release image doesn’t work with the AIY kit? I attempted to install it again and this time installed the skill. I used the command ‘msm install google-aiy-voicekit’. It acted like it installed but the light didn’t come on, and the mic still did not work.

I haven’t tried that particular combination recently, so I’m not entirely sure what to tell you about it. If I get a chance this weekend 'll try and load it up.

What files can I extract from the working 9.14 and copy to the 20.08? Obviously there is a .conf working in one and not the other. I figured I could extract the files from the old image, then edit them in the running new one.

I’ve opened an issue on the Github page. This is my current update to that issue:

After hours of troubleshooting, this might be the fix: https://github.com/google/aiyprojects-raspbian/issues/724

The new PulseAudio breaks the AIY drivers. Running the command in that post makes the mic work. I am still making sure everything else works. I wouldn’t call this fixed just yet.

2 Likes

Thx for investigating - by coincidence I reactivsted my AIY this evening and after working my way through the troubleshooting guide I found your post. Well i will reflash and try to run the fix
Is this the exact command you run :” sudo rm /lib/udev/rules.d/91-pulseaudio-rpi.rules” and how can I check that it was applied?
Cheers

1 Like

That is the command. I just rebooted and it worked.

And, in response to baconator’s first suggestion to let the hacked image wait and update; it doesn’t work. I attempted it, and it is stuck at ‘This is a major branch update, cleaning default skills’ for two hours. The official 20.08 release seems to be the only way to go, but I am still not 100% everything is working after running the pulseaudio command.

2 Likes

Well will give it a try after some hours of sleep :wink:

the “sudo rm /lib/udev/rules.d/91-pulseaudio-rpi.rules” did not work but when I rerun the setup wizard “mycroft-setup-wizard” in ssh and chose option 4 “4) Matrix Voice HAT.” and after several restarts it works with the latest image. Geat moment to see the mic levels change :wink:

Can someone please post the content of that “91-pulseaudio-rpi.rules” file?

Perhaps I can see what is wrong. The AIY v1 works perfectly with the latest linux kernel and pulseaudio on OpenVoiceOS (former MycroftOS).

All I have to do is add the “dtoverlay=googlevoicehat-soundcard” to config.txt and everything works… Perhaps I can see what they do differently in the lastest RaspberryOS.

@j1nx please take a look at this post I found:

The new RPI images break AIY voicehat with new PulseAudio settings. I might try downgrading like this person did. I am doing a fresh install using the recipe build method. If the mic works out of the box, then you’ll need to wait a few days before I break it with a sudo upgrade or something. I need to order another couple of microSD cards to copy my working install over to.

@j1nx where is the config file you are editing? Can you share any other modifications you made to get the AIY soundcard to work?

@j1nx This is what is in the 91-pulseaudio-rpi.rules file:

SUBSYSTEM!=“sound*”, GOTO=“end”
ACTION!=“change”, GOTO=“end”
KERNEL!=“card*”, GOTO=“end”
ENV{SOUND_FORM_FACTOR}!=“internal”, GOTO=“end”

ATTRS{id}==“b1”, ENV{PULSE_PROFILE_SET}=“rpi-hdmi.conf”, GOTO=“end”
ATTRS{id}==“b2”, ENV{PULSE_PROFILE_SET}=“rpi-hdmi.conf”, GOTO=“end”
ENV{PULSE_PROFILE_SET}=“rpi-analog.conf”

LABEL=“end”

And this is what is recommended to change:

SUBSYSTEM!=“sound*”, GOTO=“end”
ACTION!=“change”, GOTO=“end”
KERNEL!=“card*”, GOTO=“end”
ENV{SOUND_FORM_FACTOR}!=“internal”, GOTO=“end”

DRIVERS==“bcm2835_audio”, ATTR{id}==“b1”, ENV{PULSE_PROFILE_SET}=“rpi-hdmi.conf”, GOTO=“end”
DRIVERS==“bcm2835_audio”, ATTR{id}==“b2”, ENV{PULSE_PROFILE_SET}=“rpi-hdmi.conf”, GOTO=“end”
DRIVERS==“bcm2835_audio”, ATTR{id}==“Headphones”, ENV{PULSE_PROFILE_SET}=“rpi-analog.conf”, GOTO="end

LABEL=“end”

Right, it looks there is more going on then I thought.

With the new vc4 drivers they also use the new sound from linux instead of the firmware blobs. Hence the reason they configured the “rpi-hdmi.conf” profile.

As the AIY v1 looks like a copy of the old sound driver (sound_soc_simple) it looks like they push to much into that pulseaudio profile configuration.

Isn’t that updated 91-pulseaudio-rpi.rules you posted not working?

Changing the rules file has it working, but I can’t get my wake word to recognize.

EDIT: At first the wake word would not work, then I realized I needed to set it to Precise model.

Make sounds and check the mic monitor within the mycroft-cli-client

If it moves when making sounds, your mic is working.

Yes it’s working, but I am having a lot of trouble with the wake word. It defaults to sphinx on boot. When I type to switch to precise Mycroft hears my first command, then no other wake word commands afterward.

I am just trying to use the default ‘Hey Jarvis’.

Is this what should be after the command mycroft-config edit user?

{
“max_allowed_core_version”: 20.8,
“listener”: {
“wake_word”: “hey jarvis”
},
“hotwords”: {
“hey jarvis”: {
“module”: “precise”,
“sensitivity”: 0.5,
“trigger_level”: 3
}
}
}

Hi @nerlins

I’m not sure that there is an existing Precise Hey Jarvis wakeword trained, you will have to use PocketSphinx for that.

@goldyfruit Obviously there is a model, because it is in the account.mycroft.ai choices; along with hey Ezra, Christopher, and Hey Mycroft.

EDIT: unless those models are not Precise models. I’m just getting a handle on all of this.

I think I have figured it out. I was pronouncing the phoneme of Jarvis in my office, with Jarvis in my little shop room across the hall. He heard me. I’m slowly dialing the mic volume down in alsamixer, and I can walk closer and closer to him with wake word commands. Essentially, I had to be 20 ft away with the default settings for him to hear me clearly. This is still using the above .conf text from my earlier post.