Example Program for EVAL-AD7606

Dependencies:   platform_drivers

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers main.c Source File

main.c

Go to the documentation of this file.
00001 /***************************************************************************//**
00002  *   @file    main.c
00003  *   @brief   Main module for AD7606 IIO application
00004  *   @details This module invokes the AD7606 IIO interfaces
00005  *            through forever loop.
00006 ********************************************************************************
00007  * Copyright (c) 2020 Analog Devices, Inc.
00008  *
00009  * All rights reserved.
00010  *
00011  * This software is proprietary to Analog Devices, Inc. and its licensors.
00012  * By using this software you agree to the terms of the associated
00013  * Analog Devices Software License Agreement.
00014 *******************************************************************************/
00015 
00016 /******************************************************************************/
00017 /***************************** Include Files **********************************/
00018 /******************************************************************************/
00019 #include <stdio.h>
00020 #include <stdint.h>
00021 #include <assert.h>
00022 
00023 #include "platform_support.h"
00024 #include "iio_ad7606.h"
00025 #include "error.h"
00026 
00027 /******************************************************************************/
00028 /********************** Macros and Constants Definitions **********************/
00029 /******************************************************************************/
00030 
00031 /******************************************************************************/
00032 /************************ Functions Definitions *******************************/
00033 /******************************************************************************/
00034 
00035 /**
00036  * @brief   Main entry point to application
00037  * @return  none
00038  */
00039 int main(void)
00040 {
00041     /* Initialize the AD7606 IIO interface */
00042     if (ad7606_iio_initialize() == FAILURE) {
00043         assert(false);
00044     }
00045 
00046     while (1) {
00047         /* Monitor the IIO client events */
00048         ad7606_iio_event_handler();
00049     }
00050 }