From c09a2dbb5f7300c92e1f2c0f5da62f4d8ba0681c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?blue=20=E2=80=94=20ESP32/PlatformIO=20firmware?= Date: Wed, 10 Jun 2026 12:10:04 -0400 Subject: [PATCH] Add 3-board relay wiring diagram --- 3-Board Relay Wiring.-.md | 63 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 3-Board Relay Wiring.-.md diff --git a/3-Board Relay Wiring.-.md b/3-Board Relay Wiring.-.md new file mode 100644 index 0000000..59d6bd1 --- /dev/null +++ b/3-Board Relay Wiring.-.md @@ -0,0 +1,63 @@ +# 3-Board Bluetooth Relay — Wiring + +Relays iPhone audio to **two** Bluetooth speakers (JBL Charge 5 + Cardo "Tangerine EDGE") at once. + +**Board A** (the A2DP sink — the board the iPhone connects to) is the I2S **master** and drives three signals. **Boards B and C** (the A2DP sources) both **listen** to those same three signals in parallel. Plus one shared ground. + +## Pin-to-pin + +| Signal | Board A (SINK) out | Board B (JBL) in | Board C (Cardo) in | +|---|---|---|---| +| Bit clock (BCK) | **GPIO5** | GPIO19 | GPIO19 | +| Word select (WS/LRCK)| **GPIO25** | GPIO18 | GPIO18 | +| Data | **GPIO23** | GPIO22 | GPIO22 | +| Ground | **GND** | GND | GND | + +Each of A's three pins splits to **both** B and C: + +- A·**GPIO5** -> B·GPIO19 **and** C·GPIO19 +- A·**GPIO25** -> B·GPIO18 **and** C·GPIO18 +- A·**GPIO23** -> B·GPIO22 **and** C·GPIO22 +- A·**GND** -> B·GND **and** C·GND + +## Diagram + +``` + BOARD A (SINK / I2S MASTER) iPhone connects here + +---------------------------+ + | GPIO5 (BCK) o------------+----------+-------------+ + | GPIO25 (WS) o----------+ | | | + | GPIO23 (DAT) o--------+ | | | | + | GND o------+ | | | | | + +---------------------|-|-|-|----------+ | + | | | | | + +---------------+ | | +------+ +-------------+ (BCK to C) + | +-------------+ +-----+ | | +--------- (WS to C) + | | +---------------+--+-+---+---+--------- (DAT to C) + v v v v v v v + BOARD B (JBL) BOARD C (Cardo) + +-----------------+ +-----------------+ + | GPIO19 (BCK in) | | GPIO19 (BCK in) | + | GPIO18 (WS in) | | GPIO18 (WS in) | + | GPIO22 (DAT in) | | GPIO22 (DAT in) | + | GND | | GND | + +-----------------+ +-----------------+ + sends to JBL sends to Cardo +``` + +## Important + +- **Only share GND** between boards — do **not** tie their 3.3V/5V together. Each board runs off its **own USB**. +- The GND link is **mandatory** (common clock reference). +- Keep wires short (< ~20 cm); it's a ~1.4 MHz clock. +- One-way: A **outputs**, B and C **only listen**. + +## Power-on order + +Bring up **Board A first** so the I2S bus is clocking before B and C read it. + +## Limitations + +- The two speakers are **not** sample-synchronized (independent BT buffering -> tens of ms skew). Fine for music/intercom; not for tight stereo L/R. +- Audio is fixed at SBC **44.1 kHz / 16-bit / stereo**. +- This relay carries **music (A2DP) only** — no microphone, no phone-call (HFP) audio.