Skip to content

feat(boards): release the ATtiny85 as preview (P6.5, M3) - #337

Merged
ttbombadil merged 8 commits into
feature/browser-emulationfrom
feat/p6-5-attiny85-preview
Oct 24, 2026
Merged

ttbombadil merged 8 commits into
feature/browser-emulationfrom
feat/p6-5-attiny85-preview

Conversation

@ttbombadil

Copy link
Copy Markdown
Collaborator

Paket

P6.5 ATtiny85 freigeben (M) und Abnahme M3. Gestapelt auf #336 → #335 → #334. Die Basis ist feature/browser-emulation; bis die Vorgänger gemergt sind, enthält der Diff deren Commits mit. Merge-Reihenfolge: #334, #335, #336, dann dieser PR.

Abnahmebericht: report-m3-acceptance.md.

Umgesetzt

  • Status preview für attiny85 (shared/boards.ts, Laufzeit browser).
  • Boardansicht (DIP-8 auf einer Trägerplatine): scripts/generate-attiny85-svg.mjs, npm run generate:attiny85-svg, client/public/ATtiny85*.svg, Eintrag in board-view.ts.
    • Pins 0–4 sind interaktiv, PB5 (RESET) ist sichtbar, aber nicht nutzbar.
    • Es gibt die LEDs „L“ (PB1) und „ON“, dazu einen Reset-Taster.
    • Das Logo steht in der freien Fläche oben. Die Lage ist per Screenshot geprüft: Die erste Position überdeckte das GND-Label.
  • UI für Boards mit eigenen Pinnamen:
    • Die LED „L“ folgt LED_BUILTIN des Boards; bisher war sie fest Pin 13 und am ATtiny85 dunkel.
    • Die Beschriftungen der Analogpins nutzen den Sketch-Namen (analog.name).
    • Der Analogdialog zeigt „2 (A1)“ (activeAnalogPinTitle).
    • Uno, Nano und Mega sehen aus wie vorher.
  • Baudrate des Software-UART: Der Startbefehl hat ein optionales serialBaud, das der Client aus Serial.begin(<Zahl>) liest (sketchSerialBaud). Der Worker setzt damit die Rückfallrate. Die SSOT SimulationRuntime ist ergänzt; die Änderung ist additiv, PROTOCOL_VERSION bleibt.
  • Software-UART, zwei Funde der Korpus-Proben:
    • Die Baudraten-Erkennung rastete bei attiny_basics auf 19200 statt 9600 ein: Die schnellere Rate hatte ihre kürzeren Rahmen zuerst voll. Jetzt wird erst entschieden, wenn jede passende Rate 4 vollständige Rahmen hat; die Rate ohne Rahmenfehler (Stoppbit HIGH) gewinnt.
    • digitalWrite(0, LOW) ohne Serial erzeugte ein Byte 0x00 (attiny_pwm_duty). TX wird jetzt nur dekodiert, solange Serial aktiv ist (Komparator per Serial.begin() an).
  • Korpus: 5 Proben (derived, Begründung je case.json), HEX-Dateien mit npm run fixtures:runtime gebaut; CORPUS_FQBN kennt attiny85, die README ist ergänzt.
  • E2E e2e/attiny85.spec.ts: Boardwahl und Ansicht; Compile mit ATTinyCore, Ausgabe und A1 am Board; Eingabe über den Komparator.
  • Benutzerhandbuch „Board wählen“: Tabellenzeile und Abschnitt ATtiny85 (Pinnamen, RESET, Software-Serial mit Halbduplex und Pin-Konflikten, Baudrate, Speicher). Dazu SSOT Boards, Plan, Status und der M3-Bericht.

Abnahmeevidenz

  • Lokal grün:
    • Unit: App 3573, Emulator 681 Tests;
    • Toolchain-Gate: 133 Tests (142 s von 300 s; mit fixtures:runtime --check auch für die ATtiny-HEX);
    • Docker-Gate: 37 Tests (126 s von 240 s);
    • npm run build mit Bundle 691,0 kB von 710 kB;
    • E2E 54/54;
    • check, lint, knip, check:docs, Pre-Push mit Sonar (S6582, S4624 behoben).
  • Leistung (npm run emulate, M2 Pro): ATtiny85 11,1–11,2 × Echtzeit (Uno-Blink 4,4 ×).

Abweichungen vom Plan

Keine. Zwei Hinweise:

  • Ein E2E-Fall zeigte Halbduplex: Ein Sketch, der vor parseInt() ausgibt, verliert die zweite Ziffer, auf dem echten Chip ebenso. Test-Sketch und Benutzerhandbuch lesen deshalb zuerst und antworten danach.
  • software-uart.test.ts (aus feat(emulator): model the software UART of the ATtiny85 (P6.3) #335): Die synthetische Leitung schaltet jetzt den Komparator ein wie Serial.begin(), weil TX nur noch bei aktivem Serial dekodiert wird. Neu ist der Fall „ohne Serial kein Byte“.

Geänderte bestehende Tests (freigegeben vom Nutzer am 23.10.2026)

Sieben Tests schrieben „ATtiny85 planned bzw. ohne Grafik“ fest:

  • tests/shared/boards.test.ts (3): Statusliste, Standard-Boards, Boards mit Browser-Backend.
  • tests/server/config.test.ts: /api/config listet den ATtiny85 mit.
  • tests/server/routes/compiler-board.routes.test.ts (2): „nicht angebotenes Board“ ist weiter der ATtiny85, jetzt in einer Bereitstellung ohne Browser-Backend. Die Ablehnung bleibt geprüft.
  • tests/client/components/arduino-board-views.test.tsx: eigene Grafik statt der des Uno.

🤖 Generated with Claude Code

ttbombadil and others added 7 commits October 23, 2026 19:57
Port B with INT0 and PCINT0, timer 0 with its own registers and one-word
vectors, the ATtiny timer 1, a four-channel ADC that reads REFS2 at bit 4,
EEPROM timed for 8 MHz, watchdog and clock prescaler. INT0 and the pin-change
interrupt share GIMSK and GIFR, which avr8js wires for one of them only; the
profile wraps both hooks. Registered with the board hardware in P6.4.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
TX is decoded from PB0 with the baud rate found from the edge distances and
the bit width measured from them; RX drives PB1 through an analog comparator
model. SoftwareUart offers the USART members SerialPorts uses, for the
ATtiny85 board.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Pins 0-5 as PB0-PB5 with A0-A3 as second names, PWM on 0, 1 and 4, RESET on
PB5 and Serial as a software port on 0/1. SerialPorts takes a USART or the
software UART, the PWM observation reads timer 1 of the ATtiny85, and the
sketch parsers resolve A<n> and analogRead(n) as ATTinyCore does. The pin
map is checked against the core in the toolchain gate.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
DIP-8 board view, LED and analog labels from the board's own names, the
sketch's Serial.begin() rate for the software UART, five corpus probes, an
end-to-end test and the user guide with the board's limits. The software
UART now judges every fitting baud rate on its frames and decodes TX only
while Serial is active. M3 acceptance report.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ny tests

The gateway deployment test listed the pilot's boards by hand and failed once
the ATtiny85 became preview; it now takes them from the catalog. The ATtiny85
board tests stop as soon as their result is there and share one probe run
(16.8 s to 5.6 s under coverage).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@ttbombadil
ttbombadil merged commit 0d3583f into feature/browser-emulation Oct 24, 2026
6 checks passed
@ttbombadil
ttbombadil deleted the feat/p6-5-attiny85-preview branch October 24, 2026 08:30
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.

1 participant