AUTHOR: Cynthia
Initial Goal: Sound threshold trigger
Realized Outcome: Yes (portaudio and respeaker bug — inconsistent warning but we're using it to sense not playback or recording)
Hardware Requirements: respeaker USB array for Reachy, but can be any mic input configured for appropriate collection of audio data
Install requirements
Install packages with root privileges, apt-get install
alsa-utils
portaudio19-dev
sudo pip install soundmeter (background process)
Then...
soundmeter --trigger +2000 --action exec --exec ~/.soundmeter/trigger.sh
Also, USB webcam — fswebcam package to take test images (in trigger.sh)
Note: Reference Files on rPi4 / Circuit Launch Setup
Trigger Bash Script — executed upon sound threshold met (trigger.sh)
Profile Variable (—profile [soundmeter] or —profile [test]) pulls parameters from config file
Sample espeak Python script — can be run via trigger.sh file
espeak is currently commented out so trigger is acting only as a test image script
dependency: fswebcam (installed to operate usb webcam for images only)
(resolution explicitly for '352x288' instead of default ⇒ testimage is timestamped for debug)
TBD
TBD
[Code for trigger.sh and espeak python script](https://circuitlaunch.notion.site/Code-for-trigger-sh-and-espeak-python-script-ecd0367655fb441c8f4741acefa6427a)