๐ŸŽค

Reachy Audio Publisher

Standalone mic-capture ยท WebSocket PCM stream ยท Reachy Mini Python App
reachy_mini reachy_mini_python_app Python 3.11+ WebSocket PCM16 ยท 16 kHz

Captures raw audio from the Reachy Mini's 4-mic array via sounddevice and streams PCM16 mono frames at 16 kHz over a local WebSocket endpoint โ€” feeding the orchestrator's VAD โ†’ STT pipeline.

Architecture

Reachy Pi
โ”œโ”€โ”€ reachy_mini daemon    :8000  โ† motors, camera, built-in VAD/DOA
โ””โ”€โ”€ reachy_audio_pub :8765  โ† raw PCM stream (this app)

Orchestrator (Mac Mini / server)
โ””โ”€โ”€ ReachyMicSource โ† WS client pulls 100ms frames โ†’ VAD โ†’ STT โ†’ turn-taking

Required Secrets

Set these before installing via the Reachy dashboard:

SecretRequiredDescription
ORCH_URL Recommended WebSocket URL of your orchestrator, e.g. ws://10.0.0.100:9000/ws/audio. Logged at startup. The orchestrator connects to this publisher (pull model).
AUTH_TOKEN Optional If set, connecting WS clients must send this token as their first message. Leave blank to disable authentication.

Optional Env Overrides

VariableDefaultDescription
MIC_HOST0.0.0.0WS server bind address
MIC_PORT8765WS server bind port
SAMPLE_RATE16000Capture sample rate (Hz)
FRAME_MS100Frame duration (ms) โ€” 100 ms = 1600 samples
MIC_DEVICEsystem defaultsounddevice device name or index

How to Install

  1. Connect to your Reachy Mini using the dashboard.
  2. Navigate to Applications โ†’ Browse private apps.
  3. Enter the Space ID: CjTruHeart/reachy-audio-pub.
  4. Set ORCH_URL and optionally AUTH_TOKEN under Secrets.
  5. Click Install โ€” the daemon clones the Space and runs pip install ..
  6. Start the app. Your orchestrator can now connect to ws://<pi-ip>:8765/ws/audio.

WS Protocol

Connect to ws://<pi-ip>:8765/ws/audio. The server sends binary frames of raw int16 little-endian mono PCM at 16 kHz. Default frame size is 100 ms = 3200 bytes. Only one client is served at a time; a new connection drops the previous one.

If AUTH_TOKEN is set, send the token as a text message immediately after connecting. The server will close the connection with code 1008 if the token is missing or wrong.