Analog Devices / Mbed OS EVAL-AD4110

Dependencies:   tempsensors sdp_k1_sdram

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers ad4110_thermcouple_mode_config.c Source File

ad4110_thermcouple_mode_config.c

00001 /*************************************************************************//**
00002  *   @file   ad4110_thermocouple_mode_config.c
00003  *   @brief  Source file for AD4110 thermocouple configurations module
00004 ******************************************************************************
00005 * Copyright (c) 2022 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 "ad4110.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 /* AD4110-1 Init parameters */
00029 struct ad4110_init_param ad4110_thermocouple_mode_init_params = {
00030     .spi_init = {
00031         .max_speed_hz = 10000000,
00032         .chip_select = SPI_CSB,
00033         .mode = NO_OS_SPI_MODE_3,
00034         .extra = &spi_extra_init_params,
00035         .platform_ops = &spi_platform_ops
00036     },
00037     .volt_ref = AD4110_EXT_REF,
00038     .data_stat = AD4110_DISABLE,
00039     .data_length = AD4110_DATA_WL24,
00040     .afe_crc_en = AD4110_AFE_CRC_DISABLE,
00041     .adc_crc_en = AD4110_ADC_CRC_DISABLE,
00042     .op_mode = AD4110_THERMOCOUPLE,
00043     .gain = GAIN_CH,
00044     .sync = AD4110_SYNC_EN,
00045     .afe_clk = AD4110_AFE_ADC_CLOCKED,
00046     .adc_clk = AD4110_ADC_INT_CLK_CLKIO,
00047     .addr = 0,
00048     .bipolar = true,
00049     .analog_input_buff = ENABLE_FULL_BUFFER,
00050     .odr = AD4110_ODR_SEL,
00051     .order = sinc5_sinc1
00052 } ;