Merge branch 'develop' into feat/ledbar-sensor-indicator

This commit is contained in:
Samuel Siburian
2024-11-03 14:12:57 +07:00
committed by GitHub
27 changed files with 2248 additions and 1069 deletions
+4 -4
View File
@@ -69,7 +69,7 @@ void StateMachine::sensorhandleLeds(void) {
*
*/
void StateMachine::co2handleLeds(void) {
int co2Value = value.CO2;
int co2Value = value.get(Measurements::CO2);
if (co2Value <= 700) {
/** G; 1 */
ag->ledBar.setColor(RGB_COLOR_G, ag->ledBar.getNumberOfLeds() - 1);
@@ -141,9 +141,9 @@ void StateMachine::co2handleLeds(void) {
*
*/
void StateMachine::pm25handleLeds(void) {
int pm25Value = value.pm25_1;
if (config.isMonitorDisplayCompensatedValues() && config.hasSensorSHT) {
pm25Value = ag->pms5003.compensate(value.pm25_1, value.Humidity);
int pm25Value = value.get(Measurements::PM25);
if (config.hasSensorSHT && config.isPMCorrectionEnabled()) {
pm25Value = (int)value.getCorrectedPM25(*ag, config);
}
if (pm25Value <= 5) {