Due to high demand expect some shipping delays at this time, orders may not ship for 3-4 business days. On MLK Day no orders will be shipped.
0

Adafruit Voice Bonnet - Input and Output at the same time?
Moderators: adafruit_support_bill, adafruit

Forum rules
Talk about Adafruit Raspberry Pi® accessories! Please do not ask for Linux support, this is for Adafruit products only! For Raspberry Pi help please visit: http://www.raspberrypi.org/phpBB3/
Please be positive and constructive with your questions and comments.

Adafruit Voice Bonnet - Input and Output at the same time?

by Bortus on Wed Nov 24, 2021 10:43 am

Hello there!

Is it possible to simultaneously record audio through the board's microphones and output it through the JST 2PH connector?
I plan to use the board for a DIY intercom system.

Thanks
Bortus

Bortus
 
Posts: 2
Joined: Wed Nov 24, 2021 10:37 am

Re: Adafruit Voice Bonnet - Input and Output at the same tim

by mikeysklar on Fri Nov 26, 2021 2:33 pm

Bortus,

Good question. I cannot say that it work to record and playback audio simultaneously. The datasheet and guide do not mention this scenario.

https://cdn-learn.adafruit.com/assets/a ... 1603825540

The input and output would all be going over i2s through the same CODEC.

You could try something like these command running at the same time.

Code: Select all | TOGGLE FULL SIZE
arecord --device=hw:1,0 --format S16_LE --rate 44100 -c1 test.wav


Code: Select all | TOGGLE FULL SIZE
aplay -D plughw:1,0 test2.wav

Should playback be an issue you could use the Pi built-in 1/8" jack or HDMI audio output.

mikeysklar
 
Posts: 6487
Joined: Mon Aug 01, 2016 8:10 pm

Re: Adafruit Voice Bonnet - Input and Output at the same tim

by Bortus on Tue Nov 30, 2021 11:09 am

Thanks for the reply!

So I tried the following command (bonnet needs to be the default device or otherwise specified):

Code: Select all | TOGGLE FULL SIZE
arecord -f cd | aplay


This works. Everything that is being picked up by the microphones is played back throught the speaker.

Bortus
 
Posts: 2
Joined: Wed Nov 24, 2021 10:37 am

Re: Adafruit Voice Bonnet - Input and Output at the same tim

by mikeysklar on Tue Nov 30, 2021 4:18 pm

oh cool, thanks for sharing the syntax to record and pipe the audio through a speaker.

mikeysklar
 
Posts: 6487
Joined: Mon Aug 01, 2016 8:10 pm

Please be positive and constructive with your questions and comments.