Backport: Add header guards and clean up Button/TimeControl (master-c)#154
Merged
livingkurt merged 1 commit intomaster-cfrom Mar 28, 2026
Merged
Conversation
Port of master PR #152 cleanup changes to the master-c branch: - Add proper #ifndef/#define guard to ColorConstants.h (replacing #pragma once) - Rename Colortypes.h guard from COLOR_H to COLORTYPES_H to match filename - Remove helios_wakeup() from embedded ISR (not used on embedded) - Extract repeated time_get_current_time() calls into const local variable in button_update() for clarity - Remove unused Led.h include from TimeControl.cpp, reorder includes - Update TimeControl.h comments on time_get_current_time() and time_microseconds() for clarity Made-with: Cursor
Unreal-Dan
approved these changes
Mar 27, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Port of master PR #152 cleanup changes to the
master-cbranch (C language port). Only the changes applicable to the C codebase are included — the C branch already has proper header guards on most files, so the delta is smaller.#ifndef/#defineguard toColorConstants.h(replacing#pragma once)Colortypes.hguard fromCOLOR_H→COLORTYPES_Hto match the filenamehelios_wakeup()from embedded ISR inButton.cpp— not needed on embedded, same as the C++ branch fixtime_get_current_time()calls into aconstlocal variable inbutton_update()for clarityLed.hinclude fromTimeControl.cpp, reorder includes to put local headers firstTimeControl.hcomments ontime_get_current_time()andtime_microseconds()for clarity — removes stale vortexlib reference, adds clear warning on microseconds APITest plan
Made with Cursor