rebase: Phase B — trivial files for the v0.6.0 base

Build-system, config, usb, and CI wiring on top of upstream's
v0.6.0-hotfix tree. Build will still fail until Phase C+D land bt.h
accessors that oled.cpp references; that's expected mid-rebase.

CMakeLists.txt: add src/oled.cpp + src/slots.cpp to add_executable,
link hardware_spi, restore OUTPUT_NAME ds5-bridge-oled.

src/config.h: append the 4 OLED Edition Config_body fields
(current_slot + auto_haptics_enable/gain/lowpass). Preserves
upstream's field order for the first 8 fields.

src/config.cpp:
- speaker_volume validity default -100 dB → 0 dB (footgun fix)
- 4 new validity guards for the appended fields with sensible
  defaults (Fallback / 100 % / 160 Hz / slot 0)
- config_default() impl (was declared in upstream's config.h since
  v0.5.4 but never defined; the OLED Edition's "Reset to defaults"
  Settings item calls it)

src/usb.cpp: drop the UAC1 SET_CUR Volume → flash-config sync that
let PipeWire/Pulse silently override the user's saved Spk Vol on
every device reconnect. Borrowed from loteran/DS5Dongle commit
03fa1e4.

src/usb_descriptors.cpp: restore iSerialNumber = STRID_SERIAL.
Upstream's commit e79c762 zeroed it to work around SpecialK (#32),
but that broke Windows device identity (#100) — users lost
per-device volume / app preferences when moving USB ports. The
OLED Edition prioritizes Windows device-identity stability for
the broader user base over SpecialK compat for a narrower one.

.github/workflows/{build,release}.yml: artifact filenames use
ds5-bridge-oled.uf2 (and -debug / -picow variants) per the
OUTPUT_NAME rebrand.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
MarcelineVPQ
2026-05-17 07:53:41 -06:00
co-authored by Claude Opus 4.7
parent 0ed05d3f56
commit 4b6a72b70a
22 changed files with 2087 additions and 17 deletions
+6 -6
View File
@@ -86,7 +86,7 @@ jobs:
-DVERSION="$FIRMWARE_VERSION"
cmake --build build/standard --target ds5-bridge
mkdir -p artifacts
cp build/standard/ds5-bridge.uf2 artifacts/ds5-bridge.uf2
cp build/standard/ds5-bridge-oled.uf2 artifacts/ds5-bridge-oled.uf2
- name: Build Debug firmware
run: |
@@ -97,7 +97,7 @@ jobs:
-DENABLE_VERBOSE=ON \
-DVERSION="$FIRMWARE_VERSION"
cmake --build build/debug --target ds5-bridge
cp build/debug/ds5-bridge.uf2 artifacts/ds5-bridge-debug.uf2
cp build/debug/ds5-bridge-oled.uf2 artifacts/ds5-bridge-oled-debug.uf2
- name: Build no-batt-led firmware (compile check only)
run: |
@@ -116,25 +116,25 @@ jobs:
-DPICO_W_BUILD=ON \
-DVERSION="$FIRMWARE_VERSION"
cmake --build build/picow --target ds5-bridge
cp build/picow/ds5-bridge.uf2 artifacts/ds5-bridge-picow.uf2
cp build/picow/ds5-bridge-oled.uf2 artifacts/ds5-bridge-oled-picow.uf2
- name: Upload standard UF2 artifact
uses: actions/upload-artifact@v7
with:
path: artifacts/ds5-bridge.uf2
path: artifacts/ds5-bridge-oled.uf2
archive: false
if-no-files-found: error
- name: Upload Debug UF2 artifact
uses: actions/upload-artifact@v7
with:
path: artifacts/ds5-bridge-debug.uf2
path: artifacts/ds5-bridge-oled-debug.uf2
archive: false
if-no-files-found: error
- name: Upload PicoW UF2 artifact
uses: actions/upload-artifact@v7
with:
path: artifacts/ds5-bridge-picow.uf2
path: artifacts/ds5-bridge-oled-picow.uf2
archive: false
if-no-files-found: error
+2 -2
View File
@@ -91,7 +91,7 @@ jobs:
-DVERSION="$FIRMWARE_VERSION"
cmake --build build/standard --target ds5-bridge
mkdir -p artifacts
cp build/standard/ds5-bridge.uf2 "artifacts/ds5-bridge-${{ github.event.release.tag_name }}.uf2"
cp build/standard/ds5-bridge-oled.uf2 "artifacts/ds5-bridge-oled-${{ github.event.release.tag_name }}.uf2"
- name: Build Debug firmware
run: |
@@ -102,7 +102,7 @@ jobs:
-DENABLE_VERBOSE=ON \
-DVERSION="$FIRMWARE_VERSION"
cmake --build build/debug --target ds5-bridge
cp build/debug/ds5-bridge.uf2 "artifacts/ds5-bridge-debug-${{ github.event.release.tag_name }}.uf2"
cp build/debug/ds5-bridge-oled.uf2 "artifacts/ds5-bridge-oled-debug-${{ github.event.release.tag_name }}.uf2"
- name: Upload UF2 files to release
env: