fix INA3221 sensor (#4168)

- pass wire to begin()
- remove redundant setAddr() (already set in header)
This commit is contained in:
Warren Guy 2024-06-23 21:40:13 +01:00 committed by GitHub
parent f5098dc6d8
commit 23ac6b6514
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -16,8 +16,7 @@ int32_t INA3221Sensor::runOnce()
return DEFAULT_SENSOR_MINIMUM_WAIT_TIME_BETWEEN_READS;
}
if (!status) {
ina3221.setAddr(INA3221_ADDR42_SDA); // i2c address 0x42
ina3221.begin();
ina3221.begin(nodeTelemetrySensorsMap[sensorType].second);
ina3221.setShuntRes(100, 100, 100); // 0.1 Ohm shunt resistors
status = true;
} else {