Skip to content

Preserve multiplexed EasyEDA pin aliases - #510

Open
GokulPandi-M wants to merge 1 commit into
tscircuit:mainfrom
GokulPandi-M:codex/preserve-multiplexed-pin-aliases
Open

Preserve multiplexed EasyEDA pin aliases#510
GokulPandi-M wants to merge 1 commit into
tscircuit:mainfrom
GokulPandi-M:codex/preserve-multiplexed-pin-aliases

Conversation

@GokulPandi-M

@GokulPandi-M GokulPandi-M commented Aug 24, 2026

Copy link
Copy Markdown
Contributor

Motivation

EasyEDA pin names containing /, dots, parentheses, or Unicode minus characters were rejected by the parser and replaced with numeric fallback labels. This made alternate functions such as #RST/NMI/SBWTDIO unavailable when wiring imported components.

Changes

  • capture the complete tilde-delimited EasyEDA pin-name field
  • expose multiplexed functions as separate pinLabels aliases
  • normalize generated aliases to ASCII letters, numbers, and underscores
  • preserve Unicode and punctuation in raw schematic display labels
  • trust normalized source_port.port_hints when generating custom symbols
  • normalize ASCII hyphen, en dash, and Unicode minus polarity suffixes to _NEG
  • treat polarity-only schematic text as display decoration instead of creating false pin aliases

Verification

Real-part regression coverage and rendered schematic snapshots are included for:

  • C472489: slash-separated, active-low, and dotted aliases
  • C14877: parenthesized alternate functions
  • C2886621: Unicode en-dash polarity
  • C2979182: polarity-only display text

bun run build, bun run format:check, and the complete test suite pass (209 tests, 66 snapshots).

@GokulPandi-M
GokulPandi-M force-pushed the codex/preserve-multiplexed-pin-aliases branch from 92eaa97 to 1745eca Compare August 24, 2026 06:48
@GokulPandi-M
GokulPandi-M marked this pull request as ready for review August 26, 2026 07:47
@ShiboSoftwareDev

Copy link
Copy Markdown
Contributor
  • codex review:
    • Keep display/raw pin labels separate from selector-safe aliases, especially Unicode polarity characters. Don't mutate pin.label merely to make an alias usable.
    • Clarify/fix PC0(ADC0) behavior and add a unit test for a single parenthesized alternate function.

@ShiboSoftwareDev

Copy link
Copy Markdown
Contributor

too many, changes, hard to know what is fixed and what regressed

@GokulPandi-M

Copy link
Copy Markdown
Contributor Author

The actual fix is limited to the pin parsing and alias handling. Most of the diff is just snapshot updates caused by the label changes. @ShiboSoftwareDev

Comment thread tests/convert-to-ts/C113367-to-ts.test.ts Outdated
@GokulPandi-M
GokulPandi-M force-pushed the codex/preserve-multiplexed-pin-aliases branch from 4af850d to ecda735 Compare August 29, 2026 14:20
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.

3 participants