← Commit history

2.11.3: Dock Bar README section + adom-lbr-dockbar skill; skills refreshed for 2.10/2.11

John Lauer ·8b75cca72a ·1mo ago ·parent 0cd7d73
10 files changed +196−18
Cargo.lock+1−1
@@ -10,7 +10,7 @@ checksum = "320119579fcad9c21884f5c4861d16174d0e06250625266f50fe6898340abefa"  [[package]] name = "adom-lbr"-version = "2.11.2"+version = "2.11.3" dependencies = [  "altium-codec",  "anyhow",
Cargo.toml+1−1
@@ -1,6 +1,6 @@ [package] name = "adom-lbr"-version = "2.11.2"+version = "2.11.3" edition = "2021" description = "adom-lbr generator / EDA translator: the canonical adom-lbr JSON is the hub, with native converters to Altium (.SchLib/.PcbLib/.IntLib), EAGLE/Fusion (.lbr), and KiCad. Altium output is written natively — no Altium needed at conversion time." 
README.md+25−1
@@ -36,9 +36,33 @@ show/hide filter, drag-to-pan / scroll-to-zoom viewers, and **hover-to-highlight on pins & pads showing each one's number and name.  ```bash-adom-lbr manage --port 8785        # → http://localhost:8785 (list ▸ click ▸ viewer)+adom-lbr dashboard serve --print-url   # start (or reuse) the dashboard → http://127.0.0.1:8785/+adom-lbr manage --port 8785            # the same server, in the foreground ``` +## One click from the Hydrogen Dock Bar++![adom-lbr running in Adom Hydrogen: the Adom LBR webview tab with green status LEDs and the Say it strip, launched from the dock rail on the right](docs/dockbar-ah.png)++adom-lbr is a card on Hydrogen's **Dock Bar**, the app-launcher rail on the right+edge of the workspace. One click installs the CLI into your container+(`adom-wiki pkg install adom/adom-lbr`, skipped when it is already there), starts+the dashboard with `adom-lbr dashboard serve --print-url`, and takes over the+pre-opened **Adom LBR** webview tab. The card's LED is live health, read from the+dashboard's own `/api/status` every 15 seconds: six facets (binary, wiki,+identity, library, 3D viewer, dock) plus a rollup the app owns, each carrying a+hint that names the fix when it is not green.++The first thing on the page is the **Say it** strip, because you do not drive+this dashboard by hand: you ask your AI, using the word **lbr** ("validate my+lbr for fusion"). Click a phrase to copy it; **Try it** stages it, unsent, into+this app's own AI thread. The cog opens Settings: taskbar progress during long+work (a real progress bar on the Hydrogen window's Windows taskbar button),+whose boards count as My projects, the wiki list cache, and package+Update/Uninstall with a live console. The launch contract lives in+`dockbar.json` at the root of this page repo; the bundled `adom-lbr-dockbar`+skill documents every piece of it for your AI.+ ## The 3-column library viewer, with an interactive embed  ![The Fusion-style 3-column viewer: symbol, footprint, 3D, and the pin→pad mapping table](docs/viewer3col.png)
SKILL.md+4−1
@@ -10,7 +10,8 @@ description: >   view symbol/footprint/3D + the per-EDA (KiCad vs Altium) footprint layer stackup.   Trigger words: adom-lbr, altium schlib pcblib intlib, convert to altium, kicad to   altium, altium to kicad, any eda to any eda, eda translator, lbr, eagle library,-  fusion library, adom-lbr json, kicad convert, adom-lbr manager, layer stackup.+  fusion library, adom-lbr json, kicad convert, adom-lbr manager, adom-lbr+  dashboard, lbr dock, layer stackup. ---  # adom-lbr@@ -28,6 +29,8 @@ adom-lbr generator / EDA translator. The **adom-lbr JSON**, Adom's own canonical ```bash # INTO the hub adom-lbr import-kicad  --sym part.kicad_sym --fp part.kicad_mod --mpn MPN   # KiCad  → MPN.adom-lbr.json+#   --pin-map map.json (or a pinmap.json sidecar beside the symbol) maps pin NUMBER → pad NAME+#   when they disagree; an unmatched pin WARNs and names the unreferenced pads (never silent) adom-lbr import-altium part.SchLib --pcblib part.PcbLib --mpn MPN           # Altium → MPN.adom-lbr.json adom-lbr import-altium part.IntLib --mpn MPN                                # or one bundled .IntLib 
VERSION+1−1
@@ -1 +1 @@-2.11.2+2.11.3
docs/dockbar-ah.pngadded
⋯ 1 unchanged line ⋯
package.json+1−1
@@ -1,6 +1,6 @@ {   "slug": "adom-lbr",-  "version": "2.11.2",+  "version": "2.11.3",   "type": "app",   "description": "adom-lbr \u2014 the EDA library translator. Bring a component in from any supported EDA tool and convert it to any other (KiCad \u21c4 Altium \u21c4 EAGLE/Fusion) through one canonical adom-lbr JSON \u2014 symbol + footprint + 3D + pin\u2194pad map. Altium is written natively (no Altium needed). Includes the adom-lbr Manager: browse wiki components and view symbol/footprint/3D + the per-EDA layer stackup.",   "dependencies": {},
page.json+9−12
@@ -1,8 +1,8 @@ {   "slug": "adom-lbr",-  "version": "2.11.2",+  "version": "2.11.3",   "type": "app",-  "description": "adom-lbr — the EDA library translator. Bring a component in from any supported EDA tool and convert it to any other (KiCad ⇄ Altium ⇄ EAGLE/Fusion) through one canonical adom-lbr JSON — symbol + footprint + 3D + pin↔pad map. Altium is written natively (no Altium needed). Includes the adom-lbr Manager: browse wiki components and view symbol/footprint/3D + the per-EDA layer stackup.",+  "description": "adom-lbr \u2014 the EDA library translator. Bring a component in from any supported EDA tool and convert it to any other (KiCad \u21c4 Altium \u21c4 EAGLE/Fusion) through one canonical adom-lbr JSON \u2014 symbol + footprint + 3D + pin\u2194pad map. Altium is written natively (no Altium needed). Includes the adom-lbr Manager: browse wiki components and view symbol/footprint/3D + the per-EDA layer stackup.",   "dependencies": {},   "tags": [     "eda",@@ -52,24 +52,21 @@   ],   "files": [     "bin/**",-    "assets/**",     "SKILL.md",-    "skills/**",     "README.md",     "install.sh",     "uninstall.sh",-    "screenshots/**",-    "dockbar.json"+    "screenshots/**"   ],-  "discovery_pitch": "Convert electronic-component symbols + footprints between any two EDA tools — KiCad, Altium (written natively, no Altium needed), and EAGLE/Fusion — through one canonical adom-lbr JSON, silk/courtyard/fab layers preserved. Plus a Manager to browse and inspect any wiki part.",+  "discovery_pitch": "Convert electronic-component symbols + footprints between any two EDA tools \u2014 KiCad, Altium (written natively, no Altium needed), and EAGLE/Fusion \u2014 through one canonical adom-lbr JSON, silk/courtyard/fab layers preserved. Plus a Manager to browse and inspect any wiki part.",   "sample_prompts": [     {       "prompt": "Convert this KiCad symbol and footprint to an Altium SchLib and PcbLib",-      "label": "KiCad → Altium"+      "label": "KiCad \u2192 Altium"     },     {       "prompt": "Import this Altium footprint into the adom-lbr JSON",-      "label": "Altium → JSON"+      "label": "Altium \u2192 JSON"     },     {       "prompt": "Bundle this part into a single Altium IntLib",@@ -77,15 +74,15 @@     },     {       "prompt": "Convert this Altium SchLib and PcbLib to a KiCad symbol and footprint",-      "label": "Altium → KiCad"+      "label": "Altium \u2192 KiCad"     },     {       "prompt": "Export this adom-lbr JSON to a KiCad .kicad_sym and .kicad_mod",-      "label": "JSON → KiCad"+      "label": "JSON \u2192 KiCad"     },     {       "prompt": "Open the adom-lbr Manager to browse wiki components and view the layer stackup",       "label": "Browse parts"     }   ]-}\ No newline at end of file+}
skills/adom-lbr-dockbar/SKILL.mdadded+135
@@ -0,0 +1,135 @@+---+name: adom-lbr-dockbar+description: >+  adom-lbr on the Hydrogen Dock Bar: what the dock card does, how the one-click+  launch works (install, serve, webview takeover), the /api/status LEDs the card+  reads, the "Say it" strip, the settings modal, taskbar progress, and how to+  debug a card that reads red or a launch that fails. Use when the user clicks+  the Adom LBR dock card, asks why its LED is not green, wants the dashboard+  opened or restarted, or asks how adom-lbr integrates with the dock. Trigger+  words: adom-lbr dock, lbr dock card, adom lbr dashboard, lbr dashboard serve,+  dockbar.json lbr, lbr card red, lbr launch failed, adom-lbr status leds,+  lbr say phrases, lbr settings, lbr taskbar progress.+---++# adom-lbr on the Hydrogen Dock Bar++The Dock Bar is Hydrogen's app launcher: the rail of cards on the right edge of+the workspace. The **Adom LBR** card is the wiki page `adom/adom-lbr`; one click+installs the CLI into the user's container, starts the dashboard, and shows it+in a webview tab. This skill is the map of that machinery from adom-lbr's side.++## Purpose++The dashboard (the Manager) is adom-lbr's face: the user's wiki boards and+parts on the left, a symbol / footprint / 3D / layer-stackup viewer for any+part, live health LEDs, and settings. The dock makes it one click for someone+who has never installed anything. The user does not drive it by hand: the+"Say it" strip at the top teaches the noun **lbr** ("validate my lbr for+fusion"), and their AI does the work.++## What one click actually runs++The card's launch comes from `dockbar.json` (1.2.0) at the root of the+adom/adom-lbr page repo. Two container steps, each with PATH set to+`~/.local/bin` (wiki CLIs land there and the exec shell does not have it):++1. **Install**: `adom-wiki pkg install adom/adom-lbr`, skipped when+   `command -v adom-lbr && adom-lbr dashboard say` already succeeds. The+   `dashboard say` probe matters: it reinstalls over a pre-2.11 binary that has+   no dashboard.+2. **Serve**: `adom-lbr dashboard serve --print-url`, `await: url`. It prints+   the DIRECT URL `http://127.0.0.1:8785/` on stdout, self-backgrounds, and+   exits 0; the dock scrapes the URL and polls it before showing the page.++`serve` is idempotent and version-aware:++- A healthy instance of the SAME version already on the port: print its URL,+  exit 0 (measured 0.05 s).+- A healthy instance of a DIFFERENT version (or a pre-2.11 `manage` that has no+  status route): retire it first. Victims are matched by EXACT argv+  (`adom-lbr dashboard serve ... --foreground`, or `adom-lbr manage`), scoped+  to the target port, never this process or its parent, never a substring.+- Port taken by something that is not adom-lbr: refuse immediately and name it.+- "In use" means a completed TCP connect. Refused AND timed out both mean free+  (under WSL2 mirrored networking a free loopback port can time out instead of+  refusing; treating that as busy cost a whole launch once).++## The webview belongs to the CLI++The dock pre-opens a tab named by `webview.title` ("Adom LBR", keep it stable)+and passes that name to every step as `ADOM_DOCK_WEBVIEW`. As soon as the+socket is bound, the server runs+`adom-cli hydrogen webview open-or-refresh --name "$ADOM_DOCK_WEBVIEW" --url http://127.0.0.1:8785/`+in a background thread (never blocking the URL print), and on a reuse launch+the exiting launcher asks the running server to re-claim+(`POST /api/claim-webview {name}`). Unset env means someone ran serve by hand;+the claim is silently skipped and the dock's own interstitial navigation is the+fallback.++## The health the card shows++The card's LED polls `/api/status` every 15 s. The payload is cached 10 s and+answers in under a millisecond, carries six facet LEDs, and a top-level `state`+rollup the app owns:++| LED | ok means | not-green means |+|---|---|---|+| Binary | version + path of the running binary | never |+| Wiki | wiki.adom.inc answers | fail: no components can load; check network, `adom-wiki doctor` |+| Identity | signed in; My projects = boards by this user | warn: `adom-wiki auth`, or set owner_override in Settings |+| Library | wiki component list cached (count) | ok either way; "warming up" before first load |+| 3D viewer | viewer assets found | warn: reinstall `adom-wiki pkg install adom/adom-lbr` |+| Dock | owns the dock tab, or "started by hand" | never |++Every non-green LED carries a `_hint` naming the exact fix; read it before+diagnosing anything yourself. Every `/api/*` route (and `/health`) sends+`Access-Control-Allow-Origin: *` and answers OPTIONS, because the dock probes+cross-origin from the Hydrogen shell; without that header the card reads "not+answering" while the server is perfectly healthy.++## Say it, and Try it++`dockbar.json` declares up to six phrases in the noun lbr; the dock shows them+on the card's hover preview and the launch interstitial, and the dashboard+renders the same list as the FIRST thing on the page (they are read from the+installed copy at `~/.local/share/adom-lbr/dockbar.json`; `adom-lbr dashboard+say` prints them). Click copies; **Try it** stages the phrase, unsent, into+this app's own AI thread through the Hydrogen control API at 127.0.0.1:47084:+open threads first (census, tag `app:adom/adom-lbr`), then history (resume,+then stage), else it copies and says why. From a cloud container the control+API is unreachable and copying is the correct fallback.++## Settings and taskbar progress++The cog (upper right of the 44 px header) opens the settings modal+(settings-layout style: dim never blur; Escape, the X, and an outside click+close it). Stored at `~/.config/adom-lbr/settings.json`, typed by their+defaults; wrong-typed or unknown keys are rejected by name, never written.++- **Taskbar progress** (default on): while the dashboard does long work, it+  paints the Hydrogen window's Windows taskbar button through Adom Bridge's+  `desktop_taskbar` verb. Add to Library is determinate (every symbol and+  footprint is one step); package install/update fills over the average this+  app has measured for that operation (`~/.config/adom-lbr/durations.json`)+  and is indeterminate the very first time. The child setting names the window+  title to paint (default "Hydrogen"). No bridge, no window, or the toggle off+  all mean nothing is painted.+- **My projects author** overrides the `adom-wiki whoami` identity for the+  left pane's grouping; **List cache** sets how long the wiki page list is+  reused (default 30 minutes; the refresh button always fetches fresh).+- **Update / Uninstall** run `adom-wiki pkg install|uninstall adom/adom-lbr`+  with the real output streaming into a console under the row and a verify+  line at the end. Restore defaults is two clicks, auto-disarming.++## Debugging a launch++- **Card red / "not answering"**: `curl -s http://127.0.0.1:8785/api/status`.+  Answers? Then it is almost always the CORS header missing on a fork, or the+  wrong port. Silent? `adom-lbr dashboard serve --print-url` and read stderr.+- **"no URL" in the launch console**: the serve step failed before printing.+  Its stderr names the cause: a stale instance that would not exit, or a port+  owned by something that is not adom-lbr (pick another with `--port`).+- **Stale version after an update**: relaunch from the dock; serve retires the+  old instance itself. `adom-lbr dashboard status` prints the live payload.+- **Manual run**: `adom-lbr manage` is the foreground alias, same server.
skills/fusion-export/SKILL.md+19
@@ -97,12 +97,31 @@ adom-lbr generate --sym P.kicad_sym --fp P.kicad_mod --symbol-art P-3d-outline-b   export. `.lbr` done; KiCad `.kicad_sym` + future native exporters are TODO   ([../../docs/ROADMAP.md](../../docs/ROADMAP.md)). +## What generate now handles for you (2.10+)++- **Duplicate pad names** (KiCad same-net arrays: thermal vias, ground paddles,+  shield tabs) used to make Fusion refuse the ENTIRE library. generate resolves+  them to the EAGLE `@`-suffix convention (`17`, `17@2`, ...) with one+  space-separated multi-pad `<connect>`, and lint fails a raw duplicate+  (`duplicate-pad-name`).+- **Package-mirror symbols** (pins on all four sides, rotated colliding names)+  are re-laid into EE-convention two columns by `--symbol-layout auto` (the+  default): inputs left, outputs right, power grouped bottom-left, buses+  contiguous. `keep` preserves the source placement.+- **Pin/pad name mismatches** (a USB-C shield pin "S1" against a pad "SH") take+  `--pin-map` or a `pinmap.json` sidecar beside the symbol, on both `generate`+  and `import-kicad`; validate fails a dangling connect (`connect-pad-unresolved`)+  naming the unreferenced pads.+ ## Quick triage  | Symptom | Fix | |---|---| | Footprint is two columns / a domino | regenerate **with `--fp part.kicad_mod`** | | Fusion: "No Components" | `adom-lbr lint part.lbr` → fix the reported code |+| Fusion refuses the whole library over pads | pre-2.10 file: regenerate (`@`-suffix dedup), or `adom-lbr lint` names the duplicates |+| Symbol pins on 4 sides, names rotated | regenerate with 2.10+ (`--symbol-layout auto` re-lays it) |+| A pin connects to nothing (validate FAIL) | supply `--pin-map` / `pinmap.json` mapping pin number → pad name | | 3D body is a gray placeholder | let the bridge attach it (Create3DPackage → FINISH) | | `bind-3d` rejected the URN | self-uploaded → `--wip-urn` (`fs.file:vf…?version=N`); managed → `--urn` | | 3D offset / wrong pin 1 | run chipfit; set `placement` in the sidecar before FINISH |