Header file for admfm2000 Driver.
More...
#include <stdint.h>
#include "no_os_gpio.h"
Header file for admfm2000 Driver.
- Author
- Ramona Nechita (ramon.nosp@m.a.ne.nosp@m.chita.nosp@m.@ana.nosp@m.log.c.nosp@m.om)
Copyright 2025(c) Analog Devices, Inc.
SPDX-License-Identifier: BSD-3-Clause
◆ ADMFM2000_DEFAULT_GAIN
| #define ADMFM2000_DEFAULT_GAIN -0x20 |
◆ ADMFM2000_DIRECT_IF_MODE
| #define ADMFM2000_DIRECT_IF_MODE 1 |
◆ ADMFM2000_DSA_GPIOS
| #define ADMFM2000_DSA_GPIOS 5 |
◆ ADMFM2000_MAX_GAIN
| #define ADMFM2000_MAX_GAIN 0 |
◆ ADMFM2000_MAX_GAIN_RAW
| #define ADMFM2000_MAX_GAIN_RAW 31 |
◆ ADMFM2000_MIN_GAIN
| #define ADMFM2000_MIN_GAIN -31000 |
◆ ADMFM2000_MIN_GAIN_RAW
| #define ADMFM2000_MIN_GAIN_RAW 0 |
◆ ADMFM2000_MIXER_MODE
| #define ADMFM2000_MIXER_MODE 0 |
◆ ADMFM2000_MODE_GPIOS
| #define ADMFM2000_MODE_GPIOS 2 |
◆ ADMFM2000_NUM_CHANNELS
| #define ADMFM2000_NUM_CHANNELS 2 |
◆ admfm2000_get_channel_mode()
| int admfm2000_get_channel_mode |
( |
struct admfm2000_dev * | dev, |
|
|
uint8_t | mode ) |
◆ admfm2000_get_dsa_raw()
| int admfm2000_get_dsa_raw |
( |
struct admfm2000_dev * | dev, |
|
|
uint8_t | chan, |
|
|
int32_t * | dsa_raw ) |
Get the value of the dsa pins of the device.
- Parameters
-
| dev | - The device structure. |
| chan | - The channel for which the value is read. |
| dsa_raw | - The raw value from DSA gpios. |
- Returns
- Returns 0 in case of success or negative error code otherwise.
◆ admfm2000_init()
Initialize the admfm2000 device.
- Parameters
-
| device | - The device structure. |
| init_param | - The structure that contains the device initial parameters. |
- Returns
- Returns 0 in case of success or negative error code otherwise.
◆ admfm2000_remove()
Free the resources allocated by admfm2000_init().
- Parameters
-
| dev | - The device structure. |
- Returns
- ret - Result of the remove procedure.
◆ admfm2000_set_channel_config()
| int admfm2000_set_channel_config |
( |
struct admfm2000_dev * | dev, |
|
|
uint8_t | config ) |
Set the channel configuration.
- Parameters
-
| dev | - The device structure. |
| config | - The config |
- Returns
- Returns 0 in case of success or negative error code otherwise.
◆ admfm2000_set_dsa_raw()
| int admfm2000_set_dsa_raw |
( |
struct admfm2000_dev * | dev, |
|
|
uint8_t | chan, |
|
|
int32_t | dsa_raw ) |
Set the DSA GPIOs of the device.
- Parameters
-
| dev | - The device structure. |
| chan | - The channel for which the value is set. |
| dsa_raw | - The raw value for GPIOs. |
- Returns
- Returns 0 in case of success or negative error code otherwise.