https://github.com/stm32duino/sht40-ad1b
Arduino library to support the SHT40-AD1B digital humidity and temperature sensor
https://github.com/stm32duino/sht40-ad1b
Last synced: 10 days ago
JSON representation
Arduino library to support the SHT40-AD1B digital humidity and temperature sensor
- Host: GitHub
- URL: https://github.com/stm32duino/sht40-ad1b
- Owner: stm32duino
- License: bsd-3-clause
- Created: 2023-07-28T12:46:10.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-09-11T08:06:22.000Z (over 1 year ago)
- Last Synced: 2024-12-31T12:50:23.638Z (4 months ago)
- Language: C++
- Size: 6.84 KB
- Stars: 2
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# SHT40-AD1B
Arduino library to support the SHT40-AD1B digital humidity and temperature sensor## API
This sensor uses I2C to communicate.
For I2C it is then required to create a TwoWire interface before accessing to the sensors:TwoWire dev_i2c(I2C_SDA, I2C_SCL);
dev_i2c.begin();An instance can be created and enabled when the I2C bus is used following the procedure below:
SHT40AD1BSensor sensor(&Wire);
The access to the sensor values is done as explained below:
Read temperature and humidity.
float tmp,hum;
sensor.GetTemperature(&tmp);
sensor.GetHumidity(&hum);## Examples
* SHT40AD1B_DataLog_Terminal: This application shows how to get data from SHT40-AD1B humidity and temperature and print them on terminal.
## Documentation
You can find the source files at
https://github.com/stm32duino/SHT40-AD1B