precision-converters-firmware
Loading...
Searching...
No Matches
Classes | Macros | Typedefs | Functions | Variables
app_config.h File Reference

Application configurations module headers for digipots IIO FW. More...

#include <stdint.h>
#include "common_macros.h"
#include "common.h"
#include "no_os_spi.h"
#include "no_os_i2c.h"
#include "no_os_gpio.h"
#include "no_os_uart.h"
#include "dpot.h"
#include "app_config_stm32.h"
Include dependency graph for app_config.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  dpot_device_info
 
struct  active_dpot_device_info
 Active device information for the initial configuration. More...
 

Macros

#define XSTR(s)   #s
 
#define STR(s)   XSTR(s)
 
#define DPOT_ADD_BOARD_DEVICE
 
#define ACTIVE_PLATFORM   STM32_PLATFORM
 
#define USE_VIRTUAL_COM_PORT
 
#define HW_MEZZANINE_NAME   "EVAL-MB-LV-ARDZ"
 
#define FIRMWARE_NAME   "digipots_iio"
 
#define MAX_CHNS_LINGAIN   8
 
#define MAX_CHNS_POTENTIOMETER   4
 
#define MAX_CHNS   12
 
#define IIO_UART_BAUD_RATE   (230400)
 
#define CONSOLE_STDIO_PORT_AVAILABLE
 
#define DEFAULT_ACTIVE_DEVICE   0XFF
 
#define DEFAULT_DEVICE_NAME   "ad5244"
 
#define DEFAULT_DEVICE_I2C_ADDR   0x2C
 
#define DEFAULT_NUM_CHNS_POT   4
 
#define DEFAULT_NUM_CHNS_LINGAIN   8
 
#define DEFAULT_OPERATING_MODE   DPOT_POTENTIOMETER_MODE
 
#define DEFAULT_INTERFACE_TYPE   AD_SPI_INTERFACE
 
#define MAX_DEVICE_NAME_LEN   10
 

Typedefs

typedef struct dpot_device_info dpot_device_info
 
typedef struct active_dpot_device_info active_dpot_device
 

Functions

int32_t init_system (void)
 Initialize the system peripherals.
 

Variables

struct no_os_uart_desc * uart_iio_com_desc
 
struct no_os_spi_init_param spi_mode2_init_params
 
struct no_os_spi_init_param spi_mode0_init_params
 
struct no_os_i2c_init_param i2c_init_params
 
struct no_os_eeprom_desc * eeprom_desc
 
char * active_virtual_com_serial_num
 
active_dpot_device oactive_dev
 
const struct dpot_ops ad5144_dpot_ops
 
const struct dpot_ops ad5141_dpot_ops
 
const struct dpot_ops ad5142_dpot_ops
 
const struct dpot_ops ad5143_dpot_ops
 
const struct dpot_ops ad5259_dpot_ops
 
const struct dpot_ops ad5161_dpot_ops
 
const struct dpot_ops ad5246_dpot_ops
 
const struct dpot_ops ad5242_dpot_ops
 
const struct dpot_ops ad5171_dpot_ops
 
const struct dpot_ops ad5165_dpot_ops
 
const struct dpot_ops ad5228_dpot_ops
 
struct ad5144_dpot_init_param ad5144_init_params
 
struct ad5141_dpot_init_param ad5141_init_params
 
struct ad5142_dpot_init_param ad5142_init_params
 
struct ad5143_dpot_init_param ad5143_init_params
 
struct ad5259_dpot_init_param ad5259_init_params
 
struct ad516x_dpot_init_param ad5161_init_params
 
struct ad5246_dpot_init_param ad5246_init_params
 
struct ad5242_dpot_init_param ad5242_init_params
 
struct ad5171_dpot_init_param ad5171_init_params
 
struct ad516x_dpot_init_param ad5165_init_params
 
struct ad5228_dpot_init_param ad5228_init_params
 
dpot_device_info dpot_info []
 

Detailed Description

Application configurations module headers for digipots IIO FW.

Copyright 2025(c) Analog Devices, Inc.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

  1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
  2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
  3. Neither the name of Analog Devices, Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY ANALOG DEVICES, INC. “AS IS” AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL ANALOG DEVICES, INC. BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Macro Definition Documentation

◆ ACTIVE_PLATFORM

#define ACTIVE_PLATFORM   STM32_PLATFORM

◆ CONSOLE_STDIO_PORT_AVAILABLE

#define CONSOLE_STDIO_PORT_AVAILABLE

◆ DEFAULT_ACTIVE_DEVICE

#define DEFAULT_ACTIVE_DEVICE   0XFF

◆ DEFAULT_DEVICE_I2C_ADDR

#define DEFAULT_DEVICE_I2C_ADDR   0x2C

◆ DEFAULT_DEVICE_NAME

#define DEFAULT_DEVICE_NAME   "ad5244"

◆ DEFAULT_INTERFACE_TYPE

