Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tmigone/audio-example
Minimal audio setup for playing audio files in balenaOS
https://github.com/tmigone/audio-example
Last synced: 12 days ago
JSON representation
Minimal audio setup for playing audio files in balenaOS
- Host: GitHub
- URL: https://github.com/tmigone/audio-example
- Owner: tmigone
- Created: 2022-03-31T16:09:37.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2022-03-31T16:32:01.000Z (over 2 years ago)
- Last Synced: 2024-10-19T19:59:36.337Z (18 days ago)
- Language: Shell
- Size: 1000 Bytes
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# audio-example
Quick example on how to wire balena audio block to play a sound.
## Services
**source**This container uses `sox` to play an audio file. It's configured to send the audio into the audio block on a specific virtual sink.
**audio**
The audio block. The config file creates a virtual sink which we use to receive audio from the source container. Additionally we route the audio from the virtual sink into the device's default hardware audio (typically audio jack on Rasbperry Pi devices) for testing purposes.
__Note__: if you are using a Raspberry Pi4, make sure under `Device Configuration` the `DT Overlay` is set to `"vc4-fkms-v3d"` and **NOT** `"vc4-kms-v3d"`.
**recorder**
This service is not setup but we could use `parecord` for example to grab the audio and pipe it into another program. Just need to configure `PULSE_SERVER` and `PULSE_SOURCE` environment variables.