Skip to main content

Getting to Know the ReSpeaker 6 Microphone Array Kit

top7_9121803298176d2ff1e3c5906c931ff1d27d6dd4.jpg

Setting up the Raspberry Pi HAT and recording using the 6 microphones.

Seeed’s ReSpeaker 6-Mic Circular Array Kit (179-3744) is an extension board or “HAT” designed for Raspberry Pi. It's a circular microphone array kit and comes with six microphones in a format that is designed for AI and voice applications.

box3_181b19c7efd8152a934b2cc7d7d768cddc74d7c0.jpg

It comes neatly packaged in its box and consists of two boards; one is the voice accessory HAT, while the other hexagonal board houses the six microphones in a circular array. It supports 8 input channels: the 6 input channels for microphone recording and 2 channels that are echo channels of playback. Although it lists 8 output channels, only 2 are functional and the others Seeed describe as dummies

The specifications are listed as:

  • 2x X-Power AC108 ADC
  • 6x high-performance microphones
  • 1x X-Power AC101 DAC
  • Voice output:
    • 3.5mm headset audio jack
  • Speaker jack
  • Compatible with Raspberry Pi 40-pin headers
  • Microphones: MSM321A3729H9CP
  • Sensitivity: -22 dBFS (Omnidirectional)
  • SNR: 59 dB
  • Max Sample Rate: 48Khz

 

Connecting the Kit to a Raspberry Pi

putting-together1_5a9c89267508c144db66cdb8b3c23e5969dbd7b0.jpg

My first job was to connect the HAT to a Raspberry Pi. This entailed connecting the HAT to the microphone array using the supplied ribbon cable and then plugging the HAT into a Raspberry Pi via the 40-pin GPIO.

I wanted to make a little stacked unit of all the parts so this is how I went about it:

putting-together2_1e642e5cd63f25c587a76897c7281ee2e41628c2.jpg

I discovered that because the stand-offs are right up against the I2C and GPIO connectors on the upper side of the Mic Array HAT, therefore cannot be rotated to screw them in place. So I needed to fix them first, rather than attaching the stand-offs to the Pi first as I had done initially. Once they are in place the board can be gently squeezed onto the 40 pin GPIO header of the Pi, before being secured with screws or in my case some short stand-offs.

putting-together31_6d72bf0fbbbd75968a153d39b5ca70f0a58569c5.jpg

The hexagonal microphone array board is connected to the HAT with the supplied ribbon cable, taking care to attach the cable the right way round — blue side up in both connectors! I then fixed the array board in place on the stand-offs, over the HAT, using the supplied nylon screws.

Once that was done and a Micro SD with the latest Raspian OS installed was inserted in the Pi, I powered it up.

Connecting to the Raspberry Pi

seeed_mic_array_putty_dcaada1a05271cf628d930e0e93aaa55199b7e76.png

As I am short of space on my home workbench I wanted to connect to the Raspberry Pi from my laptop, rather than taking the more straight forward route of that connecting the Pi to a monitor, keyboard and mouse. Luckily I had already set up the wireless connection and enabled SSH on the copy of Raspian I was using, otherwise, I could have temporarily used a monitor and keyboard.

I am using a laptop running Windows 10, so I installed PUTTY for Win 10 64-bit after downloading.

pi_log_in_287fbbee4f171ac96596fdec46221f67a7fac373.png

I got the IP address of the PI by running Angry IP Scanner on my laptop and could then connect to the Pi using my recently installed copy of Putty, with the default username of “pi” and the password that I had changed from the default of “raspberry” when setting up SSH and wireless connection earlier.

Installing the Seeed sound card software

The sound card software and necessary Linux kernel drivers need installing. This can be done from the command line, logged into the Raspberry Pi using Putty, by typing the following:

sudo apt-get update
sudo apt-get upgrade
git clone https://github.com/respeaker/seeed-voicecard.git
cd seeed-voicecard
sudo ./install.sh 
sudo reboot


That final line obviously rebooted the Pi, so I waited for it to restart, logged back in with Putty and checked the sound card input was working by typing the following:

pi@raspberrypi:~ $ arecord -L

This is what I saw:

