Implement audio streaming #8
Reference in New Issue
Block a user
Delete Branch "feat/stream-audio"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Adds the
AudioSender, which is used inmainto send audio. It lives on a separate thread and sends its audio data asynchronously over a dedicated ZeroMQ socket.Microphone utilities are added to
utils.microphone, of which only the default microphone utility is used. The interactive utility could easily be swapped in instead.Adds unit and integration tests for all new code, with 100% line coverage.
To test:
assigned to @0950726
requested review from @8464960
marked the checklist item Unit tests pass (run as described in the README) as completed
marked the checklist item Run main, notice that it says "Listening with microphone ..." as completed
marked the checklist item Run the below script while main is running. You should see (for 10 seconds) bars indicating the microphone level as completed
marked the checklist item Code follows standards as completed
marked the checklist item Run main, notice that it says "Listening with microphone ..." as incomplete
marked the checklist item Run the below script while main is running. You should see (for 10 seconds) bars indicating the microphone level as incomplete
marked the checklist item Code follows standards as incomplete
marked the checklist item Unit tests pass (run as described in the README) as incomplete
Tested on WSL.
Initially, the project could not detect my microphone.
After some research, the following system packages were required:
`sudo apt install -y
libasound2 libasound2-plugins
libportaudio2 portaudio19-dev
`
After installing these, the project ran as expected.
I haven’t approved the merge request yet, since it seems that some of these dependencies might need to be added to the setup instructions or requirements documentation.
Overall, great job; I’d approve this once this issue is resolved
left review comments
Thanks, good point. I'll update the installation instructions in the README and in the error message.
I thought
portaudio19-devwas the only dependency. Was that not the case for you? I'll try to reproduce this on a Windows machine at home tonight.added 1 commit
a6a12a58- fix: remove unused qi importCompare with previous version
added 1 commit
9ea44627- fix: allow speaking text with Unicode charactersCompare with previous version
added 1 commit
5912ac60- docs: add installation instructions for the portaudio dependencyCompare with previous version
added 1 commit
fab5127c- feat: add application parameter to choose a custom microphoneCompare with previous version
added 1 commit
854a14bf- docs: describe `--microphone` program parameterCompare with previous version
added 1 commit
8a095323- docs: describe extra WSL installation stepCompare with previous version
marked the checklist item Unit tests pass (run as described in the README) as completed
marked the checklist item Run main, notice that it says "Listening with microphone ..." as completed
marked the checklist item Run the below script while main is running. You should see (for 10 seconds) bars indicating the microphone level as completed
marked the checklist item Code follows standards as completed
mentioned in commit
c037eb7ec2