Refactor patterns to use preset-based API and fix initialization order

- Fix initialization order: initialize self.presets before calling self.select()
- Separate add() and edit() methods: add() creates new presets, edit() updates existing ones
- Update all test files to use add() instead of edit() for creating presets
- Add comprehensive auto/manual mode test
- Remove tool.py (moved to led-tool project)
This commit is contained in:
2026-01-25 23:23:14 +13:00
parent f4ef415b5a
commit b7d2f52fc3
16 changed files with 1593 additions and 1105 deletions

View File

@@ -20,3 +20,4 @@ python_version = "3"
[scripts]
dev = 'watchfiles "./dev.py /dev/ttyACM0 src reset follow"'
web = "uvicorn tool:app --host 0.0.0.0 --port 8080"
install = "pipenv install"