proximity10 2.0.0.0
|
Proximity10 Click example. More...
Functions | |
void | check_response (uint8_t cmd_resp) |
void | application_init (void) |
void | application_task (void) |
int | main (void) |
Proximity10 Click example.
This application enables proximity sensor to detect objects from distance up to 20cm.
The demo application is composed of two sections :
Initializes I2C serial interface and performs a device wake up, reset and all necessary configurations. The device will wake up and performs measurements every 10 milliseconds.
Reads the proximity PS1 data value and sends result to the uart terminal. If measured proximity value is greater than selected proximity threshold value, the interrupt will be generated and the message will be showed on the uart terminal. When interrupt is generated the Sound function will make an alarm sound with determined duration depending on the detected proximity value, how much is object away or close from the sensor.
note: Additional Functions :
void application_init | ( | void | ) |
Logger initialization. Default baud rate: 115200 Default log level: LOG_LEVEL_DEBUG
void application_task | ( | void | ) |
void check_response | ( | uint8_t | cmd_resp | ) |
int main | ( | void | ) |