Contributor Spotlight: Mike (drmikecrypto) — CLI Parser Test Suite & Sensor Driver Documentation #71
angeloINTJ
announced in
Announcements
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Every contribution makes SIMUT better. This series highlights the people behind the commits.
This week: @drmikecrypto
What he built: A host-testable CLI parser extracted from the firmware core, a 20-test unit suite covering every command path, and a complete sensor-driver walkthrough for new contributors.
Why it matters: SIMUT's USB serial CLI has zero authentication. A parser bug can wipe sensor config, change WiFi credentials, or trigger factory reset — all without auth. Before this PR, the parser lived inside
CommandManager, a class that depends on Bluetooth, Serial, LittleFS, and a dozen other subsystems. Testing it required hardware or a mountain of stubs.Mike extracted
parseCliCommand()into a standaloneCommandParser.cppwith zero I/O dependencies. It compiles on any machine with GCC. The same production code that runs on the Pico W now runs under 20 unit tests in under half a second:What the tests cover:
help,ajuda,?)show system info,show sensorswith extra whitespaceconfirmsuffix detection (clear log confirm)conf user add/delwith and without passwordssensor 4 tmin -5.0) and invalid GPIO rejectionconfalone → unknown)café-π) and 256-char boundary linesThe documentation: 202 lines in
docs/adding-a-new-sensor.md— a practical guide covering the mental model, the 4 touch points needed to add a driver, a step-by-step skeleton following the async state machine pattern, rules learned in production, flash checklist, and in-tree examples (DS18B20, DHT22, BME280).This closes the tutorial gap from #63 and gives future sensor contributors a clear path.
Stats:
native_clienvironmentWhat the maintainer said:
Related: PR #70 · Issue #42 · Issue #63
Want to be featured here? Pick up any good first issue and submit a PR. We celebrate every contribution — code, tests, documentation, hardware, and infrastructure. 🎉
Beta Was this translation helpful? Give feedback.
All reactions