#define DEFAULT_INTERFACE_TYPE   AD_SPI_INTERFACE

◆ DEFAULT_NUM_CHNS_LINGAIN

#define DEFAULT_NUM_CHNS_LINGAIN   8

◆ DEFAULT_NUM_CHNS_POT

#define DEFAULT_NUM_CHNS_POT   4

◆ DEFAULT_OPERATING_MODE

#define DEFAULT_OPERATING_MODE   DPOT_POTENTIOMETER_MODE

◆ DPOT_ADD_BOARD_DEVICE

#define DPOT_ADD_BOARD_DEVICE

◆ FIRMWARE_NAME

#define FIRMWARE_NAME   "digipots_iio"

◆ HW_MEZZANINE_NAME

#define HW_MEZZANINE_NAME   "EVAL-MB-LV-ARDZ"

◆ IIO_UART_BAUD_RATE

#define IIO_UART_BAUD_RATE   (230400)

◆ MAX_CHNS

#define MAX_CHNS   12

◆ MAX_CHNS_LINGAIN

#define MAX_CHNS_LINGAIN   8

◆ MAX_CHNS_POTENTIOMETER

#define MAX_CHNS_POTENTIOMETER   4

◆ MAX_DEVICE_NAME_LEN

#define MAX_DEVICE_NAME_LEN   10

◆ STR

#define STR (   s)    XSTR(s)

◆ USE_VIRTUAL_COM_PORT

#define USE_VIRTUAL_COM_PORT

◆ XSTR

#define XSTR (   s)    #s

Typedef Documentation

◆ active_dpot_device

◆ dpot_device_info

Function Documentation

◆ init_system()

int32_t init_system ( void  )

Initialize the system peripherals.

Returns
0 in case of success, negative error code otherwise

Initialize the system peripherals.

Returns
0 in case of success, negative error code otherwise.

This function initializes system peripherals for the application

Returns
- 0 in case of success, negative error code otherwise

Initialize the system peripherals.

Returns
0 in case of success, negative error code otherwise.

Variable Documentation

◆ active_virtual_com_serial_num

char* active_virtual_com_serial_num
extern

◆ ad5141_dpot_ops

const struct dpot_ops ad5141_dpot_ops
extern

◆ ad5141_init_params

struct ad5141_dpot_init_param ad5141_init_params
extern

◆ ad5142_dpot_ops

const struct dpot_ops ad5142_dpot_ops
extern

◆ ad5142_init_params

struct ad5142_dpot_init_param ad5142_init_params
extern

◆ ad5143_dpot_ops

const struct dpot_ops ad5143_dpot_ops
extern

◆ ad5143_init_params

struct ad5143_dpot_init_param ad5143_init_params
extern

◆ ad5144_dpot_ops

const struct dpot_ops ad5144_dpot_ops
extern

◆ ad5144_init_params

struct ad5144_dpot_init_param ad5144_init_params
extern

◆ ad5161_dpot_ops

const struct dpot_ops ad5161_dpot_ops
extern

◆ ad5161_init_params

struct ad516x_dpot_init_param ad5161_init_params
extern

◆ ad5165_dpot_ops

const struct dpot_ops ad5165_dpot_ops
extern

◆ ad5165_init_params

struct ad516x_dpot_init_param ad5165_init_params
extern

◆ ad5171_dpot_ops

const struct dpot_ops ad5171_dpot_ops
extern

◆ ad5171_init_params

struct ad5171_dpot_init_param ad5171_init_params
extern

◆ ad5228_dpot_ops

const struct dpot_ops ad5228_dpot_ops
extern

◆ ad5228_init_params

struct ad5228_dpot_init_param ad5228_init_params
extern

◆ ad5242_dpot_ops

const struct dpot_ops ad5242_dpot_ops
extern

◆ ad5242_init_params

struct ad5242_dpot_init_param ad5242_init_params
extern

◆ ad5246_dpot_ops

const struct dpot_ops ad5246_dpot_ops
extern

◆ ad5246_init_params

struct ad5246_dpot_init_param ad5246_init_params
extern

◆ ad5259_dpot_ops

const struct dpot_ops ad5259_dpot_ops
extern

◆ ad5259_init_params

struct ad5259_dpot_init_param ad5259_init_params
extern

◆ dpot_info

dpot_device_info dpot_info[]
extern

◆ eeprom_desc

struct no_os_eeprom_desc* eeprom_desc
extern

◆ i2c_init_params

struct no_os_i2c_init_param i2c_init_params
extern

◆ oactive_dev

active_dpot_device oactive_dev
extern

◆ spi_mode0_init_params

struct no_os_spi_init_param spi_mode0_init_params
extern

◆ spi_mode2_init_params

struct no_os_spi_init_param spi_mode2_init_params
extern

◆ uart_iio_com_desc

struct no_os_uart_desc* uart_iio_com_desc
extern