adc11 2.0.0.0
main.c File Reference

Adc11 Click example. More...

#include "board.h"
#include "log.h"
#include "adc11.h"

Functions

void application_init (void)
 
void application_task (void)
 
int main (void)
 

Variables

adc11_calibration_data_t avg_adc_data
 
float voltage
 
uint16_t adc_data
 

Detailed Description

Adc11 Click example.

Description

This library contains API for ADC 11 Click driver. The library contains drivers for measuring ADC values
and for calculation voltage.

The demo application is composed of two sections :

Application Init

Initializes SPI driver and triggers the built-in calibration.

Application Task

This is an example that demonstrates the use of the ADC 11 Click board. In this example, we monitor and display voltage [ V ]. Results are being sent to the Usart Terminal, where you can track their changes. All data logs write on USB UART changes every 2 sec.

Author
Nenad Filipovic

Function Documentation

◆ application_init()

void application_init ( void )

< Logger config object.

< Click config object.

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 )

◆ main()

int main ( void )

Variable Documentation

◆ adc_data

uint16_t adc_data

◆ avg_adc_data

◆ voltage

float voltage