44 SUB_SENSOR(bus_voltage)
45 SUB_SENSOR(shunt_voltage)
50 void setup()
override;
51 void dump_config()
override;
52 void update()
override;
54 void set_shunt_resistance_ohm(
float shunt_resistance_ohm) {
shunt_resistance_ohm_ = shunt_resistance_ohm; }
55 void set_max_current_a(
float max_current_a) {
max_current_a_ = max_current_a; }
virtual void setup()
Where the component's initialization should happen.
This class simplifies creating components that periodically check a state.
This Class provides the methods to read/write bytes from/to an i2c device.
AdcTime adc_time_voltage_
AdcTime adc_time_current_
float shunt_resistance_ohm_
AdcAvgSamples adc_avg_samples_
uint32_t calibration_lsb_
struct @66::@67 __attribute__
Wake the main loop task from an ISR. ISR-safe.
AdcAvgSamples avg_samples
AdcTime shunt_voltage_conversion_time
AdcTime bus_voltage_conversion_time