Skip to content

Commit ad6a315

Browse files
committed
Fix second route of logic for ADC volts
1 parent 708f830 commit ad6a315

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/components/analogIO/Wippersnapper_AnalogIO.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -386,7 +386,7 @@ void Wippersnapper_AnalogIO::update() {
386386
// Perform voltage conversion if we need to
387387
if (_analog_input_pins[i].readMode ==
388388
wippersnapper_pin_v1_ConfigurePinRequest_AnalogReadMode_ANALOG_READ_MODE_PIN_VOLTAGE) {
389-
pinValVolts = pinValRaw * getAref() / 65536;
389+
pinValVolts = getPinValueVolts(_analog_input_pins[i].pinName);
390390
}
391391

392392
// Publish pin event to IO

0 commit comments

Comments
 (0)