Browse Source

Fix errors

v2
Xose Pérez 6 years ago
parent
commit
448d30b9a6
2 changed files with 3 additions and 3 deletions
  1. +1
    -1
      code/espurna/light.ino
  2. +2
    -2
      code/espurna/sensor.ino

+ 1
- 1
code/espurna/light.ino View File

@ -1061,7 +1061,7 @@ void lightSetup() {
const char * map = getSetting("myMapping", "").c_str();
unsigned char channels = strlen(map);
for (unsigned char i=0; i<channels; i++) {
_light_channel.push_back((channel_t) {0, false, true, 0, 0, 0, 0, 1, map[i] - '0'});
_light_channel.push_back((channel_t) {0, false, true, 0, 0, 0, 0, 1, (unsigned char) map[i] - '0'});
}
}


+ 2
- 2
code/espurna/sensor.ino View File

@ -850,8 +850,8 @@ void _sensorConfigure() {
// Update filter sizes
for (unsigned char i=0; i<_magnitudes.size(); i++) {
sensor_magnitude_t magnitude = _magnitudes[i];
_magnitude.filter->resize(_sensor_report_every);
_magnitude.min_change = getSetting("tmpDelta", magnitude.type, 0).toFloat();
magnitude.filter->resize(_sensor_report_every);
magnitude.min_change = getSetting("tmpDelta", magnitude.type, 0).toFloat();
}
// Save settings


Loading…
Cancel
Save