Loadvoltage = busvoltage + (shuntvoltage / 1000) Shuntvoltage = ina219.getShuntVoltage_mV() Open serial communications and wait for port to open: Serial. # include "Wire.h" # include "Adafruit_INA219.h" If you want to know how I2C is able to transfer data between electrical devices, I recommend my I2C tutorial. Power: current multiplied by the bus voltageĮach of the measurements and calculations are stored in a register that is connected to the I2C interface to forward the values to the Arduino or ESP microcontroller.Current: derived via Ohms Law from the measured shunt voltage.Bus voltage: total voltage seen by the circuit under test.Shunt voltage: voltage drop across the shunt resistor.Therefore the INA219 is able to provide four different measurements: Based on the maximum current of 3.2A and a maximum bus voltage of 26V, the INA219 can measure up to 3.2A * 26V = 83W of power. Then the power is calculated with this current multiplied with the bus voltage. Because the shunt resistor is 0.1Ω and the maximum shunt voltage at the scale of 8 is 320mV, the maximum current that can be measured is 320mV / 0.1Ω = 3.2A. The current flow on the high side of the measurement is calculated by multiplying the shunt voltage with the calibrated resistance of the shunt resistor.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |