Skip to content

v2.0.0-alpha.6

Pre-release
Pre-release

Choose a tag to compare

@remcom remcom released this 26 Oct 17:55
· 30 commits to develop since this release
156df2b

Summary

This implements the XMOS side of the wake word research. The ESPHome side is remcom/Satellite1-ESPHome#74.

Wake word steering (§5.1, beam mode and AUTO_PAIR)

  • New command AUDIO_SERVICER_CMD_WAKE_EVENT (9). The host writes 1 right after a wake word and 0 when the conversation ends.
  • The front end keeps the last ~1.5 s of DOA results (80 entries, 960 B). On a wake word it steers the beam within one frame, crossfaded and without the 0.5 s stable time or the 3 s dwell. In AUTO_PAIR it picks the pair facing the wake word.
  • The direction is the confidence-weighted mean of the largest group of DOA results within 30°. That group must hold at least 25 % of the window's weight and needs at least 5 results.
  • Groups are ranked down by up to half according to where idle speech usually comes from: a decaying 36-bin histogram over about 30 s of located speech (the report's "TV louder than user" refinement). A wake word said while a TV talks therefore wins with about as many located frames as the TV had.
  • While a conversation is active, speech does not re-steer, for at most 60 s. Each new wake word restarts that limit, also when the host never sent 0 in between.
  • Reading WAKE_EVENT returns 1 only while the steering is actually held. It returns 0 after a 0 was written, or once the 60 s ran out.
  • New command AUDIO_SERVICER_CMD_STEER_POLICY (8):
    • 0 follow speech: the default, and the same behaviour as before when no wake events arrive.
    • 1 wake word only: a TV can no longer pull the beam.
    • 2 fixed.

IC onset protection (§4.1)

  • New command AUDIO_SERVICER_CMD_IC_FAST_HOLD (6), default on.
  • The IC hold decision uses a VNR estimate with a fast attack (α 0.5) and a slow release (α 0.97, as before). From noise into speech the IC holds after 1–2 frames instead of 23–30.
  • fwk_voice applies its filter leakage (0.996 per frame) above the same VNR's 0.75 threshold. Fed the fast estimate directly, the leak would start ~50 frames earlier per utterance and wear down the learned filter. vnr_hold_adapt_vnr() keeps the fast estimate at 0.75 until the fwk_voice EMA is above 0.75 as well. The hold is fast; the leakage keeps its old timing.
  • It reuses the same vnr_extract_features/vnr_inference calls as ic_calc_vnr_pred(), so there is no extra CPU. The AGC flag still uses the fwk_voice EMA.
  • The optional OR with the DOA energy detector was not implemented: it would also hold the IC on TV and music onsets.

Right channel tap (§3.2)

  • New command AUDIO_SERVICER_CMD_CH1_TAP (5):
    • 0 AEC+IC+NS: the default, same as before.
    • 1 AEC+IC, before the NS.
    • 2 AEC only.
  • A build that cannot produce a tap rejects it with SERVICER_WRONG_PAYLOAD instead of outputting stale frame memory. Taps 1 and 2 need the IC stage, and 1 also needs the IC output stored. If the selected tap is unavailable, the output falls back to 0.
  • Tile 0 settings travel in a new frame_data_t.t0_ctrl word, because the servicer runs on tile 1.

High-pass (§3.3)

  • New command AUDIO_SERVICER_CMD_HPF (7), default on.
  • A 2nd-order 100 Hz Butterworth high-pass on both pipeline channels, before the AEC (DF1, Q28 coefficients, int64 accumulators, saturating).

Docs: README and docs/device-control-spi-protocol.md cover the five new commands. They are additive; older hosts never send them.