Playing With Fusion SHT3X Arduino Library
Loading...
Searching...
No Matches
PWFusion_SHT3X Class Reference

SHT3X device driver for Arduino. More...

#include <PWFusion_SHT3X.h>

Public Member Functions

 PWFusion_SHT3X (TwoWire *pWire=&Wire)
 Construct a new pwfusion sht3x object.
 
bool begin (uint8_t address)
 Initialize device driver.
 
void reset (void)
 Soft reset the SHT3X device.
 
void enableHeater ()
 Enable internal heater. See datasheet for more information.
 
void disableHeater ()
 Disable internal heater. See datasheet for more information.
 
PWFusion_SHT3X_Data measure ()
 Perform a one-shot measurement on the device and return the results.
 
void writeCmd (uint16_t cmd)
 Write an I2C command to the device. See datasheet for more information.
 

Detailed Description

SHT3X device driver for Arduino.

Constructor & Destructor Documentation

◆ PWFusion_SHT3X()

PWFusion_SHT3X::PWFusion_SHT3X ( TwoWire *  pWire = &Wire)

Construct a new pwfusion sht3x object.

Parameters
pWireDesired Wire interface. Typically left to default (&Wire) in order to use hardware I2C

Member Function Documentation

◆ begin()

bool PWFusion_SHT3X::begin ( uint8_t  address)

Initialize device driver.

Parameters
addressAddress device is at. Either SHT3X_ADDR_PRIMARY or SHT3X_ADDR_SECONDARY depending on connection of the ADDR pin, and status of solder jumper. See macros for more info
Returns
true Device started up OK
false Error trying to initialize device. Check wiring

◆ disableHeater()

void PWFusion_SHT3X::disableHeater ( )

Disable internal heater. See datasheet for more information.

◆ enableHeater()

void PWFusion_SHT3X::enableHeater ( )

Enable internal heater. See datasheet for more information.

◆ measure()

PWFusion_SHT3X_Data PWFusion_SHT3X::measure ( )

Perform a one-shot measurement on the device and return the results.

Returns
PWFusion_SHT3X_Data Measurement data. Ensure to check "error" member in case there was an error trying to get data.

◆ reset()

void PWFusion_SHT3X::reset ( void  )

Soft reset the SHT3X device.

◆ writeCmd()

void PWFusion_SHT3X::writeCmd ( uint16_t  cmd)

Write an I2C command to the device. See datasheet for more information.

Parameters
cmd16-bit command to send.

The documentation for this class was generated from the following files: