Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/workflows/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ qualification configuration.
Waveshare V2 audio, display and attended diagnostic development configurations
are also generated and compiled. These require isolated storage and disable every
public update transport. Capacity inspection checks their 16 MiB headers explicitly;
public release validation retains the 8 MiB reference contract.
a separate Waveshare production job checks the registered 16 MiB production
contract, with production storage and signed updates.
The Waveshare RTC host fixture checks strict register validation, interrupted
initialization, verified SNTP writes and startup restoration, including scheduler
handoffs across clock corrections and saved skips. Hardware RTC/offline-restart
Expand Down
9 changes: 6 additions & 3 deletions .github/workflows/firmware.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,15 +41,15 @@ jobs:
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
repository: OpenAthan-Project/website
ref: ba356c80f00ff07046b7433c03e0fdc9802f64b0
ref: 407d6bb165b1e6bed91a0486a1eb37870004aef6
path: .installer-contract
persist-credentials: false
- name: Verify producer output with the real installer validator
run: python tests/check_installer_contract.py --website .installer-contract
- name: Validate developer configurations
run: |
python tools/prepare_ci.py --output-dir "$RUNNER_TEMP/audio-fixture"
for config in feasibility/baseline feasibility/calculations feasibility/shared-audio scheduler/development scheduler/device scheduler/validation openathan provisioning/validation upgrades/qualification waveshare/audio waveshare/development waveshare/diagnostics; do
for config in feasibility/baseline feasibility/calculations feasibility/shared-audio scheduler/development scheduler/device scheduler/validation openathan provisioning/validation upgrades/qualification waveshare/production waveshare/audio waveshare/development waveshare/diagnostics; do
python -m esphome config "firmware/esphome/$config.yaml" > "$RUNNER_TEMP/config.log" 2>&1 || { cat "$RUNNER_TEMP/config.log"; exit 1; }
done

Expand All @@ -59,7 +59,7 @@ jobs:
strategy:
fail-fast: false
matrix:
configuration: [device, validation, reference, provisioning-validation, upgrade-qualification, upgrade-startup-failure, waveshare-audio, waveshare-display, waveshare-diagnostics]
configuration: [device, validation, reference, provisioning-validation, upgrade-qualification, upgrade-startup-failure, waveshare-production, waveshare-audio, waveshare-display, waveshare-diagnostics]
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
Expand Down Expand Up @@ -98,6 +98,9 @@ jobs:
if [ "$CONFIGURATION" = upgrade-startup-failure ]; then
options=(-s qualification_version v0.0.3 -s qualification_startup_failure true)
fi
elif [ "$CONFIGURATION" = waveshare-production ]; then
config=firmware/esphome/waveshare/production.yaml
image=openathan
elif [ "$CONFIGURATION" = waveshare-audio ] || [ "$CONFIGURATION" = waveshare-display ] || [ "$CONFIGURATION" = waveshare-diagnostics ]; then
config=firmware/esphome/waveshare/audio.yaml
if [ "$CONFIGURATION" = waveshare-display ]; then
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

OpenAthan is an open-source, low-cost DIY Athan and Quran smart speaker project. It supports an ordinary-user reference build and a reusable ESPHome integration for people who already have compatible hardware. The reference experience is intended to work without soldering, PCB design, Home Assistant, or embedded-development experience.

> **Project status:** pre-1.0 reference releases are available. [v0.3.0](https://github.com/OpenAthan-Project/openathan/releases/tag/v0.3.0) adds a dim clock, next-prayer and playback display to standalone scheduled Athan, phone-friendly setup and settings, USB Wi-Fi/password recovery, optional prayer lights and owner-requested firmware updates for AtomS3R C126 + Pyramid A167. See the [current release evidence and limits](docs/development/release-validation-2026-10-04.md); newer ST7735 display revisions, broader hardware/network coverage and long-term stability remain unqualified.
> **Project status:** [v0.4.0](https://github.com/OpenAthan-Project/openathan/releases/tag/v0.4.0) is available for AtomS3R C126 + Pyramid A167, with standalone scheduled Athan, a display, phone-friendly setup and settings, USB Wi-Fi/password recovery and owner-requested updates. [v0.5.0 preparation](docs/development/v0.5.0-preparation-2026-10-10.md) adds Waveshare Box V2 production firmware and browser installation. That candidate has not been published; its physical production installation and update qualification remain pending. Newer Atom ST7735 display revisions remain unqualified.

Use the [public setup guide](https://openathan.com/docs/getting-started/) for a
new speaker and the [firmware update guide](docs/development/firmware-upgrades.md)
Expand Down
16 changes: 15 additions & 1 deletion docs/development/firmware-upgrades.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Firmware upgrades

Official reference firmware can check for published stable releases and install
Official production firmware can check for published stable releases and install
application-only updates from its authenticated device page. Prayer calculation,
scheduling and recordings continue to work independently of the release service.
The flow is included in published pre-1.0 reference releases. See the
Expand Down Expand Up @@ -162,3 +162,17 @@ The additive [USB application-update protocol](usb-firmware-updates.md) reuses
these trust, partition and startup contracts. It waits for owner power handoff
after selection. The companion website keeps public USB writes disabled until
new transport-specific physical qualification and a capable release are available.

## Hardware-specific releases

v0.5.0 preparation adds the Waveshare Box V2 production profile. Atom retains
`upgrade.json` and `firmware.ota.bin`; Waveshare uses
`waveshare-box-v2.upgrade.json` and `waveshare-box-v2.firmware.ota.bin`. Each
signed payload binds its hardware identity, and each device discovers only its
board's descriptor. Settings/audio formats and partition offsets remain unchanged.

USB firmware INFO accepts the legacy nine fields and appends hardware as a tenth
field in new builds. USB status also appends `hardware=<identity>` after the
existing fields/URLs; older website clients ignore it as a non-URL. The new
installer validates the identity and uses Atom compatibility for older responses.
Physical Waveshare production update qualification remains pending.
31 changes: 23 additions & 8 deletions docs/development/releases.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
# Firmware release preparation

[v0.3.0](../releases/v0.3.0.md) is the published stable reference release.
The [release evidence](release-validation-2026-10-04.md) records its exact-source
build, reference-device acceptance, public delivery and qualification limits.
[v0.4.0](../releases/v0.4.0.md) is the published stable reference release.
The v0.5.0 candidate adds Waveshare Box V2 alongside Atom. Candidate preparation
does not establish physical installer/update qualification or publication.
The [v0.4.0 preparation record](v0.4.0-preparation-2026-10-07.md) records its
automated builds and physical-validation limits. The earlier
[release evidence](release-validation-2026-10-04.md) records reference-device
acceptance and public delivery for v0.3.0.
The earlier [preparation report](v0.3.0-preparation-2026-10-03.md) retains the
matched development measurements.

Expand All @@ -14,7 +18,8 @@ schema 1.

The firmware repository builds and packages releases. The website consumes a
reviewed release; it never compiles firmware. The [installer contract](https://github.com/OpenAthan-Project/website/blob/main/installer/README.md)
remains schema v1, for AtomS3R C126 + Voice Pyramid A167, ESP32-S3 with 8 MiB flash
retains schema v1. Profiles identify AtomS3R C126 + Voice Pyramid A167
(8 MiB flash) or Waveshare Box V2 (16 MiB flash), both ESP32-S3
and the dual-2 MiB application / 3.5 MiB shared-audio layout.

The selected normal and Fajr recordings have a documented
Expand Down Expand Up @@ -46,8 +51,10 @@ python tools/release.py build --commit <full-40-character-commit-sha> \
--output-dir /tmp/openathan-build
```

The command exports source to a fresh staging directory and compiles only
`firmware/esphome/openathan.yaml`. It checks dependency pins, ESP32-S3 image
The command exports source to a fresh staging directory and compiles the registered production configuration. The default remains
`firmware/esphome/openathan.yaml`; pass
`--hardware waveshare-esp32-s3-touch-lcd-1_85c-box-v2` for
`firmware/esphome/waveshare/production.yaml`. Both builds use the same source commit. It checks dependency pins, ESP32-S3 image
checksums/digests, the actual factory partition table, empty initial NVS, matching
factory/OTA application payloads, and the 1,572,864-byte application budget.
No audio is required. Output includes both images, the source archive, build record,
Expand Down Expand Up @@ -83,7 +90,15 @@ preserves MP3 bytes, checks their approved hashes, builds the
shared partition, and executes the production C++ audio-format validator from the
source commit. Format/hash validation does not decode MP3 or replace listening tests.

Current upgrade-capable releases contain exactly seven assets:
Single-board upgrade-capable releases contain seven assets. Combined releases
contain thirteen: retain the seven Atom names below and add six Waveshare files
prefixed `waveshare-box-v2.`. Both manifests reference the same `athan-audio.bin`.
Pass `--waveshare-build-dir /tmp/openathan-waveshare-build` when packaging the Atom
build to produce the combined bundle. The two builds must share an exact commit.
Each board has its own manifest, factory, OTA, signed descriptor, checksums and
build report; Atom filenames and signed schema 1 remain compatible.

The Atom assets are:

| Asset | Purpose |
| --- | --- |
Expand All @@ -97,7 +112,7 @@ Current upgrade-capable releases contain exactly seven assets:

Only factory and audio appear in the fresh-install manifest's two parts. The
device updater consumes the separate signed descriptor and OTA application;
the website importer consumes only the manifest, factory and audio. Legacy
the website importer validates both installation and signed upgrade assets. Legacy
releases without upgrade identity retain the five-asset contract and four-file
checksum list. The report excludes raw logs, credentials and personal paths.
Existing outputs and symlink files are rejected; regenerate a changed bundle
Expand Down
81 changes: 81 additions & 0 deletions docs/development/v0.5.0-preparation-2026-10-10.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
# v0.5.0 preparation — 2026-10-10

This prepares Atom and Waveshare Box V2 production profiles, combined release
packaging and browser hardware selection. It does not publish a release or
establish new physical acceptance. No hardware access or flashing occurred.
See the [candidate release notes](../releases/v0.5.0.md).

## Configuration and artifact contract

Both profiles retain two 2 MiB application slots and separate 3.5 MiB shared
audio. Atom remains 8 MiB; Waveshare is 16 MiB with the upper flash unused.
Waveshare production uses production namespaces, enabled signed updates, round
display, BOOT controls and the merged RTC adapter. Diagnostic and isolated
storage components are excluded; development records are not migrated.

Combined packaging keeps the seven Atom asset names and adds six files prefixed
`waveshare-box-v2.`. Both manifests reference identical approved audio. Signatures
bind hardware, layout, source, version and application hash; mismatched hardware
and source commits fail validation. See [release tooling](releases.md).

The browser recognizes the additive USB hardware field, preserves legacy Atom
responses, and requires explicit model selection for unknown firmware. It checks
ESP32-S3, selected flash capacity and security before any erase/write. Discovery
and recovery do not erase data. USB application writes stay disabled in public
policy until physical qualification. Stable publication remains the approval
gate for automatic website adoption.

## Automated validation

- 18 host CTests passed with UndefinedBehaviorSanitizer.
- 112 Python tests passed, including production configuration, combined bundles,
cross-board signature rejection and isolated-material exclusion.
- Website: 180 unit tests, TypeScript/Astro checks, verified static output,
363 development browser cases and 171 built-site cases passed. Three existing
browser cases were skipped. Chromium, WebKit and narrow-screen projects cover
explicit model/erase confirmation and existing Waveshare discovery.
- Desktop and narrow-screen installer inspection passed; the UI detector
reported no findings. No new dependencies or media were added.

### Matched OTA measurements

Baseline is main `96670c1e30a9d4c16ca522ac976f41682acb3ccd`; candidate is the
prepared v0.5.0 tree. Each existing configuration was built with the same pinned
Python 3.13.5, ESPHome 2026.9.0, ESP-IDF 5.5.5 and compiler, fixed development
source identity and compile-only audio fixtures. These comparison images are
not release artifacts and must not be installed or played.

| Configuration | Before bytes | After bytes | Delta | Budget remaining |
| --- | ---: | ---: | ---: | ---: |
| Atom production | 1,276,752 | 1,277,360 | +608 | 295,504 |
| Waveshare isolated audio | 1,212,912 | 1,213,344 | +432 | 359,520 |
| Waveshare isolated display | 1,262,864 | 1,263,312 | +448 | 309,552 |
| Waveshare diagnostics | 1,349,792 | 1,350,224 | +432 | 222,640 |
| Waveshare production, new profile | — | 1,284,752 | — | 288,112 |

All five passed capacity inspection, including dependency pins, factory/OTA
agreement, flash headers, partition layout and the 1,572,864-byte application
budget. Waveshare production retains 812,400 bytes free in its 2 MiB slot.
Static measurements do not establish runtime heap, fragmentation or PSRAM
headroom with concurrent audio/network/display activity.

## Hardware evidence and remaining work

Earlier attended development evidence covers stored playback, display, setup,
buttons and preservation within the source limits in the
[Waveshare validation reports](waveshare-box-v2.md). It does not qualify this new
production namespace or signed release installation. Intermittent HTTP timeouts
remain unresolved; see the [network follow-up](waveshare-network-development-2026-10-09.md).

Pending: attended production fresh installation, real signed public-feed OTA,
rollback/interruption and recovery, production settings/history/audio preservation,
and listening with the [new volume mapping](waveshare-volume-build-2026-10-10.md).
The [RTC powered-restart acceptance](waveshare-rtc-validation-2026-10-10.md) is
also pending. Battery retention and drift remain unqualified capabilities.
Reuse earlier accepted evidence where applicable without claiming it covers
changed code or exact candidate runtime behavior.

Draft PR review, merge, an exact merged-source rebuild, release/tag upload,
physical qualification and explicit stable publication are separate steps.
No tag, draft release upload, publication or website deployment is part of this
preparation.
34 changes: 27 additions & 7 deletions docs/development/waveshare-box-v2.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Waveshare Box V2 development profile
# Waveshare Box V2 profiles

The ESP32-S3-Touch-LCD-1.85C-BOX **V2** development profile reuses standalone
prayer calculations, scheduling, stored recordings, USB provisioning and the
Expand All @@ -23,9 +23,11 @@ The chip is configured for 16 MB flash and 8 MB octal PSRAM. The existing
the lower 8 MiB: two 2 MiB application slots and separate 3.5 MiB shared audio.
Additional flash is unused. Each OTA image must remain at or below 1,572,864
bytes. `check_feasibility.py` recognizes the explicit Waveshare hardware define
and requires 16 MiB image headers, isolated storage and disabled updates.
The public release validator still defaults to 8 MiB reference images and
rejects isolated development firmware.
and requires 16 MiB image headers. Development also requires isolated storage
and disabled updates; the registered production configuration enables updates.
The release validator selects the registered hardware profile and continues to
reject isolated development firmware. Production uses the same lower-8-MiB
partition layout; additional flash remains unused.

Wi-Fi power saving is disabled in this board profile following the attended
LIGHT/NONE comparison. HTTP timeouts remain unresolved; see the dated report for
Expand All @@ -42,11 +44,11 @@ load production settings or consumption history.

`firmware.hardware` and `firmware.updates_enabled` are additive status fields.
Existing clients can ignore them; the local UI treats a missing update flag as
enabled for older firmware. Waveshare sets it to false: automatic discovery,
enabled for older firmware. Development sets it to false: automatic discovery,
authenticated check/install/cancel requests and USB update writes are rejected.
USB provisioning and healthy application startup confirmation remain enabled.
These builds cannot be installed through the public updater or published as
reference releases. Maintainer installation/recovery uses esptool in an attended
Isolated builds cannot be installed through the public updater or published as
production releases. Maintainer installation/recovery uses esptool in an attended
session.

## Hardware adapters
Expand Down Expand Up @@ -206,3 +208,21 @@ to 60 minutes and retain memory/error observations. Distinguish physical power
cycling from software restart, and queued playback from audible acceptance.
Prefer compatible application-only recovery after initial partition migration;
a full-flash restore also restores historical settings and prayer consumption.

## Production release candidate

`firmware/esphome/waveshare/production.yaml` is the v0.5.0 production candidate.
It uses `openathan` with a MAC suffix, production settings/setup/network/upgrade
storage, round display, BOOT controls and signed updates. It omits diagnostic and
isolated-storage components. Existing isolated development records are not migrated.
The merged RTC adapter is retained in production with its existing powered-reset
behavior and qualification limits.

Release bundles use `waveshare-box-v2.` filenames for this board and share the
approved audio partition with Atom. The website selects matching firmware from
reported OpenAthan USB hardware identity; unknown firmware requires explicit
model and erase confirmation. See [release preparation](releases.md).

The [v0.5.0 preparation report](v0.5.0-preparation-2026-10-10.md) separates
automated evidence from pending production installation, update/recovery and
new volume-mapping listening qualification. No new physical acceptance is claimed.
4 changes: 2 additions & 2 deletions docs/releases/v0.4.0.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# OpenAthan v0.4.0

Release preparation. This version has not been published.
Published stable release: [v0.4.0](https://github.com/OpenAthan-Project/openathan/releases/tag/v0.4.0).

The speaker's local device page now puts the next prayer and everyday controls
within easy reach on phones and desktops.
Expand Down Expand Up @@ -30,7 +30,7 @@ partition layout and Home Assistant independence are unchanged.

## Updating your speaker

After this release is published, speakers running v0.2.1 or v0.3.0 can check for
Speakers running v0.2.1 or v0.3.0 can check for
updates on their device page and choose **Install update**. Compatible application
updates preserve settings, credentials, prayer history and stored audio.

Expand Down
Loading