irsense 2.0.0.0
|
This file contains API for IR SENSE Click driver. More...
#include "drv_digital_out.h"
#include "drv_digital_in.h"
#include "drv_i2c_master.h"
Go to the source code of this file.
Data Structures | |
struct | irsense_t |
Click ctx object definition. More... | |
struct | irsense_ir_data_t |
IR data structure definition. More... | |
struct | irsense_eint_t |
Enable interrupt structure definition. More... | |
struct | irsense_reg_t |
Register address structure definition. More... | |
struct | irsense_eeprom_t |
EEPROM map structure definition. More... | |
struct | irsense_cfg_t |
Click configuration structure definition. More... | |
Functions | |
void | irsense_cfg_setup (irsense_cfg_t *cfg) |
Config Object Initialization function. | |
IRSENSE_RETVAL | irsense_init (irsense_t *ctx, irsense_cfg_t *cfg) |
Initialization function. | |
void | irsense_generic_write (irsense_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len) |
Generic write function. | |
void | irsense_generic_read (irsense_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len) |
Generic read function. | |
void | irsense_write_byte (irsense_t *ctx, uint8_t reg_address, uint8_t write_data) |
Generic write the byte of data function. | |
uint8_t | irsense_read_byte (irsense_t *ctx, uint8_t reg_address) |
Generic read the byte of data function. | |
uint16_t | irsense_read_data (irsense_t *ctx, uint8_t reg_address_low) |
Generic read 16-bit of data function. | |
void | irsense_power_on (irsense_t *ctx) |
Enable the sensor function. | |
void | irsense_power_off (irsense_t *ctx) |
Disable the sensor function. | |
uint8_t | irsense_get_company_code (irsense_t *ctx) |
Get company code function. | |
uint8_t | irsense_get_device_id (irsense_t *ctx) |
Get device ID function. | |
uint8_t | irsense_read_interrupt_status (irsense_t *ctx) |
Get interrupts activate or inactivate corresponding status value function. | |
uint8_t | irsense_get_status (irsense_t *ctx) |
Get status value function. | |
void | irsense_set_configuration (irsense_t *ctx, uint8_t register_value) |
Set configuration function. | |
void | irsense_set_mode (irsense_t *ctx, uint8_t mode) |
Set the mode function. | |
void | irsense_set_cutoff_frequency (irsense_t *ctx, uint8_t frequency) |
Set the cutoff frequency function. | |
uint8_t | irsense_check_available (irsense_t *ctx) |
Checks to see if DRDY flag is set in the status register function. | |
uint8_t | irsense_check_overrun (irsense_t *ctx) |
Checks to see if data overrun flag is set in the status register function. | |
void | irsense_soft_reset (irsense_t *ctx) |
Soft reset function. | |
void | irsense_refresh (irsense_t *ctx) |
Refresh by read dummy data function. | |
int16_t | irsense_get_ir1 (irsense_t *ctx) |
Get value of sensor channel 1 function. | |
int16_t | irsense_get_ir2 (irsense_t *ctx) |
Get value of sensor channel 2 function. | |
int16_t | irsense_get_ir3 (irsense_t *ctx) |
Get value of sensor channel 3 function. | |
int16_t | irsense_get_ir4 (irsense_t *ctx) |
Get value of sensor channel 4 function. | |
void | irsense_get_ir_sense (irsense_t *ctx, irsense_ir_data_t *ir_data) |
Get value of sensor all channels function. | |
float | irsense_get_temperature (irsense_t *ctx) |
Get the temperature in degrees Celsius function. | |
float | irsense_get_temperature_f (irsense_t *ctx) |
Get the temperature in Fahrenheit degrees function. | |
void | irsense_set_threshold_ir2_ir4 (irsense_t *ctx, uint8_t value) |
Set high or low threshold for channel 2 and channel 4 ( Ir2-Ir4 ) function. | |
uint16_t | irsense_get_threshold_ir2_ir4 (irsense_t *ctx) |
Get threshold value for channel 2 and channel 4 ( Ir2-Ir4 ) function. | |
void | irsense_set_threshold_eeprom_ir2_ir4 (irsense_t *ctx, uint8_t value) |
Set high or low EEPROM threshold for channel 2 and channel 4 ( Ir2-Ir4 ) function. | |
void | irsense_set_threshold_ir1_ir3 (irsense_t *ctx, uint8_t value) |
Set high or low threshold for channel 1 and channel 3 ( Ir1-Ir3 ) function. | |
uint16_t | irsense_get_threshold_ir1_ir3 (irsense_t *ctx) |
Get threshold value for channel 1 and channel 3 ( Ir1-Ir3 ) function. | |
void | irsense_set_threshold_eeprom_ir1_ir3 (irsense_t *ctx, uint8_t value) |
Set high or low EEPROM threshold for channel 1 and channel 3 ( Ir1-Ir3 ) function. | |
void | irsense_read_threshold (irsense_t *ctx, irsense_reg_t *reg) |
Get threshold value for all channels function. | |
void | irsense_read_threshold_eeprom (irsense_t *ctx, irsense_eeprom_t *eeprom) |
Get threshold EEPROM value for all channels function. | |
void | irsense_set_hysteresis_ir2_ir4 (irsense_t *ctx, uint8_t value) |
Set hysteresis setting of threshold level for channel 2 and channel 4 ( Ir2-Ir4 ) function. | |
void | irsense_set_hysteresis_eeprom_ir2_ir4 (irsense_t *ctx, uint8_t value) |
Set hysteresis EEPROM setting of threshold level for channel 2 and channel 4 ( Ir2-Ir4 ) function. | |
void | irsense_set_hysteresis_ir1_ir3 (irsense_t *ctx, uint8_t value) |
Set hysteresis setting of threshold level for channel 1 and channel 3 ( Ir1-Ir3 ) function. | |
void | irsense_set_hysteresis_eeprom_ir1_ir3 (irsense_t *ctx, uint8_t value) |
Set hysteresis EEPROM setting of threshold level for channel 1 and channel 3 ( Ir1-Ir3 ) function. | |
void | irsense_read_hysteresis (irsense_t *ctx, uint8_t *ehys24, uint8_t *ehys13) |
Get Hysteresis value for all channes function. | |
void | irsense_read_hysteresis_eeprom (irsense_t *ctx, uint8_t *eehys24, uint8_t *eehys13) |
Get Hysteresis EEPROM value for all channes function. | |
void | irsense_set_interrupts_reg (irsense_t *ctx, irsense_eint_t *eint) |
Sets interrupts activate or inactivate corresponding function. | |
void | irsense_enable_data_ready_interrupt (irsense_t *ctx) |
Sets interrupts source settings function. | |
uint8_t | irsense_check_int_states (irsense_t *ctx) |
Check state of INT pin function. | |
This file contains API for IR SENSE Click driver.