|  | 
|  | 1 | +.. _adafruit_ina228: | 
|  | 2 | + | 
|  | 3 | +Adafruit INA228 Shield | 
|  | 4 | +############################# | 
|  | 5 | + | 
|  | 6 | +Overview | 
|  | 7 | +******** | 
|  | 8 | + | 
|  | 9 | +The `Adafruit INA228 High or Low Side Power Monitor`_ features the | 
|  | 10 | +`TI INA228 current sensor`_, an I2C 20-bit power monitoring chip, with two | 
|  | 11 | +STEMMA QT connectors. This board is capable of measuring up to 85VDC | 
|  | 12 | +common-mode, high or low side measurements ranging from milli-amps to amps. | 
|  | 13 | + | 
|  | 14 | +.. figure:: adafruit_ina228.webp | 
|  | 15 | +   :align: center | 
|  | 16 | +   :alt: Adafruit INA228 Shield | 
|  | 17 | + | 
|  | 18 | +   Adafruit INA228 Shield (Credit: Adafruit) | 
|  | 19 | + | 
|  | 20 | + | 
|  | 21 | +Requirements | 
|  | 22 | +************ | 
|  | 23 | + | 
|  | 24 | +This shield can be used with boards which provide an I2C connector, for | 
|  | 25 | +example STEMMA QT or Qwiic connectors. | 
|  | 26 | +The target board must define a ``zephyr_i2c`` node label. | 
|  | 27 | +See :ref:`shields` for more details. | 
|  | 28 | + | 
|  | 29 | + | 
|  | 30 | +Pin Assignments | 
|  | 31 | +=============== | 
|  | 32 | + | 
|  | 33 | ++--------------+-------------------+ | 
|  | 34 | +| Shield Pin   | Function          | | 
|  | 35 | ++==============+===================+ | 
|  | 36 | +| SDA          | INA228 I2C SDA    | | 
|  | 37 | ++--------------+-------------------+ | 
|  | 38 | +| SCL          | INA228 I2C SCL    | | 
|  | 39 | ++--------------+-------------------+ | 
|  | 40 | +| ALRT         | INA228 ALERT out  | | 
|  | 41 | ++--------------+-------------------+ | 
|  | 42 | +| VIN-         | Current sense neg | | 
|  | 43 | ++--------------+-------------------+ | 
|  | 44 | +| VIN+         | Current sense pos | | 
|  | 45 | ++--------------+-------------------+ | 
|  | 46 | +| VBUS         | Voltage sense     | | 
|  | 47 | ++--------------+-------------------+ | 
|  | 48 | + | 
|  | 49 | +See :dtcompatible:`ti,ina228` for documentation on how to adjust the | 
|  | 50 | +devicetree file, for example to adjust the sample averaging. | 
|  | 51 | + | 
|  | 52 | + | 
|  | 53 | +Programming | 
|  | 54 | +*********** | 
|  | 55 | + | 
|  | 56 | +Set ``--shield adafruit_ina228`` when you invoke ``west build``. For example | 
|  | 57 | +when running the :zephyr:code-sample:`sensor_shell` sample: | 
|  | 58 | + | 
|  | 59 | +.. zephyr-app-commands:: | 
|  | 60 | +   :zephyr-app: samples/sensor/sensor_shell | 
|  | 61 | +   :board: adafruit_qt_py_rp2040 | 
|  | 62 | +   :shield: adafruit_ina228 | 
|  | 63 | +   :goals: build | 
|  | 64 | + | 
|  | 65 | +.. _Adafruit INA228 High or Low Side Power Monitor: | 
|  | 66 | +   https://learn.adafruit.com/adafruit-ina228-i2c-power-monitor/ | 
|  | 67 | + | 
|  | 68 | +.. _TI INA228 Current sensor: | 
|  | 69 | +   https://www.ti.com/product/INA228 | 
0 commit comments