Files
L'électron rare 527c3a3b9d
CI / sanity (push) Successful in 14s
CI / host-tests (push) Successful in 25s
CI / box3-build (push) Failing after 11s
CI / build (push) Successful in 4m11s
fix: SD buffer ownership, input switch, MIDI rate
Backlog from the code review, all verified building:

- SD ownership barrier (Loop_SetSdBusy): while sd_module reads or
  writes the track buffers from core 0, the audio path performs no
  writes to them and MIDI/touch cannot re-arm recording or erasing.
  A MIDI track select during a save used to produce a WAV mixing
  old and new audio; a pending erase corrupted the saved take.
- MTLooper_ToggleSource now actually drives the ES8388
  (ES8388_SetInputCh 0 = mic on LIN1/RIN1, 1 = line on LIN2/RIN2).
  Only the AC101 path was wired, so on this board the UI claimed
  'Microphone' while the input stayed on line.
- loop() prescalers were off by SAMPLE_BUFFER_SIZE: one iteration
  is a block, not a sample. loop_1Hz fired every 48 s; MIDI was
  processed every ~70 ms, long enough to overflow the 256 byte
  serial RX buffer on dense controller sweeps. MIDI is now polled
  once per block.
- Box-3 tempo button wrapped to 60 BPM, below the looper floor
  (~85 BPM for an 11.3 s max loop), so it looked broken. Wraps to
  90 now.
- link RX byte counter on the console (wiring diagnostics).
- CI runs the host protocol tests (C + pytest) and builds the
  Box-3 firmware in the espressif/idf:v5.4 container.
2026-08-06 01:34:53 +02:00

76 lines
1.8 KiB
YAML

name: CI
on:
push:
branches: [main, master]
pull_request:
permissions:
contents: read
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
sanity:
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- uses: actions/checkout@v4
- name: Sanity
run: |
test -f README.md || test -f Readme.md || test -f readme.md || test -f README
echo "Repository sanity OK"
build:
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Cache PlatformIO
uses: actions/cache@v4
with:
path: |
~/.platformio
.pio
key: pio-${{ runner.os }}-${{ hashFiles('platformio.ini') }}
- name: Install PlatformIO
run: pip install platformio
- name: Build (arduino-esp32 2.0.2)
run: pio run -e esp32_audio_kit_es8388
host-tests:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Link protocol test (C)
run: |
cc -Wall -Werror -o /tmp/test_link tests/test_link_protocol.c
/tmp/test_link
- name: Link protocol test (Python)
run: |
pip install pytest
python -m pytest tests/test_link_sim.py -v
box3-build:
runs-on: ubuntu-latest
timeout-minutes: 30
container: espressif/idf:v5.4
steps:
- uses: actions/checkout@v4
- name: Build Box-3 firmware
shell: bash
run: |
. $IDF_PATH/export.sh
cd box3_display
idf.py set-target esp32s3
idf.py build