Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documented Boot Behavior enumeration and its members #118

Merged
merged 3 commits into from
Nov 12, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 35 additions & 4 deletions src/sleepTask.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,34 @@ class SleepTask : public Task {
STATES_e run(void);
void exit(void);

/**
* @brief Defines possible boot behaviors
*/
typedef enum BOOT_BEHAVIOR_
{
/**
* @brief Standard boot behavior
*/
BOOT_BEHAVIOR_NORMAL=0,
/**
* @brief Initiate temperature calibration on startup
*/
BOOT_BEHAVIOR_TMP_CAL_START=1,
/**
* @brief Continue temperature calibration sequence
*/
BOOT_BEHAVIOR_TMP_CAL_CONTINUE=2,
/**
* @brief End temperature calibration
*/
BOOT_BEHAVIOR_TMP_CAL_END=3,
/**
* @brief Reattempts data upload
*/
BOOT_BEHAVIOR_UPLOAD_REATTEMPT=4,
/**
* @brief Boot behavior is not specified
*/
BOOT_BEHAVIOR_NOT_SET=255
} BOOT_BEHAVIOR_e;

Expand All @@ -36,18 +57,28 @@ class SleepTask : public Task {
static const char* strBootBehavior(BOOT_BEHAVIOR_e behavior);
/**
* @brief Updates boot behavior to NVRAM
*/
static void setBootBehavior(BOOT_BEHAVIOR_e);
*
* @param behavior Boot Behavior to set
*/
static void setBootBehavior(BOOT_BEHAVIOR_e behavior);
/**
* @brief Get's current boot behavior from NVRAM
*/
*
* @return Current Boot Behavior
*/
static BOOT_BEHAVIOR_e getBootBehavior(void);
/**
* @brief Load boot behavior onto board
*/
*/
static void loadBootBehavior(void);
private:
/**
* @brief Stores current Boot Behavior
*/
static BOOT_BEHAVIOR_e bootBehavior;
/**
* @brief Manages LED status display settings
*/
LEDStatus ledStatus;
};
#endif
Loading