![]() |
LibDriver VEML7700
|
veml7700 basic driver modules More...
Data Structures | |
| struct | veml7700_handle_s |
| veml7700 handle structure definition More... | |
| struct | veml7700_info_s |
| veml7700 information structure definition More... | |
Macros | |
| #define | VEML7700_AUTO_RANGE_HIGH_THRESHOLD 0xFF00U |
| veml7700 auto range high threshold definition | |
| #define | VEML7700_AUTO_RANGE_LOW_THRESHOLD 0x00FFU |
| veml7700 auto range low threshold definition | |
Typedefs | |
| typedef struct veml7700_handle_s | veml7700_handle_t |
| veml7700 handle structure definition | |
| typedef struct veml7700_info_s | veml7700_info_t |
| veml7700 information structure definition | |
veml7700 basic driver modules
| #define VEML7700_AUTO_RANGE_HIGH_THRESHOLD 0xFF00U |
veml7700 auto range high threshold definition
0xFF00
Definition at line 63 of file driver_veml7700.h.
| #define VEML7700_AUTO_RANGE_LOW_THRESHOLD 0x00FFU |
veml7700 auto range low threshold definition
0x00FF
Definition at line 70 of file driver_veml7700.h.
| typedef struct veml7700_handle_s veml7700_handle_t |
veml7700 handle structure definition
| typedef struct veml7700_info_s veml7700_info_t |
veml7700 information structure definition
| enum veml7700_als_gain_t |
veml7700 als gain enumeration definition
| Enumerator | |
|---|---|
| VEML7700_ALS_GAIN_1 | gain 1 |
| VEML7700_ALS_GAIN_2 | gain 2 |
| VEML7700_ALS_GAIN_1_DIV_8 | gain 1/8 |
| VEML7700_ALS_GAIN_1_DIV_4 | gain 1/4 |
Definition at line 85 of file driver_veml7700.h.
veml7700 als integration time enumeration definition
Definition at line 96 of file driver_veml7700.h.
| enum veml7700_als_mode_t |
veml7700 als mode enumeration definition
| Enumerator | |
|---|---|
| VEML7700_ALS_MODE_POWER_ON | als power on |
| VEML7700_ALS_MODE_SHUT_DOWN | als shut down |
Definition at line 120 of file driver_veml7700.h.
veml7700 als persistence enumeration definition
Definition at line 109 of file driver_veml7700.h.
| enum veml7700_bool_t |
veml7700 bool enumeration definition
| Enumerator | |
|---|---|
| VEML7700_BOOL_DISABLE | disable |
| VEML7700_BOOL_ENABLE | enable |
Definition at line 76 of file driver_veml7700.h.
veml7700 power saving mode enumeration definition
als_integration_time refresh time
mode1 mode2 mode3 mode4 100ms 600ms 1100ms 2100ms 4100ms 200ms 700ms 1200ms 2200ms 4200ms 400ms 900ms 1400ms 2400ms 4400ms 800ms 1300ms 1800ms 2800ms 4800ms
| Enumerator | |
|---|---|
| VEML7700_POWER_SAVING_MODE1 | mode 1 |
| VEML7700_POWER_SAVING_MODE2 | mode 2 |
| VEML7700_POWER_SAVING_MODE3 | mode 3 |
| VEML7700_POWER_SAVING_MODE4 | mode 4 |
Definition at line 136 of file driver_veml7700.h.
| uint8_t veml7700_deinit | ( | veml7700_handle_t * | handle | ) |
close the chip
| [in] | *handle | pointer to a veml7700 handle structure |
Definition at line 1234 of file driver_veml7700.c.
| uint8_t veml7700_get_als_gain | ( | veml7700_handle_t * | handle, |
| veml7700_als_gain_t * | gain ) |
get als gain
| [in] | *handle | pointer to a veml7700 handle structure |
| [out] | *gain | pointer to an als gain buffer |
Definition at line 442 of file driver_veml7700.c.
| uint8_t veml7700_get_als_high_threshold | ( | veml7700_handle_t * | handle, |
| uint16_t * | threshold ) |
get als high threshold
| [in] | *handle | pointer to a veml7700 handle structure |
| [out] | *threshold | pointer to a high threshold buffer |
Definition at line 842 of file driver_veml7700.c.
| uint8_t veml7700_get_als_integration_time | ( | veml7700_handle_t * | handle, |
| veml7700_als_integration_time_t * | t ) |
get als integration time
| [in] | *handle | pointer to a veml7700 handle structure |
| [out] | *t | pointer to an als integration time buffer |
Definition at line 524 of file driver_veml7700.c.
| uint8_t veml7700_get_als_interrupt | ( | veml7700_handle_t * | handle, |
| veml7700_bool_t * | enable ) |
get als interrupt status
| [in] | *handle | pointer to a veml7700 handle structure |
| [out] | *enable | pointer to a bool value buffer |
Definition at line 688 of file driver_veml7700.c.
| uint8_t veml7700_get_als_low_threshold | ( | veml7700_handle_t * | handle, |
| uint16_t * | threshold ) |
get als low threshold
| [in] | *handle | pointer to a veml7700 handle structure |
| [out] | *threshold | pointer to a low threshold buffer |
Definition at line 912 of file driver_veml7700.c.
| uint8_t veml7700_get_als_mode | ( | veml7700_handle_t * | handle, |
| veml7700_als_mode_t * | mode ) |
get als mode
| [in] | *handle | pointer to a veml7700 handle structure |
| [out] | *mode | pointer to an als mode buffer |
Definition at line 770 of file driver_veml7700.c.
| uint8_t veml7700_get_als_persistence | ( | veml7700_handle_t * | handle, |
| veml7700_als_persistence_t * | persistence ) |
get als persistence
| [in] | *handle | pointer to a veml7700 handle structure |
| [out] | *persistence | pointer to an als persistence buffer |
Definition at line 606 of file driver_veml7700.c.
| uint8_t veml7700_get_auto_range | ( | veml7700_handle_t * | handle, |
| veml7700_bool_t * | enable ) |
get auto range
| [in] | *handle | pointer to a veml7700 handle structure |
| [out] | *enable | pointer to a bool value buffer |
Definition at line 1310 of file driver_veml7700.c.
| uint8_t veml7700_get_interrupt_status | ( | veml7700_handle_t * | handle, |
| veml7700_bool_t * | low_threshold, | ||
| veml7700_bool_t * | high_threshold ) |
get interrupt status
| [in] | *handle | pointer to a veml7700 handle structure |
| [out] | *low_threshold | pointer to a low threshold buffer |
| [out] | *high_threshold | pointer to a high threshold buffer |
Definition at line 1112 of file driver_veml7700.c.
| uint8_t veml7700_get_power_saving | ( | veml7700_handle_t * | handle, |
| veml7700_bool_t * | enable ) |
get power saving status
| [in] | *handle | pointer to a veml7700 handle structure |
| [out] | *enable | pointer to a bool value buffer |
Definition at line 1074 of file driver_veml7700.c.
| uint8_t veml7700_get_power_saving_mode | ( | veml7700_handle_t * | handle, |
| veml7700_power_saving_mode_t * | mode ) |
get power saving mode
| [in] | *handle | pointer to a veml7700 handle structure |
| [out] | *mode | pointer to a power saving mode buffer |
Definition at line 992 of file driver_veml7700.c.
| uint8_t veml7700_info | ( | veml7700_info_t * | info | ) |
get chip's information
| [out] | *info | pointer to a veml7700 info structure |
Definition at line 1475 of file driver_veml7700.c.
| uint8_t veml7700_init | ( | veml7700_handle_t * | handle | ) |
initialize the chip
| [in] | *handle | pointer to a veml7700 handle structure |
Definition at line 1150 of file driver_veml7700.c.
| uint8_t veml7700_read_als | ( | veml7700_handle_t * | handle, |
| uint16_t * | raw, | ||
| double * | lux ) |
read als channel
| [in] | *handle | pointer to a veml7700 handle structure |
| [out] | *raw | pointer to a raw lux buffer |
| [out] | *lux | pointer to a converted lux buffer |
Definition at line 1374 of file driver_veml7700.c.
| uint8_t veml7700_read_white | ( | veml7700_handle_t * | handle, |
| uint16_t * | raw ) |
read white channel
| [in] | *handle | pointer to a veml7700 handle structure |
| [out] | *raw | pointer to a raw lux buffer |
Definition at line 1336 of file driver_veml7700.c.
| uint8_t veml7700_set_als_gain | ( | veml7700_handle_t * | handle, |
| veml7700_als_gain_t | gain ) |
set als gain
| [in] | *handle | pointer to a veml7700 handle structure |
| [in] | gain | als gain |
Definition at line 397 of file driver_veml7700.c.
| uint8_t veml7700_set_als_high_threshold | ( | veml7700_handle_t * | handle, |
| uint16_t | threshold ) |
set als high threshold
| [in] | *handle | pointer to a veml7700 handle structure |
| [in] | threshold | high threshold |
Definition at line 807 of file driver_veml7700.c.
| uint8_t veml7700_set_als_integration_time | ( | veml7700_handle_t * | handle, |
| veml7700_als_integration_time_t | t ) |
set als integration time
| [in] | *handle | pointer to a veml7700 handle structure |
| [in] | t | als integration time |
Definition at line 479 of file driver_veml7700.c.
| uint8_t veml7700_set_als_interrupt | ( | veml7700_handle_t * | handle, |
| veml7700_bool_t | enable ) |
enable or disable als interrupt
| [in] | *handle | pointer to a veml7700 handle structure |
| [in] | enable | bool value |
Definition at line 643 of file driver_veml7700.c.
| uint8_t veml7700_set_als_low_threshold | ( | veml7700_handle_t * | handle, |
| uint16_t | threshold ) |
set als low threshold
| [in] | *handle | pointer to a veml7700 handle structure |
| [in] | threshold | low threshold |
Definition at line 877 of file driver_veml7700.c.
| uint8_t veml7700_set_als_mode | ( | veml7700_handle_t * | handle, |
| veml7700_als_mode_t | mode ) |
set als mode
| [in] | *handle | pointer to a veml7700 handle structure |
| [in] | mode | als mode |
Definition at line 725 of file driver_veml7700.c.
| uint8_t veml7700_set_als_persistence | ( | veml7700_handle_t * | handle, |
| veml7700_als_persistence_t | persistence ) |
set als persistence
| [in] | *handle | pointer to a veml7700 handle structure |
| [in] | persistence | als persistence |
Definition at line 561 of file driver_veml7700.c.
| uint8_t veml7700_set_auto_range | ( | veml7700_handle_t * | handle, |
| veml7700_bool_t | enable ) |
set auto range
| [in] | *handle | pointer to a veml7700 handle structure |
| [in] | enable | bool value |
Definition at line 1285 of file driver_veml7700.c.
| uint8_t veml7700_set_power_saving | ( | veml7700_handle_t * | handle, |
| veml7700_bool_t | enable ) |
enable or disable power saving
| [in] | *handle | pointer to a veml7700 handle structure |
| [in] | enable | bool value |
Definition at line 1029 of file driver_veml7700.c.
| uint8_t veml7700_set_power_saving_mode | ( | veml7700_handle_t * | handle, |
| veml7700_power_saving_mode_t | mode ) |
set power saving mode
| [in] | *handle | pointer to a veml7700 handle structure |
| [in] | mode | power saving mode |
Definition at line 947 of file driver_veml7700.c.