![]() |
no-OS
|
Header file implementation of AD5592R/AD5593R IIO driver. More...
Go to the source code of this file.
Classes | |
| struct | ad559xr_aio_port |
| struct | iio_ad559xr_desc |
| struct | iio_ad559xr_gpio_map |
Macros | |
| #define | AD559XR_MAX_AIO_PORT 8 |
| #define | AD559XR_MAX_PORT_NAMELEN 24 |
| #define | AD559XR_ADC_RESOLUTION 12 |
| #define | AD559XR_STORAGE_BITS 16 |
| #define | AD559XR_STORAGE_BYTES (AD559XR_STORAGE_BITS/8) |
| #define | AD559XR_FULL_SCALE_VALUE ((1 << AD559XR_ADC_RESOLUTION) - 1) |
| #define | AD559XR_MIN_VDD 1.0f |
| #define | AD559XR_MAX_VDD 5.5f |
| #define | AD559XR_INTERNAL_VREF 2.5f |
| #define | AD5599XR_MAX_SAMPLE_SIZE (1024) |
| #define | AD559XR_SLOPE_CONSTANT (3767897513/25) |
| #define | AD559XR_SLOPE_NANO_SCALE 1000000000 |
Functions | |
| int | iio_ad559xr_aio_init (struct iio_ad559xr_desc **desc, struct ad5592r_dev *ad5592r) |
| Initialize an ad559xr iio descriptor for all ADC and DAC channels for one ad559xr device. | |
| int | iio_ad559xr_gpio_init (struct iio_ad559xr_desc **desc, struct iio_ad559xr_gpio_map *gpio_map, const size_t count) |
| Initialize an ad559xr iio descriptor for all GPIO channels. | |
| int | iio_ad559xr_remove (struct iio_ad559xr_desc *desc) |
| Remove an ad559xr iio descriptor. | |
Header file implementation of AD5592R/AD5593R IIO driver.
Copyright 2026(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:
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.
| #define AD5599XR_MAX_SAMPLE_SIZE (1024) |
| #define AD559XR_ADC_RESOLUTION 12 |
| #define AD559XR_FULL_SCALE_VALUE ((1 << AD559XR_ADC_RESOLUTION) - 1) |
| #define AD559XR_INTERNAL_VREF 2.5f |
| #define AD559XR_MAX_AIO_PORT 8 |
| #define AD559XR_MAX_PORT_NAMELEN 24 |
| #define AD559XR_MAX_VDD 5.5f |
| #define AD559XR_MIN_VDD 1.0f |
| #define AD559XR_SLOPE_CONSTANT (3767897513/25) |
| #define AD559XR_SLOPE_NANO_SCALE 1000000000 |
| #define AD559XR_STORAGE_BITS 16 |
| #define AD559XR_STORAGE_BYTES (AD559XR_STORAGE_BITS/8) |
| anonymous enum |
| int iio_ad559xr_aio_init | ( | struct iio_ad559xr_desc ** | desc, |
| struct ad5592r_dev * | ad5592r ) |
Initialize an ad559xr iio descriptor for all ADC and DAC channels for one ad559xr device.
| [in] | desc | pointer to iio_ad559xr_desc ad559xr iio descriptor |
| [in] | ad5592r | pointer to ad5592r_dev |
desc is NULL. | int iio_ad559xr_gpio_init | ( | struct iio_ad559xr_desc ** | desc, |
| struct iio_ad559xr_gpio_map * | gpio_map, | ||
| const size_t | count ) |
Initialize an ad559xr iio descriptor for all GPIO channels.
This function takes an array called a gpio_map. It collects all the channels defined in all ad559xr devices declared in the gpio_map and creates one single ad559xr iio descriptor for all.
| [in] | desc | pointer to iio_ad559xr_desc ad559xr iio descriptor |
| [in] | gpio_map | pointer to gpio_map |
| [in] | count | number of gpio_maps |
desc and gpio_map are both NULL. | int iio_ad559xr_remove | ( | struct iio_ad559xr_desc * | desc | ) |
Remove an ad559xr iio descriptor.
Releases memory associated with an ad559xr iio descriptor and also frees up the iio descriptor memory itself.
| [in] | desc | pointer to iio_ad559xr_desc ad559xr iio descriptor |