spectral 2.0.0.0
|
This file contains API for Spectral Click driver. More...
#include "drv_digital_out.h"
#include "drv_digital_in.h"
#include "drv_uart.h"
Go to the source code of this file.
Data Structures | |
struct | spectral_t |
Click ctx object definition. More... | |
struct | spectral_cfg_t |
Click configuration structure definition. More... | |
Macros | |
#define | SPECTRAL_MAP_MIKROBUS(cfg, mikrobus) |
#define | SPECTRAL_OK 0x00 |
#define | SPECTRAL_ERROR 0xFF |
#define | DRV_RX_BUFFER_SIZE 200 |
#define | DRV_TX_BUFFER_SIZE 100 |
Functions | |
void | spectral_cfg_setup (spectral_cfg_t *cfg) |
Config Object Initialization function. | |
err_t | spectral_init (spectral_t *ctx, spectral_cfg_t *cfg) |
Initialization function. | |
void | spectral_module_reset (spectral_t *ctx) |
Reset module. | |
void | spectral_uart_write (spectral_t *ctx, uint8_t *data_buf, uint16_t len) |
Generic write function. | |
int32_t | spectral_uart_read (spectral_t *ctx, uint8_t *data_buf, uint16_t max_len) |
Generic read function. | |
void | spectral_send_command (spectral_t *ctx, uint8_t *command) |
Send Command. | |
void | spectral_get_color_data (uint8_t *rsp, uint8_t *xyz_data) |
Read calibrated X, Y, and Z color data. | |
void | spectral_get_xyz_data (uint8_t *rsp, uint8_t *xyzr_data) |
Read raw X, Y, and Z data. | |
void | spectral_get_xy_small_data (uint8_t *rsp, uint8_t *xy_data) |
Read calibrated x and y for CIE 1931 color gamut. | |
uint8_t | spectral_get_lux_data (uint8_t *rsp) |
Read the calibrated LUX value from the sensor. | |
uint8_t | spectral_get_cct_data (uint8_t *rsp) |
Read the calibrated CCT value from the sensor. | |
void | spectral_get_uv_data (uint8_t *rsp, uint16_t *uv_data) |
Read calibrated u�, v� and u, v for CIE 1976 color gamut. | |
void | spectral_get_data (uint8_t *rsp, uint16_t *c_data) |
Read raw X, Y, Z and NIR data as well as two special internal registers D, & C. | |
uint8_t | spectral_get_duv_data (uint8_t *rsp) |
Read calibrated Duv for CIE 1976-color gamut. | |
This file contains API for Spectral Click driver.