color3
2.0.0.0
|
This file contains API for Color 3 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 | color3_t |
Click ctx object definition. More... | |
struct | color3_const_t |
struct | color3_cfg_t |
Click configuration structure definition. More... | |
Functions | |
void | color3_cfg_setup (color3_cfg_t *cfg) |
Config Object Initialization function. More... | |
COLOR3_RETVAL | color3_init (color3_t *ctx, color3_cfg_t *cfg) |
Initialization function. More... | |
void | color3_generic_write (color3_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len) |
Generic write function. More... | |
void | color3_generic_read (color3_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len) |
Generic read function. More... | |
void | color3_normal_wr_byte (color3_t *ctx, uint8_t wr_addr, uint8_t wr_data) |
Generic read function. More... | |
void | color3_special_wr_byte (color3_t *ctx, uint8_t wr_addr, uint8_t wr_data) |
Special write byte function. More... | |
uint8_t | color3_read_byte (color3_t *ctx, uint8_t rd_addr) |
Read byte function. More... | |
void | color3_normal_wr_data (color3_t *ctx, uint8_t wr_addr, uint16_t wr_data) |
Normal write data function. More... | |
void | color3_special_wr_data (color3_t *ctx, uint8_t wr_addr, uint16_t wr_data) |
Special write function. More... | |
uint16_t | color3_read_data (color3_t *ctx, uint8_t rd_addr) |
Read data function. More... | |
void | color3_write_enable_register (color3_t *ctx, uint8_t wr_data) |
Write Enable Register function. More... | |
uint8_t | color3_read_enable_register (color3_t *ctx) |
Read Enable Register function. More... | |
void | color3_write_rgbc_timing_register (color3_t *ctx, uint8_t wr_data) |
Write RGBC Timing Register function. More... | |
uint8_t | color3_read_rgbc_timing_register (color3_t *ctx) |
Read RGBC Timing Register function. More... | |
void | color3_write_proxy_timing_register (color3_t *ctx) |
Write Proximity Timing Register function. More... | |
uint8_t | color3_read_proxy_timing_register (color3_t *ctx) |
Read Proximity Timing Register function. More... | |
void | color3_write_wait_time_register (color3_t *ctx, uint8_t wr_data) |
Write Wait Time Register function. More... | |
uint8_t | color3_read_wait_time_register (color3_t *ctx) |
Read Wait Time Register function. More... | |
void | color3_set_inter_trsh_lo_val (color3_t *ctx, uint16_t wr_data) |
RGBC interrupt threshold low value function. More... | |
void | color3_set_inter_trsh_hi_val (color3_t *ctx, uint16_t wr_data) |
RGBC interrupt threshold high value function. More... | |
void | color3_set_proxy_inter_trsh_lo_val (color3_t *ctx, uint16_t wr_data) |
Proximity interrupt threshold low value function. More... | |
void | color3_set_proxy_inter_trsh_hi_val (color3_t *ctx, uint16_t wr_data) |
Proximity interrupt threshold high value function. More... | |
void | color3_set_interrupt_persistence (color3_t *ctx, uint8_t int_pers) |
Set Interrupt persistence persistence function. More... | |
uint8_t | color3_read_interrupt_persistence (color3_t *ctx) |
Read Interrupt persistence function. More... | |
void | color3_setproxy_interrupt_persistence (color3_t *ctx, uint8_t int_pers) |
Set Proximity interrupt persistence function. More... | |
uint8_t | color3_read_proxy_interrupt_persistence (color3_t *ctx) |
Read Proximity interrupt persistence function. More... | |
void | color3_setLongWait (color3_t *ctx, uint8_t lon_wait) |
Set long wait function. More... | |
uint8_t | color3_read_long_wait (color3_t *ctx) |
Read long wait function. More... | |
void | color3_write_pulse_cnt (color3_t *ctx, uint8_t pulse_cnt) |
Write Proximity Pulse Count function. More... | |
uint8_t | color3_read_pulse_cnt (color3_t *ctx) |
Read Proximity Pulse Count function. More... | |
void | color3_write_rgbc_gain (color3_t *ctx, uint8_t gain_val) |
Write RGBC Gain Value function. More... | |
uint8_t | color3_read_rgbc_gain (color3_t *ctx) |
Read RGBC Gain Value function. More... | |
void | color3_set_diode_select (color3_t *ctx, uint8_t dio_sel) |
Set Diode Selection function. More... | |
uint8_t | color3_get_diode_select (color3_t *ctx) |
Get Diode Selection function. More... | |
void | color3_set_led_str (color3_t *ctx, uint8_t led_str) |
Set LED Strength function. More... | |
uint8_t | color3_read_led_str (color3_t *ctx) |
Read LED Strength function. More... | |
uint8_t | color3_read_dev_id (color3_t *ctx) |
Read device ID function. More... | |
uint8_t | color3_read_dev_stat (color3_t *ctx) |
Read device status function. More... | |
uint16_t | color3_read_clear_data (color3_t *ctx) |
Read clear data function. More... | |
uint16_t | color3_read_red_data (color3_t *ctx) |
Read red data function. More... | |
uint16_t | color3_read_green_data (color3_t *ctx) |
Read green data function. More... | |
uint16_t | color3_read_blue_data (color3_t *ctx) |
Read blue data function. More... | |
uint16_t | color3_read_proxy_data (color3_t *ctx) |
ead proximity data function. More... | |
uint8_t | color3_get_inter_state (color3_t *ctx) |
Get Interrupt state function. More... | |
void | color3_set_default_settings (color3_t *ctx) |
Default settings function. More... | |
void | color3_get_rgb_data (color3_t *ctx, uint16_t *red_data, uint16_t *green_data, uint16_t *blue_data) |
Get color data function. More... | |
float | color3_get_color_ratio (color3_t *ctx, uint16_t color_data) |
Get color ratio function. More... | |
float | color3_get_color_value (color3_t *ctx) |
Get color value function. More... | |
void | color3_get_crgb_data (color3_t *ctx, color3_const_t *data_const) |
Get CRBG data function. More... | |
uint8_t | color3_get_color (float color_value) |
Detect color. More... | |
This file contains API for Color 3 Click driver.