pi@raspberrypi:~ $ arecord -L
null
Discard all samples (playback) or generate zero samples (capture)
default
ac108
dmixer
ac101
sysdefault:CARD=seeed8micvoicec
seeed-8mic-voicecard,
Default Audio Device
dmix:CARD=seeed8micvoicec,DEV=0
seeed-8mic-voicecard,
Direct sample mixing device
dsnoop:CARD=seeed8micvoicec,DEV=0
seeed-8mic-voicecard,
Direct sample snooping device
hw:CARD=seeed8micvoicec,DEV=0
seeed-8mic-voicecard,
Direct hardware device without any conversions
plughw:CARD=seeed8micvoicec,DEV=0
seeed-8mic-voicecard,
Hardware device with all software conversions


Which shows everything is working as it should.

Similarly, I tested the output:

pi@raspberrypi:~ $ aplay -L

Which resulted in the following:

pi@raspberrypi:~ $ aplay -L
null
Discard all samples (playback) or generate zero samples (capture)
default
ac108
dmixer
ac101
sysdefault:CARD=ALSA
bcm2835 ALSA, bcm2835 ALSA
Default Audio Device
dmix:CARD=ALSA,DEV=0
bcm2835 ALSA, bcm2835 ALSA
Direct sample mixing device
dmix:CARD=ALSA,DEV=1
bcm2835 ALSA, bcm2835 IEC958/HDMI
Direct sample mixing device
dsnoop:CARD=ALSA,DEV=0
bcm2835 ALSA, bcm2835 ALSA
Direct sample snooping device
dsnoop:CARD=ALSA,DEV=1
bcm2835 ALSA, bcm2835 IEC958/HDMI
Direct sample snooping device
hw:CARD=ALSA,DEV=0
bcm2835 ALSA, bcm2835 ALSA
Direct hardware device without any conversions
hw:CARD=ALSA,DEV=1
bcm2835 ALSA, bcm2835 IEC958/HDMI
Direct hardware device without any conversions
plughw:CARD=ALSA,DEV=0
bcm2835 ALSA, bcm2835 ALSA
Hardware device with all software conversions
plughw:CARD=ALSA,DEV=1
bcm2835 ALSA, bcm2835 IEC958/HDMI
Hardware device with all software conversions
sysdefault:CARD=seeed8micvoicec
seeed-8mic-voicecard,
Default Audio Device
dmix:CARD=seeed8micvoicec,DEV=0
seeed-8mic-voicecard,
Direct sample mixing device
dsnoop:CARD=seeed8micvoicec,DEV=0
seeed-8mic-voicecard,
Direct sample snooping device
hw:CARD=seeed8micvoicec,DEV=0
seeed-8mic-voicecard,
Direct hardware device without any conversions
plughw:CARD=seeed8micvoicec,DEV=0
seeed-8mic-voicecard,
Hardware device with all software conversions

Again, everything was OK so I was ready to try recording.

Install Audacity with the mic array

Audacity_Pi_recording_27903b1fb8055415fa02ea2d03cf33b5b7550b57.png

I use Audacity as an audio editor in Windows, OS X and Ubuntu, so as I am familiar with this, it seemed a good option to install it on the Pi and try it out with the Mic Array.

It was simple enough to install from the command line:

sudo apt update

sudo apt install audacity

audacity // run audacity

Once Audacity was installed I used VNC to run it so I could see what I was doing. Luckily I had already installed VNC when I was setting up the Pi TV. Once installed Audacity appears under Sound & Video in the Pi’s applications menu.

seeed_mic_array_audacity_settings1_392d4f5e835a7c33aee10939a7a5ba7e046eae6d.png

I select the Mic array as both the recording and playback device in Audacity’s and once I clicked the record button I could see it was recording. I could use Audacity’s Export option in the File menu to save the recording as an MP3 (or other audio formats if I preferred) or save it as an Audacity Project so I could work on it later on one of my other PCs.

Conclusion

The Mic Array seems primarily aimed at voice-controlled applications such as Alexa, Google assist and the like, but I am not really interested in that. I would like to try out Sound Source Localization and Tracking, but was unable to get the ODAS software working on my setup – although I will keep trying as that seems a fascinating avenue to explore. In the meantime I intend to try it out with some field recordings to incorporate into some of my music projects – I just need it to stop raining!

I have a background in the arts, environmental conservation and IT support. In my spare time I do a bit of DJing and I like making things.
DesignSpark Electrical Logolinkedin