28 Jun, 2016

2 commits

  • The result of an integer divide by an unsigned is undefined.
    This causes unexpected results when writing negative values
    into the limit registers.

    Maintain the shunt_resistors variables as signed integer to avoid
    the problem. Also, for simplicity and ease of use, clamp shunt
    resistor value on writes instead of rejecting bad values.

    Cc: Andrew F. Davis
    Acked-by: Andrew F. Davis
    Signed-off-by: Guenter Roeck

    Guenter Roeck
     
  • Add support for the the INA3221 26v capable, Triple channel,
    Bi-Directional, Zero-Drift, Low-/High-Side, Current/Voltage Monitor
    with I2C interface.

    Signed-off-by: Andrew F. Davis
    Signed-off-by: Guenter Roeck

    Andrew F. Davis