Browse Source

Fix typos

pull/1301/head
Xose Pérez 5 years ago
parent
commit
5337b5303a
3 changed files with 4 additions and 3 deletions
  1. +1
    -1
      code/espurna/config/sensors.h
  2. +1
    -0
      code/espurna/config/types.h
  3. +2
    -2
      code/espurna/sensors/PulseMeterSensor.h

+ 1
- 1
code/espurna/config/sensors.h View File

@ -590,7 +590,7 @@
#endif
#ifndef PULSEMETER_PIN
#define PULSEMETERL_PIN 5
#define PULSEMETER_PIN 5
#endif
#ifndef PULSEMETER_ENERGY_RATIO


+ 1
- 0
code/espurna/config/types.h View File

@ -285,6 +285,7 @@
//--------------------------------------------------------------------------------
// Magnitudes
// These should remain over time, do not modify their values, only add new ones at the end
//--------------------------------------------------------------------------------
#define MAGNITUDE_NONE 0


+ 2
- 2
code/espurna/sensors/PulseMeterSensor.h View File

@ -80,7 +80,7 @@ class PulseMeterSensor : public BaseSensor {
// Address of the sensor (it could be the GPIO or I2C address)
String address(unsigned char index) {
return String(gpio);
return String(_gpio);
}
// Pre-read hook (usually to populate registers with up-to-date data)
@ -169,7 +169,7 @@ class PulseMeterSensor : public BaseSensor {
PulseMeterSensor * _pulsemeter_sensor_instance[10] = {NULL};
void ICACHE_RAM_ATTR _pulseMeter_sensor_isr(unsigned char gpio) {
void ICACHE_RAM_ATTR _pulsemeter_sensor_isr(unsigned char gpio) {
unsigned char index = gpio > 5 ? gpio-6 : gpio;
if (_pulsemeter_sensor_instance[index]) {
_pulsemeter_sensor_instance[index]->handleInterrupt(gpio);


Loading…
Cancel
Save