zephyr/samples/drivers/current_sensing
Gerson Fernando Budke 62ba4723d4 drivers: serial: uart_sam0: Add pinctrl support
Add Atmel sam0 sercom[uart] pinctrl bindings and implements pinctrl at
driver level.  It changes all sam0 boards to use new feature and remove
pinmux driver dependency for sercom[uart].  The samples that require a
binding were update to keep consistency and avoid errors.

Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
2021-07-30 14:37:20 -05:00
..
boards drivers: serial: uart_sam0: Add pinctrl support 2021-07-30 14:37:20 -05:00
src
CMakeLists.txt
prj.conf
README.rst
sample.yaml

.. _current_sensing:

Current Sensing
###############

Overview
********
This is a sample app to interface with TI INA219 power monitor.
The values used in the app are for use on Adafruit's breakout board
(https://www.adafruit.com/products/904).

This assumes the slave address is 0x40, where A0 and A1 are all tied to ground.

Building and Running
********************

This project outputs measured values to the console. It can be built and
executed as follows:

.. zephyr-app-commands::
   :zephyr-app: samples/drivers/current_sensing
   :host-os: unix
   :goals: build flash
   :compact:

Sample Output
=============

.. code-block:: console

	Bus Voltage: 3300 mV
	Shunt Voltage: 100 uV
	Current: 5000 uA
	Power: 16500 uW