-
-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
24 additions
and
3 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,13 @@ | ||
/** | ||
* @file movingAvg.h | ||
* @author Frédéric Metrich ([email protected]) | ||
* @brief Code for sliding-window average | ||
* @version 0.1 | ||
* @date 2023-06-14 | ||
* | ||
* @copyright Copyright (c) 2023 | ||
* | ||
*/ | ||
|
||
#ifndef MOVINGAVG_H | ||
#define MOVINGAVG_H | ||
|
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,14 @@ | ||
/** | ||
* @file type_traits.hpp | ||
* @author Frédéric Metrich ([email protected]) | ||
* @brief Some useful but missing stl functions templates | ||
* @version 0.1 | ||
* @date 2023-06-14 | ||
* | ||
* @copyright Copyright (c) 2023 | ||
* | ||
*/ | ||
|
||
// ArduinoJson - https://arduinojson.org | ||
// Copyright © 2014-2023, Benoit BLANCHON | ||
// MIT License | ||
|
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
/** | ||
* @file utils_relay.h | ||
* @author Frédéric Metrich ([email protected]) | ||
* @brief | ||
* @brief Some utility functions for the relay output feature | ||
* @version 0.1 | ||
* @date 2023-03-31 | ||
* | ||
|
@@ -226,8 +226,8 @@ template< uint8_t T = 1 > class relayOutput | |
const uint16_t minON{ 5 * 60 }; /**< Minimum duration in seconds the relay is turned ON */ | ||
const uint16_t minOFF{ 5 * 60 }; /**< Minimum duration in seconds the relay is turned OFF */ | ||
|
||
uint16_t duration{ 0 }; /**< Duration of the current state */ | ||
bool relayState{ false }; /**< State of the relay */ | ||
uint16_t duration{ 0 }; /**< Duration of the current state */ | ||
bool relayState{ false }; /**< State of the relay */ | ||
|
||
static inline movingAvg< int16_t, T * 60 / DATALOG_PERIOD_IN_SECONDS > sliding_Average; | ||
}; | ||
|