Skip to content

fix(autoresearch): route the HSPI MISO pad so spiLoopback captures on hardware (#4942) - #4963

Merged
zackees merged 1 commit into
masterfrom
feat/spi-loopback-miso-fix
Oct 29, 2026
Merged

zackees merged 1 commit into
masterfrom
feat/spi-loopback-miso-fix

Conversation

@zackees

@zackees zackees commented Oct 29, 2026

Copy link
Copy Markdown
Member

The bench muxed MOSI/SCK but not GPIO12 (MISO), so the duplex receive returned 0 even with D7->D6 wired. Now matches the core's SPI.begin() (pinMode MISO/MOSI/SCK = SPECIAL).

On-device (D1 mini, D7→D6 jumpered):

spiLoopback 32 -> {'sent': 32, 'success': True, 'last_got': 150, 'first_bad': -1}
spiLoopback 8  -> {'sent': 8,  'success': True, 'last_got': 30,  'first_bad': -1}

Byte-exact SPI capture, verified on silicon.

… hardware

The spiLoopback bench configured only the MOSI/SCK pads, so GPIO12 (MISO) was
never muxed to SPI1 -- the duplex receive read the plain GPIO and returned 0
even with D7->D6 wired. Match the core's SPI.begin(): pinMode MISO/MOSI/SCK to
SPECIAL.

On-device (D1 mini, D7->D6 jumpered, /dev/ttyUSB0):
  spiLoopback 32 -> {'sent': 32, 'success': True, 'last_got': 150, 'first_bad': -1}
  spiLoopback 8  -> {'sent': 8,  'success': True, 'last_got': 30,  'first_bad': -1}
last_got matches the pattern (31*37+0x1B=150, 7*37+0x1B=30) and first_bad=-1:
byte-exact SPI output capture, verified on silicon.

Refs #4942, #4949.
@zackees
zackees merged commit 264520b into master Oct 29, 2026
91 of 93 checks passed
@coderabbitai

coderabbitai Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

Caution

Review failed

The pull request is closed.

Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@fastled-project-sync fastled-project-sync Bot moved this to Triage in FastLED Tracker Oct 29, 2026
@fastled-project-sync fastled-project-sync Bot moved this from Triage to Done in FastLED Tracker Oct 29, 2026
@zackees
zackees deleted the feat/spi-loopback-miso-fix branch November 5, 2026 05:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant