19 #define UV_TASKLIST 0x80
20 #define UV_IRQ_EN IE_ALS_EVRYSAMPLE
21 #define SI1146_DEVICE_ID 0x46
29 static void * si114x_handle;
57 while((regval & 0x80) != 0)
90 if( vis_range_bit == 1 )
SI114X_CAL_S Data Structure.
Si114x function prototypes, structure and bit definitions.
int16_t Si114xParamSet(HANDLE si114x_handle, uint8_t address, uint8_t value)
Writes a byte to an Si113x/4x Parameter.
int16_t Si114xWriteToRegister(HANDLE si114x_handle, uint8_t address, uint8_t data)
Writes to Si114x Register.
int16_t si114x_set_ucoef(HANDLE si114x_handle, uint8_t *input_ucoef, SI114X_CAL_S *si114x_cal)
Initializes the Si113x/46/47/48 UCOEF Registers.
int Si114x_ConfigureUV(int fullInit, HANDLE *handle)
Initializes and configures the Si1146 sensor for UV index measurements.
int16_t Si114xPsAlsForce(HANDLE si114x_handle)
Sends a PSALSFORCE command to the Si113x/4x.
int Si114x_EnableVisRange(int vis_range_bit)
Set the VIS_RANGE bit of the optical sensor Si114x.
int16_t Si114xReadFromRegister(HANDLE si114x_handle, uint8_t address)
Reads from Si114x register.
int16_t si114x_get_calibration(HANDLE si114x_handle, SI114X_CAL_S *si114x_cal, uint8_t security)
Populates the SI114X_CAL_S structure.
static void * si114x_handle
Si114x PGM toolkit functions uses a void* to pass hardware parameters through to the lower level i2c ...
int Si114x_MeasureUVIndex(u16 *uvIndex)
Reads the UV index measurement data from the Si114x.
int16_t Si114xReset(HANDLE si114x_handle)
Resets the Si113x/4x, clears any interrupts and initializes the HW_KEY register.