Weekly Status Report #9: 11/17

Bobbie

Done this week

This week I worked on getting SDW-MWF to work with the Teensy Audio library. This required changing many constants like the buffer length in each audio frame. However, this ran into problems (segfaults) when I tried to actually integrate it. I spent a good amount of time trying to debug the generated C code (from Matlab Coder), when Professor Sullivan suggested just rewriting it directly.

So I rewrote the code for the Teensy Audio library as a new object (mwf.h and mwf.cpp). This also required implementing a voice activity detector, which I did using the algorithm described in “A Simple But Efficient Real-time Voice Activity Detection Algorithm” (Moattar and Homayounpour, 2009). I tested the voice activity detector against some WAV inputs, and it appears to work with good accuracy. The main time spent here was learning the bit of C++ needed to integrate with the library, and familiarizing myself with the CMSIS DSP Software Library (“arm_math.h”), which is a DSP library optimized for the ARM architecture. For example, a few times I wrote a loop to calculate some simple property like the mean, only to find that I could have just called arm_max_q15(buf, len, &max_size).

I also talked to Kevin about material choice for the microphone rig and decided on mounting the microphones to Lexan polycarbonate, as a material which is strong, stiff and slightly flexible. This is decided over acrylic because it will not shatter under load, and over wood because it stronger. We also decided against 3D-printed ABS because it is less flexible, and our geometry is not complex enough to warrant the time and expense.

Goals for next week

  • Acquire scrap Lexan from my shop and cut/drill it to the sizes we need
  • Work with Sean to get the 4-mic input to the MWF working on the Teensy board

 

Kevin

Done this week

This week I worked on converting the MATLAB code for beamforming to C code.  I am currently working on a delay sum beamformer for our microphone array.  I am still currently working on a working C implementation partially delayed because this weekend was spent in Ohio.  I currently have code for microphone array initialization and microphone delay calculations.  I have added screenshots of sample code below.

Goals for next week

  • Frostbeamforming code conversion to C-code
  • Finish building microphone array on test environment
  • Test microphone inputs on frost beamformer

Sean

Done this week

I received and tested the PDM microphones this week, but unfortunately translating the data uses too much CPU power. Reading from 1 mic used about 37% CPU and 2 mics used 81%, so we won’t be able to translate data from 4 microphones and process all the audio. Therefore, we’re going forward with using I2S communication via the Teensy audio shields. I found some left/right mono to stereo audio adapters, as well as a microphone/ headphone splitter so we can record and output data on the same I2S port. This setup will allow us to have 4 input and 1 output with only 2 audio shields attached to the Teensy.

I rewrote my Teensy startup code to take in I2S inputs and connect to an empty filter, which will eventually become Kevin’s and Bobbie’s algorithms.  I also implemented a simple program that records for 5 seconds, then plays that audio back. I am using this to test different microphone setups.

Goals for next week

Next week, I want to build the mic setup and test multiple input and single output via I2S. I hope Bobbie and I will be able to implement and test his noise cancelling algorithm on the Teensy board. We will initially try this with only one microphone input.

Leave a Reply

Your email address will not be published. Required fields are marked *