Skip to content

fix RP2040 LED supplier polarity - #98

Merged
MustafaMulla29 merged 5 commits into
mainfrom
agent/fix-rp2040-led-polarity
Aug 18, 2026
Merged

fix RP2040 LED supplier polarity#98
MustafaMulla29 merged 5 commits into
mainfrom
agent/fix-rp2040-led-polarity

Conversation

@MustafaMulla29

Copy link
Copy Markdown
Contributor

Summary

  • map XL_1608SURC_06 pin 1 to cathode/negative and pin 2 to anode/positive
  • align the custom footprint pad hints with JLCPCB part C965799
  • rotate the two RP2040 status LED schematic symbols so their resistor-to-LED-to-ground flow remains direct
  • update the RP2040 source/footprint regression assertions and schematic, PCB, and 3D snapshots

Root cause

The imported XINGLIGHT LED retained tscircuit's generic LED numbering (pin1 = anode) while its supplier part defines pin 1 as cathode. The footprint previously compensated by swapping only its port hints, leaving the logical source pinout inconsistent with supplier metadata. Correcting the logical pinout also swapped the schematic endpoints, so the existing symbol rotations had to be turned 180 degrees to preserve the intended visual routing.

Impact

Supplier-aware validation no longer reports a polarity mismatch for D1 and D_PWR, and the schematic keeps the clean resistor -> LED -> GND presentation without changing PCB placement or electrical connectivity.

Validation

  • bun test tests/test.test.tsx — 18 passed
  • bun run build
  • focused Biome formatting check
  • bunx tsci snapshot lib/Microcontroller_RP2040/Microcontroller_RP2040.circuit.tsx --3d — all snapshots match

@vercel

vercel Bot commented Aug 18, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
tscircuit-common Ready Ready Preview Aug 18, 2026 10:32am

Request Review

Co-authored-by: MustafaMulla29 <97171641+MustafaMulla29@users.noreply.github.com>

@imrishabh18 imrishabh18 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not the right place to fix, the fix needs to be made upstream. So, on import of part numbers we don't face this issue anymore

…polarity

# Conflicts:
#	examples/MicrocontrollerRP2040WithUsbC/__snapshots__/MicrocontrollerRP2040WithUsbC.circuit-pcb.snap.svg
#	lib/Microcontroller_RP2040/__snapshots__/Microcontroller_RP2040.circuit-pcb.snap.svg
@MustafaMulla29

Copy link
Copy Markdown
Contributor Author

@imrishabh18 the issue is already fixed, reimported the file

@MustafaMulla29
MustafaMulla29 merged commit 6a835a6 into main Aug 18, 2026
6 checks passed
@tscircuitbot

Copy link
Copy Markdown

Thank you for your contribution! 🎉

PR Rating:
Impact: Tiny

Track your contributions and see the leaderboard at: tscircuit Contribution Tracker


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.

4 participants