Clearing input buffer before capturing new data
- Lenguaje dominante
- Jupyter Notebook
- Estrellas
- 15.1k
- Forks
- 1.8k
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Descripción
Hi,
I am working on a project that uses ALSA to capture words and phrases from a microphone which is then passed onto Vosk-Api (in c) to convert into text. This is working very well and I am impressed on the accuracy of the conversion. I then take the result of the conversion and output appropriate message via a speech synthesiser.
I assumed that any new spoken phrases would not be captured until I issued the next snd_pcm_readi(handle, buffer, frames); call. But what seems to be happening is while the first phrase is being processed and the message spoken, ALSA is still capturing spoken data via the microphone. This means that some of the spoken speech from the synthesiser is being captured via the mic and causing a feedback loop!
Is there a way of flushing / deleting unprocessed data in the input buffer before start a new phrase capture?
Thanks you for any help you can give.
Ernie
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Evaluación
Este issue todavía no se ha evaluado.