precision-converters-firmware
Classes | Macros | Enumerations | Functions | Variables
ad7124_console_app.h File Reference

: defines the console menu structure for the AD7124 example code More...

#include "adi_console_menu.h"
Include dependency graph for ad7124_console_app.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  ad7124_setup_config
 

Macros

#define AD7124_CONFIG_A   0
 
#define AD7124_CONFIG_B   1
 
#define LOW_POWER_MODE_FREQUENCY   76800
 
#define MED_POWER_MODE_FREQUENCY   153600
 
#define FUL_POWER_MODE_FREQUENCY   614400
 
#define DEVICE_REG_READ_ID   1
 
#define DEVICE_REG_WRITE_ID   2
 

Enumerations

enum  filter_type {
  SINC4_FILTER = 0 ,
  SINC3_FILTER = 2 ,
  FAST_SETTLING_SINC4_FILTER = 4 ,
  FAST_SETTLING_SINC3_FILTER = 5
}
 
enum  reference_type {
  REFIN1 ,
  REFIN2 ,
  INT ,
  AVDD
}
 
enum  power_mode_t {
  LOW_POWER_MODE ,
  MED_POWER_MODE ,
  FULL_POWER_MODE
}
 

Functions

int32_t ad7124_app_initialize (uint8_t configID)
 Initialize the AD7124 device and the SPI port as required. More...
 

Variables

console_menu ad7124_main_menu
 

Detailed Description

: defines the console menu structure for the AD7124 example code

:

Copyright (c) 2019, 2020 Analog Devices, Inc. All rights reserved.

This software is proprietary to Analog Devices, Inc. and its licensors. By using this software you agree to the terms of the associated Analog Devices Software License Agreement.

Macro Definition Documentation

◆ AD7124_CONFIG_A

#define AD7124_CONFIG_A   0

◆ AD7124_CONFIG_B

#define AD7124_CONFIG_B   1

◆ DEVICE_REG_READ_ID

#define DEVICE_REG_READ_ID   1

◆ DEVICE_REG_WRITE_ID

#define DEVICE_REG_WRITE_ID   2

◆ FUL_POWER_MODE_FREQUENCY

#define FUL_POWER_MODE_FREQUENCY   614400

◆ LOW_POWER_MODE_FREQUENCY

#define LOW_POWER_MODE_FREQUENCY   76800

◆ MED_POWER_MODE_FREQUENCY

#define MED_POWER_MODE_FREQUENCY   153600

Enumeration Type Documentation

◆ filter_type

Enumerator
SINC4_FILTER 
SINC3_FILTER 
FAST_SETTLING_SINC4_FILTER 
FAST_SETTLING_SINC3_FILTER 

◆ power_mode_t

Enumerator
LOW_POWER_MODE 
MED_POWER_MODE 
FULL_POWER_MODE 

◆ reference_type

Enumerator
REFIN1 
REFIN2 
INT 
AVDD 

Function Documentation

◆ ad7124_app_initialize()

int32_t ad7124_app_initialize ( uint8_t  config_id)

Initialize the AD7124 device and the SPI port as required.

Parameters
configID-Configuration ID
Returns
0 in case of success, negative error code otherwise

This resets and then writes the default register map value to the device. A call to init the SPI port is made, but may not actually do very much, depending on the platform

Initialize the AD7124 device and the SPI port as required.

Parameters
config_id[in]-Register configuration to be load into device
Returns
0 in case of success, negative error code otherwise

This resets and then writes the default register map value to the device. A call to init the SPI port is made, but may not actually do very much, depending on the platform.

Variable Documentation

◆ ad7124_main_menu

console_menu ad7124_main_menu
extern