Go to the documentation of this file.
49 #define AD6673_READ (1 << 15)
50 #define AD6673_WRITE (0 << 15)
51 #define AD6673_CNT(x) ((((x) & 0x3) - 1) << 13)
52 #define AD6673_ADDR(x) ((x) & 0xFF)
54 #define AD6673_R1B (1 << 8)
55 #define AD6673_R2B (2 << 8)
56 #define AD6673_R3B (3 << 8)
57 #define AD6673_TRANSF_LEN(x) (((x) >> 8) & 0xFF)
58 #define SHADOW(x) ((x) << 16)
61 #define AD6673_REG_SPI_CFG (AD6673_R1B | 0x00)
62 #define AD6673_REG_CHIP_ID (AD6673_R1B | 0x01)
63 #define AD6673_REG_CHIP_INFO (AD6673_R1B | 0x02)
66 #define AD6673_REG_CH_INDEX (AD6673_R1B | 0x05)
67 #define AD6673_REG_DEVICE_UPDATE (AD6673_R1B | 0xFF)
70 #define AD6673_REG_PDWN (AD6673_R1B | 0x08)
71 #define AD6673_REG_CLOCK (AD6673_R1B | 0x09 | SHADOW(1))
72 #define AD6673_REG_PLL_STAT (AD6673_R1B | 0x0A)
73 #define AD6673_REG_CLOCK_DIV (AD6673_R1B | 0x0B | SHADOW(2))
74 #define AD6673_REG_TEST (AD6673_R1B | 0x0D | SHADOW(3))
75 #define AD6673_REG_BIST (AD6673_R1B | 0x0E | SHADOW(4))
76 #define AD6673_REG_OFFSET (AD6673_R1B | 0x10 | SHADOW(5))
77 #define AD6673_REG_OUT_MODE (AD6673_R1B | 0x14 | SHADOW(6))
78 #define AD6673_REG_CML (AD6673_R1B | 0x15)
79 #define AD6673_REG_VREF (AD6673_R1B | 0x18 | SHADOW(7))
80 #define AD6673_REG_USER_TEST1 (AD6673_R2B | 0x1A)
81 #define AD6673_REG_USER_TEST2 (AD6673_R2B | 0x1C)
82 #define AD6673_REG_USER_TEST3 (AD6673_R2B | 0x1E)
83 #define AD6673_REG_USER_TEST4 (AD6673_R2B | 0x20)
84 #define AD6673_REG_PLL_ENCODE (AD6673_R1B | 0x21)
85 #define AD6673_REG_BIST_MISR (AD6673_R2B | 0x25)
86 #define AD6673_REG_SYS_CTRL (AD6673_R1B | 0x3A | SHADOW(8))
87 #define AD6673_REG_NSR_CTRL (AD6673_R1B | 0x3C | SHADOW(9))
88 #define AD6673_REG_NSR_TUNING (AD6673_R1B | 0x3E | SHADOW(10))
89 #define AD6673_REG_DCC_CTRL (AD6673_R1B | 0x40 | SHADOW(11))
90 #define AD6673_REG_DCC_VAL (AD6673_R2B | 0x42 | SHADOW(12))
91 #define AD6673_REG_FAST_DETECT (AD6673_R1B | 0x45 | SHADOW(13))
92 #define AD6673_REG_FD_UPPER_THD (AD6673_R2B | 0x48 | SHADOW(14))
93 #define AD6673_REG_FD_LOWER_THD (AD6673_R2B | 0x4A | SHADOW(15))
94 #define AD6673_REG_FD_DWELL_TIME (AD6673_R2B | 0x4C | SHADOW(16))
95 #define AD6673_REG_204B_QUICK_CFG (AD6673_R1B | 0x5E)
96 #define AD6673_REG_204B_CTRL1 (AD6673_R1B | 0x5F)
97 #define AD6673_REG_204B_CTRL2 (AD6673_R1B | 0x60)
98 #define AD6673_REG_204B_CTRL3 (AD6673_R1B | 0x61)
99 #define AD6673_REG_204B_DID_CFG (AD6673_R1B | 0x64)
100 #define AD6673_REG_204B_BID_CFG (AD6673_R1B | 0x65)
101 #define AD6673_REG_204B_LID_CFG1 (AD6673_R1B | 0x67)
102 #define AD6673_REG_204B_LID_CFG2 (AD6673_R1B | 0x68)
103 #define AD6673_REG_204B_PARAM_SCR_L (AD6673_R1B | 0x6E)
104 #define AD6673_REG_204B_PARAM_F (AD6673_R1B | 0x6F)
105 #define AD6673_REG_204B_PARAM_K (AD6673_R1B | 0x70)
106 #define AD6673_REG_204B_PARAM_M (AD6673_R1B | 0x71)
107 #define AD6673_REG_204B_PARAM_CS_N (AD6673_R1B | 0x72)
108 #define AD6673_REG_204B_PARAM_NP (AD6673_R1B | 0x73)
109 #define AD6673_REG_204B_PARAM_S (AD6673_R1B | 0x74)
110 #define AD6673_REG_204B_PARAM_HD_CF (AD6673_R1B | 0x75)
111 #define AD6673_REG_204B_RESV1 (AD6673_R1B | 0x76)
112 #define AD6673_REG_204B_RESV2 (AD6673_R1B | 0x77)
113 #define AD6673_REG_204B_CHKSUM0 (AD6673_R1B | 0x79)
114 #define AD6673_REG_204B_CHKSUM1 (AD6673_R1B | 0x7A)
115 #define AD6673_REG_204B_LANE_ASSGN1 (AD6673_R1B | 0x82)
116 #define AD6673_REG_204B_LANE_ASSGN2 (AD6673_R1B | 0x83)
117 #define AD6673_REG_204B_LMFC_OFFSET (AD6673_R1B | 0x8B)
118 #define AD6673_REG_204B_PRE_EMPHASIS (AD6673_R1B | 0xA8)
121 #define AD6673_SPI_CFG_LSB_FIRST ((1 << 6) | (1 << 1))
122 #define AD6673_SPI_CFG_SOFT_RST ((1 << 5) | (1 << 2))
125 #define AD6673_CH_INDEX_ADC_A (1 << 0)
126 #define AD6673_CH_INDEX_ADC_B (1 << 1)
129 #define AD6673_DEVICE_UPDATE_SW (1 << 0)
132 #define AD6673_PDWN_EXTERN (1 << 5)
133 #define AD6673_PDWN_JTX (1 << 4)
134 #define AD6673_PDWN_JESD204B(x) (((x) & 0x3) << 2)
135 #define AD6673_PDWN_CHIP(x) (((x) & 0x3) << 0)
138 #define AD6673_CLOCK_SELECTION(x) (((x) & 0x3) << 4)
139 #define AD6673_CLOCK_DUTY_CYCLE (1 << 0)
142 #define AD6673_PLL_STAT_LOCKED (1 << 7)
143 #define AD6673_PLL_STAT_204B_LINK_RDY (1 << 0)
146 #define AD6673_CLOCK_DIV_PHASE(x) (((x) & 0x7) << 3)
147 #define AD6673_CLOCK_DIV_RATIO(x) (((x) & 0x7) << 0)
150 #define AD6673_TEST_USER_TEST_MODE(x) (((x) & 0x3) << 6)
151 #define AD6673_TEST_RST_PN_LONG (1 << 5)
152 #define AD6673_TEST_RST_PN_SHOR (1 << 4)
153 #define AD6673_TEST_OUTPUT_TEST(x) (((x) & 0xF) << 0)
156 #define AD6673_BIST_RESET (1 << 2)
157 #define AD6673_BIST_ENABLE (1 << 0)
160 #define AD6673_REG_OFFSET_ADJUST(x) (((x) & 0x3F) << 0)
163 #define AD6673_OUT_MODE_JTX_BIT_ASSIGN(x) (((x) & 0x7) << 5)
164 #define AD6673_OUT_MODE_DISABLE (1 << 4)
165 #define AD6673_OUT_MODE_INVERT_DATA (1 << 3)
166 #define AD6673_OUT_MODE_DATA_FORMAT(x) (((x) & 0x1) << 0)
169 #define AD6673_CML_DIFF_OUT_LEVEL(x) (((x) & 0x7) << 0)
172 #define AD6673_VREF_FS_ADJUST(x) (((x) & 0x1F) << 0)
175 #define AD6673_PLL_ENCODE(x) (((x) & 0x3) << 3)
178 #define AD6673_SYS_CTRL_REALIGN_ON_SYNCINB (1 << 4)
179 #define AD6673_SYS_CTRL_REALIGN_ON_SYSREF (1 << 3)
180 #define AD6673_SYS_CTRL_SYSREF_MODE (1 << 2)
181 #define AD6673_SYS_CTRL_SYSREF_EN (1 << 1)
182 #define AD6673_SYS_CTRL_SYNCINB_EN (1 << 0)
185 #define AD6673_NSR_CTRL_BW_MODE (1 << 1)
186 #define AD6673_NSR_CTRL_ENABLE (1 << 0)
189 #define AD6673_NSR_TUNING(x) (((x) & 0x3F) << 0)
192 #define AD6673_DCC_CTRL_FREEZE_DCC (1 << 6)
193 #define AD6673_DCC_CTRL_DCC_BW(x) (((x) & 0xF) << 2)
194 #define AD6673_DCC_CTRL_DCC_EN (1 << 1)
197 #define AD6673_FAST_DETECT_PIN_FCT (1 << 4)
198 #define AD6673_FAST_DETECT_FORCE_FDA_FDB_PIN (1 << 3)
199 #define AD6673_FAST_DETECT_FORCE_FDA_FDB_VAL (1 << 2)
200 #define AD6673_FAST_DETECT_OUTPUT_ENABLE (1 << 0)
203 #define AD6673_204B_QUICK_CFG(x) (((x) & 0xFF) << 0)
206 #define AD6673_204B_CTRL1_TAIL_BITS (1 << 6)
207 #define AD6673_204B_CTRL1_TEST_SAMPLE_EN (1 << 5)
208 #define AD6673_204B_CTRL1_ILAS_MODE(x) (((x) & 0x3) << 2)
209 #define AD6673_204B_CTRL1_POWER_DOWN (1 << 0)
212 #define AD6673_204B_CTRL2_INVERT_JESD_BITS (1 << 1)
215 #define AD6673_204B_CTRL3_TEST_DATA_INJ_PT(x) (((x) & 0x3) << 4)
216 #define AD6673_204B_CTRL3_JESD_TEST_MODE(x) (((x) & 0xF) << 0)
219 #define AD6673_204B_PARAM_SCR_L_SCRAMBLING (1 << 7)
220 #define AD6673_204B_PARAM_SCR_L_LANES (1 << 0)
223 #define AD6673_204B_PARAM_CS_N_NR_CTRL_BITS(x) (((x) & 0x3) << 6)
224 #define AD6673_204B_PARAM_CS_N_ADC_RESOLUTION(x) (((x) & 0xF) << 0)
227 #define AD6673_204B_PARAM_NP_JESD_SUBCLASS(x) (((x) & 0x3) << 5)
228 #define AD6673_204B_PARAM_NP_JESD_N_VAL(x) (((x) & 0xF) << 0)
231 #define AD6673_204B_PARAM_S(x) (((x) << 0x1F) << 0)
234 #define AD6673_204B_PARAM_HD_CF_HD_VAL (1 << 7)
235 #define AD6673_204B_PARAM_HD_CF_CF_VAL(x) (((x) & 0x1F) << 0)
238 #define AD6673_204B_LANE_ASSGN1(x) (((x) & 0x3) << 4)
241 #define AD6673_204B_LANE_ASSGN2(x) (((x) &0x3) << 0)
244 #define AD6673_204B_LMFC_OFFSET(x) (((x) & 0x1F) << 0)
541 int32_t register_address);
544 int32_t register_address,
545 int32_t register_value);
580 int32_t user_pattern);
#define AD6673_REG_PLL_ENCODE
Definition: ad6673.h:84
int32_t ad6673_output_disable(struct ad6673_dev *dev, int32_t en)
Disables (1) or enables (0) the data output. Note: This function modifies a shadowed register,...
Definition: ad6673.c:545
@ AD6673_SHD_REG_CLOCK
Definition: ad6673.h:498
int16_t fd_lower_tresh
Definition: ad6673.h:480
int8_t en_fd
Definition: ad6673.h:458
#define AD6673_FAST_DETECT_FORCE_FDA_FDB_VAL
Definition: ad6673.h:199
#define AD6673_REG_204B_CTRL1
Definition: ad6673.h:96
@ AD6673_REG_SHD_NSR_CTRL
Definition: ad6673.h:506
uint32_t timeout
Definition: ad413x.c:49
int32_t ad6673_write(struct ad6673_dev *dev, int32_t register_address, int32_t register_value)
Writes a value to the selected register.
Definition: ad6673.c:244
#define AD6673_CML_DIFF_OUT_LEVEL(x)
Definition: ad6673.h:169
#define AD6673_NSR_CTRL_ENABLE
Definition: ad6673.h:186
#define AD6673_204B_QUICK_CFG(x)
Definition: ad6673.h:203
shadow_registers
Definition: ad6673.h:497
#define SHADOW(x)
Definition: ad6673.h:58
@ AD6673_SHD_REG_SYS_CTRL
Definition: ad6673.h:505
int32_t ad6673_dcc_enable(struct ad6673_dev *dev, int32_t enable)
Enables DC correction for use in the output data signal path.
Definition: ad6673.c:1207
int32_t ad6673_nsr_bandwidth_mode(struct ad6673_dev *dev, int32_t mode)
Selects the NSR Bandwidth mode.
Definition: ad6673.c:1337
int32_t ad6673_jesd204b_invert_logic(struct ad6673_dev *dev, int32_t invert)
Inverts the logic of JESD204B bits.
Definition: ad6673.c:1131
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
Header file of AD6673 Driver Configuration.
#define AD6673_REG_204B_QUICK_CFG
Definition: ad6673.h:95
int32_t ad6673_output_invert(struct ad6673_dev *dev, int32_t invert)
Activates the inverted (1) or normal (0) output mode. Note: This function modifies a shadowed registe...
Definition: ad6673.c:580
int8_t ctrl_bits_assign
Definition: ad6673.h:361
#define AD6673_REG_FD_LOWER_THD
Definition: ad6673.h:93
struct ad6673_platform_data * pdata
Definition: ad6673.h:492
Header file of SPI Interface.
int32_t ad6673_dcc_enable(struct ad6673_dev *dev, int32_t enable)
Enables DC correction for use in the output data signal path.
Definition: ad6673.c:1207
#define AD6673_TEST_RST_PN_SHOR
Definition: ad6673.h:152
#define AD6673_REG_204B_PARAM_K
Definition: ad6673.h:105
#define AD6673_REG_204B_BID_CFG
Definition: ad6673.h:100
#define AD6673_REG_FAST_DETECT
Definition: ad6673.h:91
#define AD6673_204B_CTRL1_TEST_SAMPLE_EN
Definition: ad6673.h:207
#define AD6673_204B_PARAM_CS_N_NR_CTRL_BITS(x)
Definition: ad6673.h:223
struct ad6673_state ad6673_st
Definition: ad6673.h:521
int32_t ad6673_output_invert(struct ad6673_dev *dev, int32_t invert)
Activates the inverted (1) or normal (0) output mode. Note: This function modifies a shadowed registe...
Definition: ad6673.c:580
#define AD6673_REG_PDWN
Definition: ad6673.h:70
int32_t ad6673_reset_pn9(struct ad6673_dev *dev, int32_t rst)
Sets (1) or clears (0) the reset short PN sequence bit(PN9).
Definition: ad6673.c:648
@ AD6673_SHD_REG_DCC_VAL
Definition: ad6673.h:509
int32_t ad6673_nsr_enable(struct ad6673_dev *dev, int32_t enable)
Enables the Noise shaped requantizer(NRS).
Definition: ad6673.c:1305
int8_t pin_function
Definition: ad6673.h:464
int32_t ad6673_nsr_tuning_freq(int64_t tune_freq, int64_t f_adc, struct ad6673_type_band *p_band)
Sets the NSR frequency range.
Definition: ad6673.c:1370
#define AD6673_REG_204B_CTRL2
Definition: ad6673.h:97
int32_t ad6673_dcc_bandwidth(struct ad6673_dev *dev, int32_t bw)
Selects the bandwidth value for the DC correction circuit.
Definition: ad6673.c:1241
int32_t ad6673_bist_enable(struct ad6673_dev *dev, int32_t enable)
Enables the Build-In-Self-Test.
Definition: ad6673.c:733
#define AD6673_REG_OUT_MODE
Definition: ad6673.h:77
int32_t ad6673_soft_reset(struct ad6673_dev *dev)
Resets all registers to their default values.
Definition: ad6673.c:320
#define AD6673_BIST_RESET
Definition: ad6673.h:156
#define AD6673_REG_NSR_CTRL
Definition: ad6673.h:87
#define AD6673_204B_CTRL3_TEST_DATA_INJ_PT(x)
Definition: ad6673.h:215
int32_t ad6673_select_channel_for_config(struct ad6673_dev *dev, int32_t channel)
Selects a channel as the current channel for further configurations.
Definition: ad6673.c:445
int8_t bid
Definition: ad6673.h:371
enum no_os_spi_mode mode
Definition: no_os_spi.h:148
#define AD6673_PLL_ENCODE(x)
Definition: ad6673.h:175
@ AD6673_SHD_REG_CLOCK_DIV
Definition: ad6673.h:499
#define AD6673_READ
Definition: ad6673.h:49
const int32_t shadow_regs[SHADOW_REGISTER_COUNT]
Definition: ad9250.c:45
struct ad6673_jesd204b_cfg ad6673_jesd204b_interface
Definition: ad6673_cfg.h:55
Definition: ad9361_util.h:69
@ AD6673_REG_SHD_NSR_TUNING
Definition: ad6673.h:507
#define AD6673_REG_CLOCK_DIV
Definition: ad6673.h:73
int32_t ad6673_reset_pn23(struct ad6673_dev *dev, int32_t rst)
Sets (1) or clears (0) the reset long PN sequence bit(PN23).
Definition: ad6673.c:680
int8_t did
Definition: ad6673.h:369
int32_t ad6673_fast_detect_setup(struct ad6673_dev *dev)
Configures the Fast-Detect module.
Definition: ad6673.c:1160
int32_t ad6673_set_bits_to_reg(struct ad6673_dev *dev, uint32_t register_address, uint8_t bits_value, uint8_t mask)
Sets a bit/group of bits inside a register without modifying other bits.
Definition: ad6673.c:355
#define AD6673_CLOCK_DIV_PHASE(x)
Definition: ad6673.h:146
struct no_os_spi_init_param spi_init
Definition: ad6673.h:527
#define AD6673_PDWN_EXTERN
Definition: ad6673.h:132
int32_t ad6673_reset_pn9(struct ad6673_dev *dev, int32_t rst)
Sets (1) or clears (0) the reset short PN sequence bit(PN9).
Definition: ad6673.c:648
#define AD6673_BIST_ENABLE
Definition: ad6673.h:157
#define AD6673_CLOCK_SELECTION(x)
Definition: ad6673.h:138
int32_t ad6673_chip_pwr_mode(struct ad6673_dev *dev, int32_t mode)
Configures the power mode of the chip.
Definition: ad6673.c:412
#define AD6673_SYS_CTRL_SYSREF_EN
Definition: ad6673.h:181
#define AD6673_DCC_CTRL_FREEZE_DCC
Definition: ad6673.h:192
int32_t ad6673_jesd204b_test_mode(struct ad6673_dev *dev, int32_t test_mode)
Selects a JESD204B test mode.
Definition: ad6673.c:1099
#define AD6673_WRITE
Definition: ad6673.h:50
int32_t ad6673_jesd204b_select_test_injection_point(struct ad6673_dev *dev, int32_t inj_point)
Selects the point in the processing path of a lane, where the test data will be inserted.
Definition: ad6673.c:1058
int32_t ad6673_bist_enable(struct ad6673_dev *dev, int32_t enable)
Enables the Build-In-Self-Test.
Definition: ad6673.c:733
#define AD6673_204B_CTRL1_POWER_DOWN
Definition: ad6673.h:209
int32_t ad6673_output_format(struct ad6673_dev *dev, int32_t format)
Specifies the output format. Note: This function modifies a shadowed register, therefore a call of ad...
Definition: ad6673.c:616
int32_t ad6673_read(struct ad6673_dev *dev, int32_t register_address)
Reads the value of the selected register.
Definition: ad6673.c:207
#define AD6673_REG_CH_INDEX
Definition: ad6673.h:66
#define AD6673_REG_USER_TEST1
Definition: ad6673.h:80
#define AD6673_SYS_CTRL_REALIGN_ON_SYSREF
Definition: ad6673.h:179
int32_t ad6673_remove(struct ad6673_dev *dev)
Free the resources allocated by ad6673_setup().
Definition: ad6673.c:188
int8_t lane0_assign
Definition: ad6673.h:440
int8_t subclass
Definition: ad6673.h:344
@ SHADOW_REGISTER_COUNT
Definition: ad6673.h:514
int8_t lid0
Definition: ad6673.h:373
#define AD6673_DEVICE_UPDATE_SW
Definition: ad6673.h:129
int8_t align_sys_ref
Definition: ad6673.h:434
int8_t force_pins
Definition: ad6673.h:470
int32_t ad6673_jesd204b_setup(struct ad6673_dev *dev)
Configures the JESD204B interface.
Definition: ad6673.c:832
int32_t ad6673_dcc_bandwidth(struct ad6673_dev *dev, int32_t bw)
Selects the bandwidth value for the DC correction circuit.
Definition: ad6673.c:1241
@ AD6673_SHD_REG_OFFSET
Definition: ad6673.h:502
int8_t lane1_assign
Definition: ad6673.h:445
#define AD6673_DCC_CTRL_DCC_BW(x)
Definition: ad6673.h:193
#define AD6673_REG_BIST
Definition: ad6673.h:75
#define AD6673_CLOCK_DUTY_CYCLE
Definition: ad6673.h:139
#define AD6673_REG_FD_DWELL_TIME
Definition: ad6673.h:94
int32_t ad6673_is_shadow_register(int32_t register_address)
Checks if the register is shadowed.
Definition: ad6673.c:396
int32_t ad6673_select_channel_for_config(struct ad6673_dev *dev, int32_t channel)
Selects a channel as the current channel for further configurations.
Definition: ad6673.c:445
#define AD6673_REG_204B_PARAM_SCR_L
Definition: ad6673.h:103
int8_t jtx_in_standby
Definition: ad6673.h:321
#define AD6673_OUT_MODE_INVERT_DATA
Definition: ad6673.h:165
#define AD6673_REG_204B_LANE_ASSGN2
Definition: ad6673.h:116
int32_t ad6673_output_format(struct ad6673_dev *dev, int32_t format)
Specifies the output format. Note: This function modifies a shadowed register, therefore a call of ad...
Definition: ad6673.c:616
int8_t ilas_mode
Definition: ad6673.h:392
int32_t ad6673_read(struct ad6673_dev *dev, int32_t register_address)
Reads the value of the selected register.
Definition: ad6673.c:207
#define AD6673_204B_CTRL1_ILAS_MODE(x)
Definition: ad6673.h:208
@ AD6673_SHD_REG_OUT_MODE
Definition: ad6673.h:503
@ AD6673_SHD_REG_FD_DWELL_TIME
Definition: ad6673.h:513
int32_t ad6673_test_mode(struct ad6673_dev *dev, int32_t mode)
Sets the ADC's test mode.
Definition: ad6673.c:485
int32_t ad6673_jesd204b_invert_logic(struct ad6673_dev *dev, int32_t invert)
Inverts the logic of JESD204B bits.
Definition: ad6673.c:1131
int32_t ad6673_offset_adj(struct ad6673_dev *dev, int32_t adj)
Sets the offset adjustment.
Definition: ad6673.c:515
#define AD6673_TRANSF_LEN(x)
Definition: ad6673.h:57
#define AD6673_TEST_OUTPUT_TEST(x)
Definition: ad6673.h:153
struct ad6673_fast_detect_cfg * p_fd
Definition: ad6673.h:494
#define AD6673_FAST_DETECT_OUTPUT_ENABLE
Definition: ad6673.h:200
#define AD6673_REG_204B_LID_CFG2
Definition: ad6673.h:102
@ AD6673_SHD_REG_FD_LOWER_THD
Definition: ad6673.h:512
int8_t align_sync_in_b
Definition: ad6673.h:428
#define AD6673_204B_CTRL1_TAIL_BITS
Definition: ad6673.h:206
Structure holding SPI descriptor.
Definition: no_os_spi.h:192
Header file of AD6673 Driver.
#define AD6673_VREF_FS_ADJUST(x)
Definition: ad6673.h:172
#define AD6673_CH_INDEX_ADC_A
Definition: ad6673.h:125
int8_t invert_logic_bits
Definition: ad6673.h:404
#define AD6673_REG_DCC_CTRL
Definition: ad6673.h:89
int8_t scrambling
Definition: ad6673.h:386
#define AD6673_204B_PARAM_SCR_L_SCRAMBLING
Definition: ad6673.h:219
int16_t fd_upper_tresh
Definition: ad6673.h:478
#define AD6673_NSR_CTRL_BW_MODE
Definition: ad6673.h:185
@ AD6673_SHD_REG_BIST
Definition: ad6673.h:501
int32_t ad6673_transfer(struct ad6673_dev *dev)
Initiates a transfer and waits for the operation to end. Note: This function may be called after a sh...
Definition: ad6673.c:288
int32_t ad6673_output_disable(struct ad6673_dev *dev, int32_t en)
Disables (1) or enables (0) the data output. Note: This function modifies a shadowed register,...
Definition: ad6673.c:545
#define AD6673_SYS_CTRL_SYNCINB_EN
Definition: ad6673.h:182
int32_t ad6673_soft_reset(struct ad6673_dev *dev)
Resets all registers to their default values.
Definition: ad6673.c:320
#define AD6673_REG_DEVICE_UPDATE
Definition: ad6673.h:67
#define AD6673_REG_204B_LANE_ASSGN1
Definition: ad6673.h:115
int32_t ad6673_remove(struct ad6673_dev *dev)
Free the resources allocated by ad6673_setup().
Definition: ad6673.c:188
int32_t ad6673_bist_reset(struct ad6673_dev *dev, int32_t reset)
Resets the Build-In-Self-Test.
Definition: ad6673.c:763
@ AD6673_SHD_REG_TEST
Definition: ad6673.h:500
#define AD6673_PDWN_CHIP(x)
Definition: ad6673.h:135
#define AD6673_FAST_DETECT_PIN_FCT
Definition: ad6673.h:197
int8_t sys_ref_mode
Definition: ad6673.h:422
#define AD6673_REG_SYS_CTRL
Definition: ad6673.h:86
int32_t f0
Definition: ad6673.h:486
#define AD6673_REG_FD_UPPER_THD
Definition: ad6673.h:92
@ AD6673_SHD_REG_DCC_CTRL
Definition: ad6673.h:508
int32_t ad6673_bist_reset(struct ad6673_dev *dev, int32_t reset)
Resets the Build-In-Self-Test.
Definition: ad6673.c:763
void * no_os_malloc(size_t size)
Allocate memory and return a pointer to it.
Definition: chibios_alloc.c:43
int8_t en_sys_ref
Definition: ad6673.h:410
int32_t ad6673_set_user_pattern(struct ad6673_dev *dev, int32_t pattern_no, int32_t user_pattern)
Configures a User Test Pattern.
Definition: ad6673.c:711
int32_t ad6673_jesd204b_pwr_mode(struct ad6673_dev *dev, int32_t mode)
Configures the power mode of the JESD204B data transmit block.
Definition: ad6673.c:1024
#define AD6673_204B_CTRL3_JESD_TEST_MODE(x)
Definition: ad6673.h:216
int8_t en_ilas_test
Definition: ad6673.h:398
#define AD6673_CLOCK_DIV_RATIO(x)
Definition: ad6673.h:147
#define AD6673_SYS_CTRL_SYSREF_MODE
Definition: ad6673.h:180
int32_t ad6673_nsr_bandwidth_mode(struct ad6673_dev *dev, int32_t mode)
Selects the NSR Bandwidth mode.
Definition: ad6673.c:1337
int8_t k
Definition: ad6673.h:380
int8_t pin_force_value
Definition: ad6673.h:476
#define AD6673_REG_204B_DID_CFG
Definition: ad6673.h:99
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
#define AD6673_ADDR(x)
Definition: ad6673.h:52
int32_t ad6673_chip_pwr_mode(struct ad6673_dev *dev, int32_t mode)
Configures the power mode of the chip.
Definition: ad6673.c:412
#define AD6673_SYS_CTRL_REALIGN_ON_SYNCINB
Definition: ad6673.h:178
#define AD6673_CH_INDEX_ADC_B
Definition: ad6673.h:126
#define AD6673_OUT_MODE_JTX_BIT_ASSIGN(x)
Definition: ad6673.h:163
int32_t ad6673_jesd204b_select_test_injection_point(struct ad6673_dev *dev, int32_t inj_point)
Selects the point in the processing path of a lane, where the test data will be inserted.
Definition: ad6673.c:1058
int32_t ad6673_transfer(struct ad6673_dev *dev)
Initiates a transfer and waits for the operation to end. Note: This function may be called after a sh...
Definition: ad6673.c:288
#define AD6673_PDWN_JTX
Definition: ad6673.h:133
#define AD6673_REG_OFFSET_ADJUST(x)
Definition: ad6673.h:160
int32_t ad6673_dcc_freeze(struct ad6673_dev *dev, int32_t freeze)
Freezes DC correction value.
Definition: ad6673.c:1273
int32_t ad6673_nsr_enable(struct ad6673_dev *dev, int32_t enable)
Enables the Noise shaped requantizer(NRS).
Definition: ad6673.c:1305
#define AD6673_REG_SPI_CFG
Definition: ad6673.h:61
#define AD6673_REG_TEST
Definition: ad6673.h:74
struct ad7616_init_param init_param
Definition: ad7616_sdz.c:113
int32_t ad6673_nsr_tuning_freq(int64_t tune_freq, int64_t f_adc, struct ad6673_type_band *p_band)
Sets the NSR frequency range.
Definition: ad6673.c:1370
#define AD6673_204B_CTRL2_INVERT_JESD_BITS
Definition: ad6673.h:212
int8_t lid1
Definition: ad6673.h:375
int8_t en_sync_in_b
Definition: ad6673.h:416
int32_t ad6673_set_user_pattern(struct ad6673_dev *dev, int32_t pattern_no, int32_t user_pattern)
Configures a User Test Pattern.
Definition: ad6673.c:711
int32_t ad6673_jesd204b_pwr_mode(struct ad6673_dev *dev, int32_t mode)
Configures the power mode of the JESD204B data transmit block.
Definition: ad6673.c:1024
@ AD6673_SHD_REG_VREF
Definition: ad6673.h:504
JESD204B interface configuration.
Definition: ad6673.h:315
int8_t ctrl_bits_no
Definition: ad6673.h:351
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
#define AD6673_OUT_MODE_DISABLE
Definition: ad6673.h:164
int8_t cml_level
Definition: ad6673.h:330
struct ad6673_fast_detect_cfg ad6673_fast_detect
Definition: ad6673_cfg.h:81
int16_t df_dwell_time
Definition: ad6673.h:482
int32_t f_center
Definition: ad6673.h:487
int32_t ad6673_reset_pn23(struct ad6673_dev *dev, int32_t rst)
Sets (1) or clears (0) the reset long PN sequence bit(PN23).
Definition: ad6673.c:680
struct ad6673_jesd204b_cfg * p_jesd204b
Definition: ad6673.h:493
int32_t ad6673_setup(struct ad6673_dev **device, struct ad6673_init_param init_param)
Configures the device.
Definition: ad6673.c:88
int32_t ad6673_fast_detect_setup(struct ad6673_dev *dev)
Configures the Fast-Detect module.
Definition: ad6673.c:1160
@ AD6673_SHD_REG_FD_UPPER_THD
Definition: ad6673.h:511
#define AD6673_204B_LANE_ASSGN2(x)
Definition: ad6673.h:241
#define AD6673_204B_PARAM_NP_JESD_SUBCLASS(x)
Definition: ad6673.h:227
#define AD6673_REG_CLOCK
Definition: ad6673.h:71
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
Fast Detect module configuration.
Definition: ad6673.h:452
#define AD6673_REG_VREF
Definition: ad6673.h:79
int32_t ad6673_jesd204b_set_frames(struct ad6673_dev *dev, int32_t k_frames)
Sets number of frames per multiframe (K).
Definition: ad6673.c:795
#define AD6673_REG_204B_CTRL3
Definition: ad6673.h:98
#define AD6673_204B_LANE_ASSGN1(x)
Definition: ad6673.h:238
struct no_os_spi_desc * spi_desc
Definition: ad6673.h:519
#define AD6673_REG_204B_PARAM_CS_N
Definition: ad6673.h:107
#define AD6673_SPI_CFG_SOFT_RST
Definition: ad6673.h:122
int32_t ad6673_setup(struct ad6673_dev **device, struct ad6673_init_param init_param)
Configures the device.
Definition: ad6673.c:88
int32_t ad6673_test_mode(struct ad6673_dev *dev, int32_t mode)
Sets the ADC's test mode.
Definition: ad6673.c:485
#define AD6673_PDWN_JESD204B(x)
Definition: ad6673.h:134
int32_t ad6673_jesd204b_test_mode(struct ad6673_dev *dev, int32_t test_mode)
Selects a JESD204B test mode.
Definition: ad6673.c:1099
int32_t ad6673_offset_adj(struct ad6673_dev *dev, int32_t adj)
Sets the offset adjustment.
Definition: ad6673.c:515
#define AD6673_OUT_MODE_DATA_FORMAT(x)
Definition: ad6673.h:166
#define AD6673_DCC_CTRL_DCC_EN
Definition: ad6673.h:194
struct ad6673_platform_data ad6673_pdata_lpc
Definition: ad6673_cfg.h:44
#define AD6673_REG_204B_PARAM_NP
Definition: ad6673.h:108
int32_t shadow_regs[SHADOW_REGISTER_COUNT]
Definition: ad6673.h:522
int32_t f1
Definition: ad6673.h:488
#define AD6673_FAST_DETECT_FORCE_FDA_FDB_PIN
Definition: ad6673.h:198
#define AD6673_REG_OFFSET
Definition: ad6673.h:76
#define AD6673_REG_CML
Definition: ad6673.h:78
@ AD6673_SHD_REG_FAST_DETECT
Definition: ad6673.h:510
#define AD6673_TEST_RST_PN_LONG
Definition: ad6673.h:151
int32_t ad6673_dcc_freeze(struct ad6673_dev *dev, int32_t freeze)
Freezes DC correction value.
Definition: ad6673.c:1273
#define AD6673_REG_204B_LID_CFG1
Definition: ad6673.h:101
int8_t tail_bits_mode
Definition: ad6673.h:367
int8_t quick_cfg_option
Definition: ad6673.h:338
Structure holding the parameters for SPI initialization.
Definition: no_os_spi.h:140
int32_t ad6673_jesd204b_setup(struct ad6673_dev *dev)
Configures the JESD204B interface.
Definition: ad6673.c:832
int32_t ad6673_write(struct ad6673_dev *dev, int32_t register_address, int32_t register_value)
Writes a value to the selected register.
Definition: ad6673.c:244