In the training session, we are collecting the voices of ON and OFF which are used to develop the codebook for recognition. The audio captured from the microphone connected to the BeagleBoard is saved to the MATLAB workspace for pattern analysis and pattern code generation.
As shown in the following screenshot, a Simulink model VocRcgBB_Trn.mdl
has been developed for training and creating the code book. The ALSA Audio Capture block is configured to a sampling frequency of 22050 Hz and sends out the stereo audio data in a 2205 x 2 frame of 16-bit integers at interval 0.1 s. For floating point processing, the Normalize block converts the captured two-channel audio data (a 2205 x 2 integer matrix) into single-channel double data (a 2205 x 1 double vector).
The rest of the model consists of the following function blocks:
The buffer block (highlighted by a red circle numbered 1) is configured to buffer size 22050 and buffer overlap 9*2205. This...