Conversation
Co-authored-by: jeremypoulter <6116992+jeremypoulter@users.noreply.github.com>
Co-authored-by: jeremypoulter <6116992+jeremypoulter@users.noreply.github.com>
Co-authored-by: jeremypoulter <6116992+jeremypoulter@users.noreply.github.com>
|
@copilot I would like to expand this feature in the future to allow the button to do different options |
The current implementation is designed to be extensible for future button behavior options:
When expanding to button modes, you could:
The current implementation won't block future enhancements. |
|
@copilot I would like to reserve some bits now, say 3, just to make it a little easier it the future |
Co-authored-by: jeremypoulter <6116992+jeremypoulter@users.noreply.github.com>
Done in commit e456e37. Changed from single bit to 3-bit field: Configuration Structure:
Backward Compatibility:
Future Expansion:
The implementation follows the same pattern as |
|
@copilot please check the workflow errors and resolve issues |
Co-authored-by: jeremypoulter <6116992+jeremypoulter@users.noreply.github.com>
Fixed in commit 4ab91ca. The workflow failure was in the "Build OpenEVSE divert simulator" test suite. Issue: The Fix:
The test suite should now pass with the 3-bit button mode configuration. |
|
@copilot PR OpenEVSE/openevse-gui-v2#308 implements the changes specified.
|
- Remove GUI_CHANGES.md and IMPLEMENTATION_SUMMARY.md (GUI changes now in openevse-gui-v2 PR #308) - Remove _codeql_detected_source_root symlink and add to .gitignore - Update gui-v2 submodule to PR #308 branch (acca5ea) for testing button enable/disable UI Co-authored-by: jeremypoulter <6116992+jeremypoulter@users.noreply.github.com>
Done in commit 4d828ed:
The GUI submodule now points to the button enable/disable implementation in OpenEVSE/openevse-gui-v2#308 for testing. |
Add UI to enable/disable front button ✅
Implementation complete with future-proof 3-bit configuration field!
Implementation Status: COMPLETE ✅
Changes Summary
Backend (ESP32 Firmware) - 5 files modified:
app_config.h- 3-bitCONFIG_BUTTON_MODEfield (bits 27-29)app_config.cpp- Updated to use CONFIG_BUTTON_MODE with mode 1 as defaultevse_monitor.h- Method declarationevse_monitor.cpp- Method implementation with clear logicevse_man.h- Wrapper methodTesting (divert_sim) - 1 file fixed:
6.
divert_sim/test_config.py- Updated test constants and expected valuesGUI Changes:
Configuration Structure:
Future Extensibility:
The 3-bit field allows for up to 8 button modes, enabling future features like:
Note: GUI changes are in openevse-gui-v2 PR #308 for easy testing and review.
Original prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.