SoundLink enables data transfer through audio signals. It encodes messages into audio waveforms and decodes them back, using the speaker and microphone as the transmission medium.
output.mp4
2026-04-05.22-56-26.mp4
Sender Receiver
| ^
| Encode + Play | Capture + Decode
v |
[Encoder] ---- audio -----> [Encoder]
For Ubuntu
Make sure that all the required packages are installed (on Debian):
sudo apt-get update
sudo apt-get install -y portaudio19-devFor Mac
Install homebrew
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"Install portaudio
# Use Homebrew to install latest PortAudio (for ARM)
arch -arm64 brew install portaudio
# Validate PortAudio path
brew --prefix portaudio # Example: /opt/homebrew/opt/portaudiobazel run //src/sender:sender_mainbazel run //src/receiver:receiver_mainParameters are defined in params/encoder_params_prod.txt.
# Build all targets
bazel build //...
# Build specific target
bazel build //src/demo
# Build with AddressSanitizer
bazel build --config=asan //...# Run all tests
bazel test //...
# Run specific test
bazel test //src/wav:wav_writer_test
# Run with full output
bazel test --test_output=all //...
# Run with AddressSanitizer
bazel test --config=asan --test_output=errors //...| Component | Description |
|---|---|
| Encoder | Encodes/decodes data to/from audio samples. Supports multiple algorithms (simple, Goertzel, chirp). |
| Audio | Cross-platform audio playback and capture using PortAudio. |
| Sender | High-level module that encodes and transmits messages via speakers. |
| Receiver | High-level module that captures audio and decodes messages via microphone. |
| Protocol | Frame structure with preamble, length, checksum for reliable transmission. |
| WAV | WAV file read/write utilities for audio file handling. |
- Bazel - Build system
- PortAudio - Cross-platform audio I/O (
sudo apt-get install portaudio19-dev) - Google Test - Unit testing
- Google Logging - Logging
- Protocol Buffers - Data serialization