comment unused PZEM non-measurements
This commit is contained in:
parent
520e5fac16
commit
cf44707281
@ -133,9 +133,11 @@ struct sensor_pzem_measurement_t sensor_pzem_measurement_decode(void)
|
||||
case SENSOR_PZEM_ENERGY:
|
||||
measurement.value.energy = ((uint32_t)rx_buffer[1]<<16)+((uint16_t)rx_buffer[2]<<8)+rx_buffer[3];
|
||||
break;
|
||||
/* not used in this application
|
||||
case SENSOR_PZEM_ADDRESS:
|
||||
case SENSOR_PZEM_ALARM:
|
||||
break; // no value is returned
|
||||
*/
|
||||
default:
|
||||
measurement.valid = false; // unexpected type
|
||||
}
|
||||
|
@ -29,8 +29,8 @@ enum sensor_pzem_measurement_type_t {
|
||||
SENSOR_PZEM_CURRENT = 1,
|
||||
SENSOR_PZEM_POWER = 2,
|
||||
SENSOR_PZEM_ENERGY = 3,
|
||||
SENSOR_PZEM_ADDRESS = 4,
|
||||
SENSOR_PZEM_ALARM = 5,
|
||||
// SENSOR_PZEM_ADDRESS = 4, // this is a setting, not a measurement
|
||||
// SENSOR_PZEM_ALARM = 5, // this is a setting, not a measurement
|
||||
SENSOR_PZEM_MAX
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user