Skip to content

sof-teensy: Add PJRC Teensy 4.1 flash, loopback test, and diag tools - #5

Open
lgirdwood wants to merge 1 commit into
mainfrom
feat/teensy41-tools
Open

lgirdwood wants to merge 1 commit into
mainfrom
feat/teensy41-tools

Conversation

@lgirdwood

Copy link
Copy Markdown
Member

Summary

Moves the PJRC Teensy 4.1 (NXP i.MX RT1062) host utilities out of the main sof repository (per review feedback on thesofproject/sof#11197) into sof-utils/sof-teensy/:

  • teensy_flash.py (sof-teensy-flash): Sends the vendor-specific USB control transfer (0xFB) to reboot running SOF UAC2 firmware into the HalfKay bootloader without physical button presses, resolves multi-board setups by USB hub topology path or serial, and flashes .hex images via teensy_loader_cli.
  • test_teensy_loopback.py (sof-teensy-loopback): Automated end-to-end hardware audio loopback test (aplay -> Board A UAC2 -> S/PDIF or SAI1 I2S -> Board B -> UAC2 -> arecord) computing FFT fundamental frequency, per-channel SNR (dB), and XRUN/dropped-frame diagnostics.
  • teensy_diag.py (sof-teensy-diag): Non-intrusive USB topology, ALSA card discovery, and SOF UAC2 enumeration diagnostics.
  • Integrated into the top-level Makefile (install, uninstall, check) and README.md.

Verification

  • make check passes cleanly.
  • Verified teensy_flash.py and test_teensy_loopback.py --interface spdif on physical Board A + Board B hardware (140.81 dB SNR on Left & Right channels, 0 dropped frames).

Add host utilities for flashing, hardware loopback verification, and USB/ALSA diagnostics on PJRC Teensy 4.1 (NXP i.MX RT1062) SOF audio bridges:
- teensy_flash.py: Automated HalfKay reboot request (0xFB) and firmware flashing via teensy_loader_cli with topology-path board resolution.
- test_teensy_loopback.py: Automated UAC2 -> S/PDIF / SAI1 I2S -> UAC2 hardware loopback audio test computing FFT peak frequency, SNR (dB), and XRUN/dropped-frame diagnostics.
- teensy_diag.py: Non-intrusive USB topology, ALSA card discovery, and SOF UAC2 enumeration diagnostics.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants