How does it work?
SHT Click is based on the SHT31-DIS, a humidity and temperature sensor from Sensirion. The SHT31-DIS is a robust and reliable sensor, and even when exposed to conditions outside its normal range, it can recalibrate itself once conditions stabilize. The sensor shows the best performance when operated within recommended normal temperature and humidity range of 5°C up to 60°C and 20%RH up to 80%RH, respectively. Long-term exposure to conditions outside the normal range, especially at high humidity, may temporarily offset the RH signal. After returning to the normal temperature and humidity range, the sensor will slowly return to a calibration state by itself. Also, note that prolonged exposure to extreme conditions may accelerate aging.
The SHT Click communicates with the host MCU using an I2C interface over the mikroBUS™ socket, with communication speeds of up to 1MHz. This Click board™ allows the selection of one of two available I2C addresses via the ADDR jumper, where I2C address 0 is selected by default. To reset the SHT31-DIS sensor, there is an RST pin with an active LOW state. The SHT31-DIS also features alert functions and can send interrupt signals over the INT pin of the mikroBUS™ socket. The output of this pin depends on the RH/T reading relative to programmable limits.
This Click board™ can operate with either 3.3V or 5V logic voltage levels selected via the PWR SEL jumper. This way, both 3.3V and 5V capable MCUs can use the communication lines properly. However, the Click board™ comes equipped with a library containing easy-to-use functions and an example code that can be used, as a reference, for further development.
Specifications
Type
Temperature & humidity
Applications
Can be used for the development of humidity and thermal management of portable electronics and industrial, consumer, and environmental applications
On-board modules
SHT31-DIS – humidity and temperature sensor from Sensirion
Key Features
Fully calibrated, linearized and temperature compensated digital output, high speed I2C interface, high performance, very fast Start-up and measurement time, high accuracy and reliability, and more
Interface
I2C
Feature
No ClickID
Compatibility
mikroBUS™
Click board size
S (28.6 x 25.4 mm)
Input Voltage
3.3V or 5V
Pinout diagram
This table shows how the pinout on SHT Click corresponds to the pinout on the mikroBUS™ socket (the latter shown in the two middle columns).
Onboard settings and indicators
Label | Name | Default | Description |
---|---|---|---|
– | PWR | – | Power LED Indicator |
– | PWR SEL | Left | Logic Level Voltage Selection 3V3/5V: Left position 3V3, Right position 5V |
– | ADDR | Left | I2C Address Selection 0/1: Left position 0, Right position 1 |
Software Support
We provide a library for the SHT Click as well as a demo application (example), developed using MIKROE compilers. The demo can run on all the main MIKROE development boards.
Package can be downloaded/installed directly from NECTO Studio Package Manager (recommended), downloaded from our LibStock™ or found on Mikroe github account.
Library Description
This library contains API for SHT Click driver.
Key functions
-
Returns temperature measurement in single shot mode.
-
Returns humidity measurement in single shot mode.
-
Sets the heater state.
Example Description
This application enables usage of the temperature and humidity sensor.
void application_task ( void )
{
// Task implementation.
float temperature;
float humidity;
Delay_ms( 1500 );
temperature = sht_temp_ss( &sht );
log_printf( &logger, "Temperature: %.2f C rn", temperature );
Delay_ms( 200 );
humidity = sht_hum_ss( &sht );
log_printf( &logger, "Humidity: %.2f %% rn", humidity );
Delay_ms( 200 );
}
The full application code, and ready to use projects can be installed directly from NECTO Studio Package Manager (recommended), downloaded from our LibStock™ or found on Mikroe github account.
Other Mikroe Libraries used in the example:
- MikroSDK.Board
- MikroSDK.Log
- Click.Sht
Additional notes and informations
Depending on the development board you are using, you may need USB UART click, USB UART 2 Click or RS232 Click to connect to your PC, for development systems with no UART to USB interface available on the board. UART terminal is available in all MIKROE compilers.
mikroSDK
This Click board™ is supported with mikroSDK – MIKROE Software Development Kit. To ensure proper operation of mikroSDK compliant Click board™ demo applications, mikroSDK should be downloaded from the LibStock and installed for the compiler you are using.
For more information about mikroSDK, visit the official page.