Primary Git Repository for the Zephyr Project. Zephyr is a new generation, scalable, optimized, secure RTOS for multiple hardware architectures.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
Benjamin Cabé ee77704715 samples: sensor: use zephyr:code-sample directive 10 months ago
..
src
CMakeLists.txt
README.rst samples: sensor: use zephyr:code-sample directive 10 months ago
prj.conf
sample.yaml samples: sensor: hts221 no trigger on stm32u585 disco kit 2 years ago

README.rst

.. zephyr:code-sample:: hts221
:name: HTS221 Temperature and Humidity Monitor
:relevant-api: sensor_interface

Get temperature and humidity data from an HTS221 sensor (polling & trigger mode).

Overview
********
This sample periodically reads temperature and humidity from the HTS221
Temperature & Humidity Sensor and displays it on the console


Requirements
************

This sample uses the HTS221 sensor controlled using the I2C interface.

References
**********

- HTS211: https://www.st.com/en/mems-and-sensors/hts221.html

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

This project outputs sensor data to the console. It requires an HTS221
sensor, which is present on the disco_l475_iot1 board.

.. zephyr-app-commands::
:zephyr-app: samples/sensor/hts221
:board: disco_l475_iot1
:goals: build
:compact:

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

.. code-block:: console

Temperature:25.3 C
Relative Humidity:40%
Temperature:25.3 C
Relative Humidity:40%
Temperature:25.3 C
Relative Humidity:40%
Temperature:25.3 C
Relative Humidity:40%

<repeats endlessly every 2 seconds>