Mahesh Phalke / Mbed OS EVAL-AD7689

Dependencies:   sdp_k1_sdram

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers ad7689_user_config.c Source File

ad7689_user_config.c

Go to the documentation of this file.
00001 /***************************************************************************//**
00002  * @file    ad7689_user_config.c
00003  * @brief   User configurations for AD7689 No-OS driver
00004 ********************************************************************************
00005 * Copyright (c) 2021-22 Analog Devices, Inc.
00006 * All rights reserved.
00007 *
00008 * This software is proprietary to Analog Devices, Inc. and its licensors.
00009 * By using this software you agree to the terms of the associated
00010 * Analog Devices Software License Agreement.
00011 *******************************************************************************/
00012 
00013 /******************************************************************************/
00014 /***************************** Include Files **********************************/
00015 /******************************************************************************/
00016 
00017 #include "ad7689_user_config.h"
00018 #include "app_config.h"
00019 
00020 /******************************************************************************/
00021 /********************* Macros and Constants Definition ************************/
00022 /******************************************************************************/
00023 
00024 /******************************************************************************/
00025 /******************** Variables and User Defined Data Types *******************/
00026 /******************************************************************************/
00027 
00028 /* AD7689 No-OS driver init parameters */
00029 struct ad7689_init_param ad7689_init_params = {
00030     .id = ACTIVE_DEVICE,
00031 
00032     .config = {
00033         .incc = ADC_INPUT_TYPE_CFG,
00034         .inx = 0,
00035         .bw = AD7689_BW_FULL,
00036         .ref = ADC_REF_VOLTAGE_CFG,
00037         .seq = AD7689_SEQ_DISABLE,
00038         .rb = false
00039     },
00040 
00041     .spi_init = {
00042         .max_speed_hz = 22500000,
00043         .mode = NO_OS_SPI_MODE_0,
00044         .chip_select = SPI_CSB,
00045         .platform_ops = &spi_ops,
00046         .extra = &spi_extra_init_params
00047     }
00048 };