heartrate8 2.0.0.0
main.c File Reference

HeartRate8 Click example. More...

#include "board.h"
#include "log.h"
#include "heartrate8.h"

Functions

void plot_res (uint16_t plot_data)
 
void log_res ()
 
void application_init (void)
 
void application_task (void)
 
int main (void)
 

Detailed Description

HeartRate8 Click example.

Description

This example demonstrates the use of Hearth rate 8 Click board.

The demo application is composed of two sections :

Application Init

Performs the device reset, after which the device configuration can be performed. The device is configured to work in Single Measurement Mode with LED pulsing. The driver which is selected is driver for the GREEN LED Data.

Application Task

Sends command to start measurement cycle, then waits until measurement cycle is finished. When measurement cycle is done, gets LED ON and LED OFF Data for the selected LED driver (GREEN or IR LED) and performs data plotting on serial plotter every 35ms.

Author
MikroE Team

Function Documentation

◆ application_init()

void application_init ( void )

Logger initialization. Default baud rate: 115200 Default log level: LOG_LEVEL_DEBUG

Note
If USB_UART_RX and USB_UART_TX are defined as HAL_PIN_NC, you will need to define them manually for log to work. See LOG_MAP_USB_UART macro definition for detailed explanation.

◆ application_task()

void application_task ( void )

◆ log_res()

void log_res ( )

◆ main()

int main ( void )

◆ plot_res()

void plot_res ( uint16_t plot_data)