Go to the documentation of this file.
48 #define AD9680_REG_INTERFACE_CONF_A 0x000
49 #define AD9680_REG_INTERFACE_CONF_B 0x001
50 #define AD9680_REG_CHIP_ID_LOW 0x004
51 #define AD9680_REG_CHIP_ID_HIGH 0x005
52 #define AD9680_REG_DEVICE_INDEX 0x008
53 #define AD9680_REG_CHIP_DEC_RATIO 0x201
54 #define AD9680_REG_ADC_TEST_MODE 0x550
55 #define AD9680_REG_OUTPUT_MODE 0x561
56 #define AD9680_REG_LINK_CONTROL 0x571
57 #define AD9680_REG_JESD204B_LANE_RATE_CTRL 0x56e
58 #define AD9680_REG_JESD204B_PLL_LOCK_STATUS 0x56f
59 #define AD9680_REG_JESD204B_QUICK_CONFIG 0x570
60 #define AD9680_REG_JESD_LINK_CTRL1_REG 0x571
61 #define AD9680_REG_JESD204B_MF_CTRL 0x58d
62 #define AD9680_REG_JESD204B_CSN_CONFIG 0x58f
63 #define AD9680_REG_JESD204B_SUBCLASS_CONFIG 0x590
64 #define AD9680_REG_JESD204B_LANE_SERD_OUT0_ASSIGN 0x5b2
65 #define AD9680_REG_JESD204B_LANE_SERD_OUT1_ASSIGN 0x5b3
66 #define AD9680_REG_JESD204B_LANE_SERD_OUT2_ASSIGN 0x5b5
67 #define AD9680_REG_JESD204B_LANE_SERD_OUT3_ASSIGN 0x5b6
69 #define AD9680_CHIP_ID 0x0C5
70 #define AD9680_TEST_OFF 0x000
71 #define AD9680_TEST_PN9 0x006
72 #define AD9680_TEST_PN23 0x005
73 #define AD9680_TEST_RAMP 0x00f
74 #define AD9680_FORMAT_2S_COMPLEMENT 0x001
75 #define AD9680_FORMAT_OFFSET_BINARY 0x000
76 #define AD9680_JESD_LINK_PDN NO_OS_BIT(0)
78 #define AD9680_SYSREF_NONE 0
79 #define AD9680_SYSREF_ONESHOT 2
80 #define AD9680_SYSREF_CONT 1
81 #define AD9680_SYSREF_MON 3
#define AD9680_REG_JESD204B_QUICK_CONFIG
Definition: ad9680.h:59
int32_t ad9680_setup_jesd_fsm(struct ad9680_dev **device, const struct ad9680_init_param *init_param)
Definition: ad9680.c:294
JESD204 link configuration settings.
Definition: jesd204.h:105
uint32_t lane_rate_kbps
Definition: ad9680.h:103
int32_t ad9680_spi_read(struct ad9680_dev *dev, uint16_t reg_addr, uint8_t *reg_data)
ad9680_spi_read
Definition: ad9680.c:51
struct jesd204_state_op state_ops[__JESD204_MAX_OPS]
Definition: jesd204.h:232
int32_t no_os_spi_write_and_read(struct no_os_spi_desc *desc, uint8_t *data, uint16_t bytes_number)
Write and read data to/from SPI.
Definition: no_os_spi.c:159
@ JESD204_STATE_OP_REASON_INIT
Definition: jesd204.h:148
#define AD9680_CHIP_ID
Definition: ad9680.h:69
Header file of SPI Interface.
unsigned long dcm
Definition: ad9680.h:107
#define AD9680_REG_JESD204B_PLL_LOCK_STATUS
Definition: ad9680.h:58
void jesd204_copy_link_params(struct jesd204_link *dst, const struct jesd204_link *src)
#define pr_err(fmt, args...)
Definition: no_os_print_log.h:88
Header file of AD9680 Driver.
struct no_os_spi_desc * spi_desc
Definition: ad9680.h:88
#define AD9680_REG_JESD204B_CSN_CONFIG
Definition: ad9680.h:62
Header file of Delay functions.
@ JESD204_ENCODER_8B10B
Definition: jesd204.h:30
enum jesd204_sysref_mode mode
Definition: jesd204.h:61
jesd204_state_op_reason
Definition: jesd204.h:147
Definition: ad9361_util.h:69
uint32_t sample_rate_div
Definition: jesd204.h:110
int32_t ad9680_setup_jesd_fsm(struct ad9680_dev **device, const struct ad9680_init_param *init_param)
Definition: ad9680.c:294
int ad9680_jesd_enable_link(struct ad9680_dev *dev, uint8_t en)
Definition: ad9680.c:147
struct jesd204_sysref sysref
Definition: jesd204.h:139
#define AD9680_REG_LINK_CONTROL
Definition: ad9680.h:56
void * jesd204_dev_priv(struct jesd204_dev *jdev)
void no_os_mdelay(uint32_t msecs)
Wait until msecs milliseconds passed.
Definition: aducm3029_delay.c:126
#define AD9680_REG_JESD204B_SUBCLASS_CONFIG
Definition: ad9680.h:63
#define AD9680_REG_INTERFACE_CONF_A
Definition: ad9680.h:48
@ JESD204_OP_CLOCKS_ENABLE
Definition: jesd204.h:210
#define pr_debug(fmt, args...)
Definition: no_os_print_log.h:129
#define AD9680_FORMAT_OFFSET_BINARY
Definition: ad9680.h:75
int32_t ad9680_spi_write(struct ad9680_dev *dev, uint16_t reg_addr, uint8_t reg_data)
ad9680_spi_write
Definition: ad9680.c:74
@ JESD204_OP_LINK_INIT
Definition: jesd204.h:198
#define AD9680_SYSREF_CONT
Definition: ad9680.h:80
@ JESD204_SYSREF_ONESHOT
Definition: jesd204.h:40
struct jesd204_link jesd204_link
Definition: ad9680.h:91
struct jesd204_dev * jdev
Definition: ad9680.h:90
int32_t ad9680_spi_write(struct ad9680_dev *dev, uint16_t reg_addr, uint8_t reg_data)
ad9680_spi_write
Definition: ad9680.c:74
int32_t ad9680_remove(struct ad9680_dev *dev)
Free the resources allocated by ad9680_setup().
Definition: ad9680.c:384
unsigned long long sampling_frequency_hz
Definition: ad9680.h:106
@ JESD204_OP_LINK_ENABLE
Definition: jesd204.h:211
Structure holding SPI descriptor.
Definition: no_os_spi.h:192
unsigned long long sampling_frequency_hz
Definition: ad9680.h:93
struct no_os_spi_init_param spi_init
Definition: ad9680.h:101
unsigned long sysref_mode
Definition: ad9680.h:96
#define AD9680_REG_JESD204B_MF_CTRL
Definition: ad9680.h:61
#define AD9680_TEST_OFF
Definition: ad9680.h:70
#define AD9680_REG_JESD204B_LANE_RATE_CTRL
Definition: ad9680.h:57
#define AD9680_FORMAT_2S_COMPLEMENT
Definition: ad9680.h:74
uint32_t link_id
Definition: jesd204.h:106
#define AD9680_REG_OUTPUT_MODE
Definition: ad9680.h:55
void * no_os_malloc(size_t size)
Allocate memory and return a pointer to it.
Definition: chibios_alloc.c:43
unsigned long dcm
Definition: ad9680.h:94
int32_t ad9680_spi_read(struct ad9680_dev *dev, uint16_t reg_addr, uint8_t *reg_data)
ad9680_spi_read
Definition: ad9680.c:51
int32_t ad9680_remove(struct ad9680_dev *dev)
Free the resources allocated by ad9680_setup().
Definition: ad9680.c:384
uint64_t sample_rate
Definition: jesd204.h:109
#define AD9680_SYSREF_ONESHOT
Definition: ad9680.h:79
void no_os_free(void *ptr)
Deallocate memory previously allocated by a call to no_os_calloc or no_os_malloc.
Definition: chibios_alloc.c:69
int jesd204_dev_register(struct jesd204_dev **jdev, const struct jesd204_dev_data *dev_data)
#define NULL
Definition: wrapper.h:64
struct ad7616_init_param init_param
Definition: ad7616_sdz.c:113
uint8_t jesd_encoder
Definition: jesd204.h:124
#define AD9680_REG_JESD_LINK_CTRL1_REG
Definition: ad9680.h:60
#define AD9680_JESD_LINK_PDN
Definition: ad9680.h:76
@ JESD204_STATE_CHANGE_DONE
Definition: jesd204.h:46
@ JESD204_SYSREF_CONTINUOUS
Definition: jesd204.h:39
int32_t ad9680_setup(struct ad9680_dev **device, const struct ad9680_init_param *init_param)
ad9680_setup
Definition: ad9680.c:220
int32_t no_os_spi_remove(struct no_os_spi_desc *desc)
Free the resources allocated by no_os_spi_init().
Definition: no_os_spi.c:116
jesd204_link_cb per_link
Definition: jesd204.h:192
int32_t no_os_spi_init(struct no_os_spi_desc **desc, const struct no_os_spi_init_param *param)
Initialize the SPI communication peripheral.
Definition: no_os_spi.c:52
int32_t ad9680_test(struct ad9680_dev *dev, uint32_t test_mode)
Definition: ad9680.c:96
Header file of utility functions.
int32_t ad9680_test(struct ad9680_dev *dev, uint32_t test_mode)
Definition: ad9680.c:96
#define AD9680_REG_ADC_TEST_MODE
Definition: ad9680.h:54
int32_t ad9680_setup(struct ad9680_dev **device, const struct ad9680_init_param *init_param)
ad9680_setup
Definition: ad9680.c:220
JESD204 device initialization data.
Definition: jesd204.h:227
struct ad9680_dev * dev
Definition: ad9680.c:45
#define AD9680_REG_CHIP_ID_LOW
Definition: ad9680.h:50
chip_id
Definition: ad9172.h:51
Structure holding the parameters for SPI initialization.
Definition: no_os_spi.h:140
unsigned long sysref_mode
Definition: ad9680.h:108