You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At 332:
readInafromEEPROM(deviceNumber); // Load EEPROM to ina structure
ina.maxBusAmps = maxBusAmps > 1022 ? 1022 : maxBusAmps; // Clamp to maximum of 1022A
ina.microOhmR = microOhmR;
initDevice(deviceNumber);
--------------- Should be:
readInafromEEPROM(deviceNumber); // Load EEPROM to ina structure
inaEE.maxBusAmps = maxBusAmps > 1022 ? 1022 : maxBusAmps; // Clamp to maximum of 1022A
inaEE.microOhmR = microOhmR;
ina = inaEE; // to execute inaDet with the new values.
initDevice(deviceNumber);
This makes no sense
_DeviceCount = ((_DeviceCount + 1) % maxDevices); // start again at 0 if overflow
maxDevices should match _expectedDevices when nonzero and of course, _DeviceCount should not overflow back to 0.
if _expectedDevices is nonzero then do not call EEPROM.begin
The text was updated successfully, but these errors were encountered:
I had this issue as well with using three different shunt resistors and maxBusAmps. @SV-Zanshin, is there a plan when that fix can be released? Shall we create a pull request?
At 332:
readInafromEEPROM(deviceNumber); // Load EEPROM to ina structure
ina.maxBusAmps = maxBusAmps > 1022 ? 1022 : maxBusAmps; // Clamp to maximum of 1022A
ina.microOhmR = microOhmR;
initDevice(deviceNumber);
--------------- Should be:
readInafromEEPROM(deviceNumber); // Load EEPROM to ina structure
inaEE.maxBusAmps = maxBusAmps > 1022 ? 1022 : maxBusAmps; // Clamp to maximum of 1022A
inaEE.microOhmR = microOhmR;
ina = inaEE; // to execute inaDet with the new values.
initDevice(deviceNumber);
This makes no sense
_DeviceCount = ((_DeviceCount + 1) % maxDevices); // start again at 0 if overflow
maxDevices should match _expectedDevices when nonzero and of course, _DeviceCount should not overflow back to 0.
if _expectedDevices is nonzero then do not call EEPROM.begin
The text was updated successfully, but these errors were encountered: