Go to the documentation of this file.
53 #define DRIVER_MODE_AC_COUPLED_IF 0
54 #define DRIVER_MODE_DC_COUPLED_1V2 1
55 #define DRIVER_MODE_DC_COUPLED_1V8 2
56 #define DRIVER_MODE_IN_PULL_UP 3
59 #define DRIVER_MODE_AC_COUPLED 0
60 #define DRIVER_MODE_DC_COUPLED 1
61 #define DRIVER_MODE_DC_COUPLED_LVDS 2
64 #define DRIVER_MODE_SINGLE_DIV_DIF 0
65 #define DRIVER_MODE_SINGLE_DIV 1
66 #define DRIVER_MODE_DUAL_DIV 2
69 #define AD9545_CLK_OUT 0
70 #define AD9545_CLK_PLL 1
71 #define AD9545_CLK_NCO 2
72 #define AD9545_CLK_AUX_TDC 3
95 #define AD9545_CLK_AUX_TDC0 0
96 #define AD9545_CLK_AUX_TDC1 1
103 #define BYTE_ADDR_H NO_OS_GENMASK(14, 8)
104 #define BYTE_ADDR_L NO_OS_GENMASK(7, 0)
110 #define AD9545_CONFIG_0 0x0000
111 #define AD9545_PRODUCT_ID_LOW 0x0004
112 #define AD9545_PRODUCT_ID_HIGH 0x0005
113 #define AD9545_IO_UPDATE 0x000F
114 #define AD9545_M0_PIN 0x0102
115 #define AD9545_CHIP_ID 0x0121
116 #define AD9545_SYS_CLK_FB_DIV 0x0200
117 #define AD9545_SYS_CLK_INPUT 0x0201
118 #define AD9545_SYS_CLK_REF_FREQ 0x0202
119 #define AD9545_STABILITY_TIMER 0x0207
120 #define AD9545_COMPENSATE_TDCS 0x0280
121 #define AD9545_COMPENSATE_NCOS 0x0281
122 #define AD9545_COMPENSATE_DPLL 0x0282
123 #define AD9545_AUX_DPLL_CHANGE_LIMIT 0x0283
124 #define AD9545_AUX_DPLL_SOURCE 0x0284
125 #define AD9545_AUX_DPLL_LOOP_BW 0x0285
126 #define AD9545_REF_A_CTRL 0x0300
127 #define AD9545_REF_A_RDIV 0x0400
128 #define AD9545_REF_A_PERIOD 0x0404
129 #define AD9545_REF_A_OFFSET_LIMIT 0x040C
130 #define AD9545_REF_A_MONITOR_HYST 0x040F
131 #define AD9545_REF_A_VALID_TIMER 0x0410
132 #define AD9545_PHASE_LOCK_THRESH 0x0800
133 #define AD9545_PHASE_LOCK_FILL_RATE 0x0803
134 #define AD9545_PHASE_LOCK_DRAIN_RATE 0x0804
135 #define AD9545_FREQ_LOCK_THRESH 0x0805
136 #define AD9545_FREQ_LOCK_FILL_RATE 0x0808
137 #define AD9545_FREQ_LOCK_DRAIN_RATE 0x0809
138 #define AD9545_DPLL0_FTW 0x1000
139 #define AD9545_DPLL0_SLEW_RATE 0x1011
140 #define AD9545_MODULATION_COUNTER_A0 0x10C2
141 #define AD9545_MODULATION_COUNTER_B0 0x10C6
142 #define AD9545_MODULATION_COUNTER_C0 0x10CA
143 #define AD9545_MODULATOR_A0 0x10CF
144 #define AD9545_MODULATOR_B0 0x10D0
145 #define AD9545_MODULATOR_C0 0x10D1
146 #define AD9545_NSHOT_REQ_CH0 0x10D3
147 #define AD9545_NSHOT_EN_AB0 0x10D4
148 #define AD9545_NSHOT_EN_C0 0x10D5
149 #define AD9545_DRIVER_0A_CONF 0x10D7
150 #define AD9545_SYNC_CTRL0 0x10DB
151 #define AD9545_APLL0_M_DIV 0x1081
152 #define AD9545_Q0A_DIV 0x1100
153 #define AD9545_Q0A_PHASE 0x1104
154 #define AD9545_Q0A_PHASE_CONF 0x1108
155 #define AD9545_DPLL0_EN 0x1200
156 #define AD9545_DPLL0_SOURCE 0x1201
157 #define AD9545_DPLL0_ZERO_DELAY_FB 0x1202
158 #define AD9545_DPLL0_FB_MODE 0x1203
159 #define AD9545_DPLL0_LOOP_BW 0x1204
160 #define AD9545_DPLL0_HITLESS_N 0x1208
161 #define AD9545_DPLL0_N_DIV 0x120C
162 #define AD9545_DPLL0_FRAC 0x1210
163 #define AD9545_DPLL0_MOD 0x1213
164 #define AD9545_DPLL0_FAST_L1 0x1216
165 #define AD9545_DPLL0_FAST_L2 0x1217
166 #define AD9545_MODULATION_COUNTER_A1 0x14C2
167 #define AD9545_MODULATION_COUNTER_B1 0x14C6
168 #define AD9545_MODULATOR_A1 0x14CF
169 #define AD9545_MODULATOR_B1 0x14D0
170 #define AD9545_NSHOT_EN_AB1 0x14D4
171 #define AD9545_DRIVER_1A_CONF 0x14D7
172 #define AD9545_Q1A_DIV 0x1500
173 #define AD9545_Q1A_PHASE 0x1504
174 #define AD9545_Q1A_PHASE_CONF 0x1508
175 #define AD9545_CALIB_CLK 0x2000
176 #define AD9545_POWER_DOWN_REF 0x2001
177 #define AD9545_PWR_CALIB_CH0 0x2100
178 #define AD9545_CTRL_CH0 0x2101
179 #define AD9545_DIV_OPS_Q0A 0x2102
180 #define AD9545_DPLL0_MODE 0x2105
181 #define AD9545_DPLL0_FAST_MODE 0x2106
182 #define AD9545_DIV_OPS_Q1A 0x2202
183 #define AD9545_NCO0_CENTER_FREQ 0x2800
184 #define AD9545_NCO0_OFFSET_FREQ 0x2807
185 #define AD9545_NCO0_TAG_RATIO 0x280B
186 #define AD9545_NCO0_TAG_DELTA 0x280D
187 #define AD9545_NCO0_TYPE_ADJUST 0x280F
188 #define AD9545_NCO0_DELTA_RATE_LIMIT 0x2810
189 #define AD9545_NCO0_DELTA_ADJUST 0x2814
190 #define AD9545_NCO0_CYCLE_ADJUST 0x2819
191 #define AD9545_TDC0_DIV 0x2A00
192 #define AD9545_TDC0_PERIOD 0x2A01
193 #define AD9545_PLL_STATUS 0x3001
194 #define AD9545_MISC 0x3002
195 #define AD9545_TEMP0 0x3003
196 #define AD9545_REFA_STATUS 0x3005
197 #define AD9545_PLL0_STATUS 0x3100
198 #define AD9545_PLL0_OPERATION 0x3101
200 #define AD9545_SYS_CLK_STABILITY_PERIOD_MASK NO_OS_GENMASK(19, 0)
202 #define AD9545_REF_CTRL_DIF_MSK NO_OS_GENMASK(3, 2)
203 #define AD9545_REF_CTRL_REFA_MSK NO_OS_GENMASK(5, 4)
204 #define AD9545_REF_CTRL_REFAA_MSK NO_OS_GENMASK(7, 6)
206 #define AD9545_UPDATE_REGS 0x1
207 #define AD9545_RESET_REGS 0x81
209 #define AD9545_MX_PIN(x) (AD9545_M0_PIN + (x))
211 #define AD9545_SYNC_CTRLX(x) (AD9545_SYNC_CTRL0 + ((x) * 0x400))
212 #define AD9545_REF_X_RDIV(x) (AD9545_REF_A_RDIV + ((x) * 0x20))
213 #define AD9545_REF_X_PERIOD(x) (AD9545_REF_A_PERIOD + ((x) * 0x20))
214 #define AD9545_REF_X_OFFSET_LIMIT(x) (AD9545_REF_A_OFFSET_LIMIT + ((x) * 0x20))
215 #define AD9545_REF_X_MONITOR_HYST(x) (AD9545_REF_A_MONITOR_HYST + ((x) * 0x20))
216 #define AD9545_REF_X_VALID_TIMER(x) (AD9545_REF_A_VALID_TIMER + ((x) * 0x20))
217 #define AD9545_REF_X_PHASE_LOCK_FILL(x) (AD9545_PHASE_LOCK_FILL_RATE + ((x) * 0x20))
218 #define AD9545_REF_X_PHASE_LOCK_DRAIN(x) (AD9545_PHASE_LOCK_DRAIN_RATE + ((x) * 0x20))
219 #define AD9545_REF_X_FREQ_LOCK_FILL(x) (AD9545_FREQ_LOCK_FILL_RATE + ((x) * 0x20))
220 #define AD9545_REF_X_FREQ_LOCK_DRAIN(x) (AD9545_FREQ_LOCK_DRAIN_RATE + ((x) * 0x20))
222 #define AD9545_SOURCEX_PHASE_THRESH(x) (AD9545_PHASE_LOCK_THRESH + ((x) * 0x20))
223 #define AD9545_SOURCEX_FREQ_THRESH(x) (AD9545_FREQ_LOCK_THRESH + ((x) * 0x20))
224 #define AD9545_NCOX_PHASE_THRESH(x) (AD9545_SOURCEX_PHASE_THRESH((x) + 4))
225 #define AD9545_NCOX_FREQ_THRESH(x) (AD9545_SOURCEX_FREQ_THRESH((x) + 4))
227 #define AD9545_APLLX_M_DIV(x) (AD9545_APLL0_M_DIV + ((x) * 0x400))
229 #define AD9545_Q0_DIV(x) (AD9545_Q0A_DIV + ((x) * 0x9))
230 #define AD9545_Q1_DIV(x) (AD9545_Q1A_DIV + ((x) * 0x9))
231 #define AD9545_QX_DIV(x) ({ \
232 typeof(x) x_ = (x); \
234 (x_ > 5) ? AD9545_Q1_DIV(x_ - 6) : AD9545_Q0_DIV(x_); \
237 #define AD9545_Q0_PHASE(x) (AD9545_Q0A_PHASE + ((x) * 0x9))
238 #define AD9545_Q1_PHASE(x) (AD9545_Q1A_PHASE + ((x) * 0x9))
239 #define AD9545_QX_PHASE(x) ({ \
240 typeof(x) x_ = (x); \
242 (x_ > 5) ? AD9545_Q1_PHASE(x_ - 6) : AD9545_Q0_PHASE(x_); \
245 #define AD9545_Q0_PHASE_CONF(x) (AD9545_Q0A_PHASE_CONF + ((x) * 0x9))
246 #define AD9545_Q1_PHASE_CONF(x) (AD9545_Q1A_PHASE_CONF + ((x) * 0x9))
247 #define AD9545_QX_PHASE_CONF(x) ({ \
248 typeof(x) x_ = (x); \
250 (x_ > 5) ? AD9545_Q1_PHASE_CONF(x_ - 6) : AD9545_Q0_PHASE_CONF(x_); \
253 #define AD9545_NSHOT_REQ_CH(x) (AD9545_NSHOT_REQ_CH0 + ((x) * 0x400))
254 #define AD9545_DPLLX_FTW(x) (AD9545_DPLL0_FTW + ((x) * 0x400))
255 #define AD9545_DPLLX_SLEW_RATE(x) (AD9545_DPLL0_SLEW_RATE + ((x) * 0x400))
256 #define AD9545_DPLLX_EN(x, y) (AD9545_DPLL0_EN + ((x) * 0x400) + ((y) * 0x20))
257 #define AD9545_DPLLX_SOURCE(x, y) (AD9545_DPLL0_SOURCE + ((x) * 0x400) + ((y) * 0x20))
258 #define AD9545_DPLLX_FB_PATH(x, y) (AD9545_DPLL0_ZERO_DELAY_FB + ((x) * 0x400) + ((y) * 0x20))
259 #define AD9545_DPLLX_FB_MODE(x, y) (AD9545_DPLL0_FB_MODE + ((x) * 0x400) + ((y) * 0x20))
260 #define AD9545_DPLLX_LOOP_BW(x, y) (AD9545_DPLL0_LOOP_BW + ((x) * 0x400) + ((y) * 0x20))
261 #define AD9545_DPLLX_HITLESS_N(x, y) (AD9545_DPLL0_HITLESS_N + ((x) * 0x400) + ((y) * 0x20))
262 #define AD9545_DPLLX_N_DIV(x, y) (AD9545_DPLL0_N_DIV + ((x) * 0x400) + ((y) * 0x20))
263 #define AD9545_DPLLX_FRAC_DIV(x, y) (AD9545_DPLL0_FRAC + ((x) * 0x400) + ((y) * 0x20))
264 #define AD9545_DPLLX_MOD_DIV(x, y) (AD9545_DPLL0_MOD + ((x) * 0x400) + ((y) * 0x20))
265 #define AD9545_DPLLX_FAST_L1(x, y) (AD9545_DPLL0_FAST_L1 + ((x) * 0x400) + ((y) * 0x20))
266 #define AD9545_DPLLX_FAST_L2(x, y) (AD9545_DPLL0_FAST_L2 + ((x) * 0x400) + ((y) * 0x20))
268 #define AD9545_DIV_OPS_Q0(x) (AD9545_DIV_OPS_Q0A + (x))
269 #define AD9545_DIV_OPS_Q1(x) (AD9545_DIV_OPS_Q1A + (x))
270 #define AD9545_DIV_OPS_QX(x) ({ \
271 typeof(x) x_ = (x) / 2; \
273 (x_ > 2) ? AD9545_DIV_OPS_Q1(x_ - 3) : AD9545_DIV_OPS_Q0(x_); \
276 #define AD9545_PWR_CALIB_CHX(x) (AD9545_PWR_CALIB_CH0 + ((x) * 0x100))
277 #define AD9545_PLLX_STATUS(x) (AD9545_PLL0_STATUS + ((x) * 0x100))
278 #define AD9545_PLLX_OPERATION(x) (AD9545_PLL0_OPERATION + ((x) * 0x100))
279 #define AD9545_CTRL_CH(x) (AD9545_CTRL_CH0 + ((x) * 0x100))
280 #define AD9545_DPLLX_FAST_MODE(x) (AD9545_DPLL0_FAST_MODE + ((x) * 0x100))
281 #define AD9545_REFX_STATUS(x) (AD9545_REFA_STATUS + (x))
283 #define AD9545_PROFILE_SEL_MODE_MSK NO_OS_GENMASK(3, 2)
284 #define AD9545_PROFILE_SEL_MODE(x) no_os_field_prep(AD9545_PROFILE_SEL_MODE_MSK, x)
286 #define AD9545_NCOX_CENTER_FREQ(x) (AD9545_NCO0_CENTER_FREQ + ((x) * 0x40))
287 #define AD9545_NCOX_OFFSET_FREQ(x) (AD9545_NCO0_OFFSET_FREQ + ((x) * 0x40))
288 #define AD9545_NCOX_TAG_RATIO(x) (AD9545_NCO0_TAG_RATIO + ((x) * 0x40))
289 #define AD9545_NCOX_TAG_DELTA(x) (AD9545_NCO0_TAG_DELTA + ((x) * 0x40))
290 #define AD9545_NCOX_TYPE_ADJUST(x) (AD9545_NCO0_TYPE_ADJUST + ((x) * 0x40))
291 #define AD9545_NCOX_DELTA_RATE_LIMIT(x) (AD9545_NCO0_DELTA_RATE_LIMIT + ((x) * 0x40))
292 #define AD9545_NCOX_DELTA_ADJUST(x) (AD9545_NCO0_DELTA_ADJUST + ((x) * 0x40))
293 #define AD9545_NCOX_CYCLE_ADJUST(x) (AD9545_NCO0_CYCLE_ADJUST + ((x) * 0x40))
299 #define AD9545_NCO_CENTER_FREQ_INT_WIDTH 16
300 #define AD9545_NCO_CENTER_FREQ_FRAC_WIDTH 40
301 #define AD9545_NCO_CENTER_FREQ_WIDTH (AD9545_NCO_CENTER_FREQ_INT_WIDTH + \
302 AD9545_NCO_CENTER_FREQ_FRAC_WIDTH)
304 #define AD9545_NCO_CENTER_FREQ_MSK NO_OS_GENMASK_ULL(AD9545_NCO_CENTER_FREQ_WIDTH - 1, 0)
305 #define AD9545_NCO_CENTER_FREQ_INT_MSK NO_OS_GENMASK_ULL(AD9545_NCO_CENTER_FREQ_WIDTH - 1, \
306 AD9545_NCO_CENTER_FREQ_FRAC_WIDTH)
307 #define AD9545_NCO_CENTER_FREQ_FRAC_MSK NO_OS_GENMASK_ULL(AD9545_NCO_CENTER_FREQ_FRAC_WIDTH - 1, 0)
309 #define AD9545_NCO_CENTER_FREQ_MAX no_os_field_max_u64(AD9545_NCO_CENTER_FREQ_MSK)
310 #define AD9545_NCO_CENTER_FREQ_INT_MAX no_os_field_max_u64(AD9545_NCO_CENTER_FREQ_INT_MSK)
311 #define AD9545_NCO_CENTER_FREQ_FRAC_MAX no_os_field_max_u64(AD9545_NCO_CENTER_FREQ_FRAC_MSK)
317 #define AD9545_NCO_OFFSET_FREQ_INT_WIDTH 8
318 #define AD9545_NCO_OFFSET_FREQ_FRAC_WIDTH 24
319 #define AD9545_NCO_OFFSET_FREQ_WIDTH (AD9545_NCO_OFFSET_FREQ_INT_WIDTH + \
320 AD9545_NCO_OFFSET_FREQ_FRAC_WIDTH)
322 #define AD9545_NCO_OFFSET_FREQ_MSK NO_OS_GENMASK_ULL(AD9545_NCO_OFFSET_FREQ_WIDTH - 1, 0)
323 #define AD9545_NCO_OFFSET_FREQ_INT_MSK NO_OS_GENMASK_ULL(AD9545_NCO_OFFSET_FREQ_WIDTH - 1, \
324 AD9545_NCO_OFFSET_FREQ_FRAC_WIDTH)
325 #define AD9545_NCO_OFFSET_FREQ_FRAC_MSK NO_OS_GENMASK_ULL(AD9545_NCO_OFFSET_FREQ_FRAC_WIDTH - 1, 0)
327 #define AD9545_NCO_OFFSET_FREQ_MAX no_os_field_max(AD9545_NCO_OFFSET_FREQ_MSK)
328 #define AD9545_NCO_OFFSET_FREQ_INT_MAX no_os_field_max(AD9545_NCO_OFFSET_FREQ_INT_MSK)
329 #define AD9545_NCO_OFFSET_FREQ_FRAC_MAX no_os_field_max(AD9545_NCO_OFFSET_FREQ_FRAC_MSK)
331 #define AD9545_NCO_FREQ_INT_MAX (AD9545_NCO_CENTER_FREQ_INT_MAX + \
332 AD9545_NCO_OFFSET_FREQ_INT_MAX)
334 #define AD9545_TDCX_DIV(x) (AD9545_TDC0_DIV + ((x) * 0x9))
335 #define AD9545_TDCX_PERIOD(x) (AD9545_TDC0_PERIOD + ((x) * 0x9))
338 #define AD9545_MX_TO_TDCX(x) (0x30 + (x))
341 #define AD9545_COMPENSATE_TDCS_VIA_AUX_DPLL 0x4
344 #define AD9545_COMPENSATE_NCOS_VIA_AUX_DPLL 0x44
347 #define AD9545_COMPNESATE_VIA_AUX_DPLL 0x44
350 #define AD9545_EN_PROFILE_MSK NO_OS_BIT(0)
351 #define AD9545_SEL_PRIORITY_MSK NO_OS_GENMASK(5, 1)
354 #define AD9545_EN_HITLESS_MSK NO_OS_BIT(0)
355 #define AD9545_TAG_MODE_MSK NO_OS_GENMASK(4, 2)
356 #define AD9545_BASE_FILTER_MSK NO_OS_BIT(7)
359 #define AD9545_PWR_DOWN_CH NO_OS_BIT(0)
360 #define AD9545_CALIB_APLL NO_OS_BIT(1)
363 #define AD9545_SYNC_CTRL_DPLL_REF_MSK NO_OS_BIT(2)
364 #define AD9545_SYNC_CTRL_MODE_MSK NO_OS_GENMASK(1, 0)
367 #define AD9545_QX_HALF_DIV_MSK NO_OS_BIT(5)
368 #define AD9545_QX_PHASE_32_MSK NO_OS_BIT(6)
371 #define AD9545_DIV_OPS_MUTE_A_MSK NO_OS_BIT(2)
372 #define AD9545_DIV_OPS_MUTE_AA_MSK NO_OS_BIT(3)
375 #define AD9545_MODULATOR_EN NO_OS_BIT(0)
378 #define AD9545_NSHOT_NR_MSK NO_OS_GENMASK(5, 0)
381 #define AD9545_CTRL_CH_NSHOT_MSK NO_OS_BIT(0)
384 #define AD9545_PLLX_LOCK(x, y) ((1 << (4 + (x))) & (y))
387 #define AD9545_MISC_AUX_NC0_ERR_MSK NO_OS_GENMASK(5, 4)
388 #define AD9545_MISC_AUX_NC1_ERR_MSK NO_OS_GENMASK(7, 6)
389 #define AD9545_AUX_DPLL_LOCK_MSK NO_OS_BIT(1)
390 #define AD9545_AUX_DPLL_REF_FAULT NO_OS_BIT(2)
393 #define AD9545_REFX_SLOW_MSK NO_OS_BIT(0)
394 #define AD9545_REFX_FAST_MSK NO_OS_BIT(1)
395 #define AD9545_REFX_JITTER_MSK NO_OS_BIT(2)
396 #define AD9545_REFX_FAULT_MSK NO_OS_BIT(3)
397 #define AD9545_REFX_VALID_MSK NO_OS_BIT(4)
398 #define AD9545_REFX_LOS_MSK NO_OS_BIT(5)
401 #define AD9545_PLL_LOCKED NO_OS_BIT(0)
404 #define AD9545_PLL_FREERUN NO_OS_BIT(0)
405 #define AD9545_PLL_HOLDOVER NO_OS_BIT(1)
406 #define AD9545_PLL_ACTIVE NO_OS_BIT(3)
407 #define AD9545_PLL_ACTIVE_PROFILE NO_OS_GENMASK(6, 4)
409 #define AD9545_SYS_PLL_STABLE_MSK NO_OS_GENMASK(1, 0)
410 #define AD9545_SYS_PLL_STABLE(x) (((x) & AD9545_SYS_PLL_STABLE_MSK) == 0x3)
412 #define AD9545_APLL_LOCKED(x) ((x) & NO_OS_BIT(3))
415 #define AD9545_NO_TAGGING 0
416 #define AD9545_FB_PATH_TAG 2
418 #define AD9545_SYS_CLK_STABILITY_MS 50
420 #define AD9545_R_DIV_MSK NO_OS_GENMASK(29, 0)
421 #define AD9545_R_DIV_MAX 0x40000000
422 #define AD9545_IN_MAX_TDC_FREQ_HZ 200000
424 #define AD9545_MAX_REFS 4
426 #define AD9545_APLL_M_DIV_MIN 1
427 #define AD9545_APLL_M_DIV_MAX 255
429 #define AD9545_DPLL_MAX_N 1073741823
430 #define AD9545_DPLL_MAX_FRAC 16777215
431 #define AD9545_DPLL_MAX_MOD 16777215
432 #define AD9545_MAX_DPLL_PROFILES 6
434 #define AD9545_MAX_NSHOT_PULSES 63
436 #define AD9545_MAX_ZERO_DELAY_RATE 200000000
438 #define AD9545_MIN_SYS_CLK_FREQ 2250
439 #define AD9545_MAX_SYS_CLK_FREQ 2415
440 #define AD9545_MIN_DIV_RATIO 4
441 #define AD9545_MAX_DIV_RATIO 256
448 static const unsigned int ad9545_apll_rate_ranges_hz[2][2] = {
449 {2424000000U, 3232000000U}, {3232000000U, 4040000000U}
452 static const unsigned int ad9545_apll_pfd_rate_ranges_hz[2] = {
453 162000000U, 350000000U
456 static const unsigned short ad9545_vco_calibration_op[][2] = {
463 static const uint8_t ad9545_tdc_source_mapping[] = {
467 static const uint32_t ad9545_fast_acq_excess_bw_map[] = {
468 0, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024,
471 static const uint32_t ad9545_fast_acq_timeout_map[] = {
472 1, 10, 50, 100, 500, 1000, 10000, 50000,
475 static const uint32_t ad9545_hyst_scales_bp[] = {
476 0, 3125, 6250, 12500, 25000, 50000, 75000, 87500
479 static const uint32_t ad9545_out_source_ua[] = {
483 static const uint32_t ad9545_rate_change_limit_map[] = {
484 715, 1430, 2860, 5720, 11440, 22880, 45760,
487 static const char *
const ad9545_ref_m_clk_names[] = {
488 "Ref-M0",
"Ref-M1",
"Ref-M2",
491 static const char *
const ad9545_ref_clk_names[] = {
492 "Ref-A",
"Ref-AA",
"Ref-B",
"Ref-BB",
495 static const char *
const ad9545_in_clk_names[] = {
496 "Ref-A-Div",
"Ref-AA-Div",
"Ref-B-Div",
"Ref-BB-Div",
499 static const char *
const ad9545_out_clk_names[] = {
500 "Q0A-div",
"Q0AA-div",
"Q0B-div",
"Q0BB-div",
"Q0C-div",
"Q0CC-div",
"Q1A-div",
"Q1AA-div",
501 "Q1B-div",
"Q1BB-div",
504 static const char *
const ad9545_pll_clk_names[] = {
508 static const char *
const ad9545_aux_nco_clk_names[] = {
509 "AUX_NCO0",
"AUX_NCO1",
512 static const char *
const ad9545_aux_tdc_clk_names[] = {
513 "AUX_TDC0",
"AUX_TDC1",
745 ad9545_aux_nco_clk_names)];
747 ad9545_aux_tdc_clk_names)];
766 ad9545_aux_nco_clk_names)];
768 ad9545_aux_tdc_clk_names)];
#define AD9545_DPLLX_FB_PATH(x, y)
Definition: ad9545.h:258
enum ad9545_ref_mode mode
Definition: ad9545.h:662
bool pll_used
Definition: ad9545.h:637
#define AD9545_NCOX_FREQ_THRESH(x)
Definition: ad9545.h:225
#define AD9545_MODULATOR_C0
Definition: ad9545.h:145
#define AD9545_DPLLX_HITLESS_N(x, y)
Definition: ad9545.h:261
int32_t ad9545_write_reg_multiple(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t *reg_data, uint16_t count)
Definition: ad9545.c:107
#define AD9545_CLK_PLL
Definition: ad9545.h:70
unsigned int address
Definition: ad9545.h:679
bool tdc_used
Definition: ad9545.h:686
#define AD9545_MISC_AUX_NC0_ERR_MSK
Definition: ad9545.h:387
#define AD9545_EN_PROFILE_MSK
Definition: ad9545.h:350
bool sys_clk_crystal
Definition: ad9545.h:705
@ AD9545_SINGLE_DIV_DIF
Definition: ad9545.h:535
#define AD9545_DIV_OPS_MUTE_A_MSK
Definition: ad9545.h:371
#define AD9545_MAX_DPLL_PROFILES
Definition: ad9545.h:432
unsigned int phase_thresh_ps
Definition: ad9545.h:664
@ AD9545_DC_COUPLED_LVDS
Definition: ad9545.h:531
#define AD9545_DPLLX_FRAC_DIV(x, y)
Definition: ad9545.h:263
struct no_os_clk_desc * hw
Definition: ad9545.h:653
int32_t ad9545_read_reg(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t *reg_data)
Definition: ad9545.c:62
int32_t no_os_i2c_init(struct no_os_i2c_desc **desc, const struct no_os_i2c_init_param *param)
Initialize the I2C communication peripheral.
Definition: no_os_i2c.c:52
#define AD9545_IN_MAX_TDC_FREQ_HZ
Definition: ad9545.h:422
struct ad9545_dev * dev
Definition: ad9545.h:654
uint64_t no_os_field_prep_u64(uint64_t mask, uint64_t val)
unsigned int loop_bw_mhz
Definition: ad9545.h:698
struct no_os_clk_desc * hw
Definition: ad9545.h:685
struct no_os_clk_desc * hw
Definition: ad9545.h:639
int32_t ad9545_write_mask(struct ad9545_dev *dev, uint16_t reg_addr, uint32_t mask, uint8_t data)
Definition: ad9545.c:123
#define NO_OS_GENMASK(h, l)
Definition: no_os_util.h:82
uint32_t valid_t_ms
Definition: ad9545.h:659
#define AD9545_NSHOT_NR_MSK
Definition: ad9545.h:378
#define AD9545_DPLLX_EN(x, y)
Definition: ad9545.h:256
const struct no_os_clk_platform_ops * platform_ops
Definition: no_os_clk.h:50
#define AD9545_MODULATOR_B0
Definition: ad9545.h:144
@ SPI
Definition: ad9545.h:444
#define NO_OS_BIT_ULL(x)
Definition: no_os_util.h:47
Header file of SPI Interface.
@ AD9545_DC_COUPLED_1V8
Definition: ad9545.h:524
#define AD9545_REF_X_PHASE_LOCK_DRAIN(x)
Definition: ad9545.h:218
#define AD9545_DPLLX_MOD_DIV(x, y)
Definition: ad9545.h:264
struct no_os_i2c_desc * i2c_desc
Definition: ad9545.h:731
int32_t no_os_i2c_remove(struct no_os_i2c_desc *desc)
Free the resources allocated by no_os_i2c_init().
Definition: no_os_i2c.c:113
#define AD9545_REF_X_MONITOR_HYST(x)
Definition: ad9545.h:215
#define AD9545_NCOX_PHASE_THRESH(x)
Definition: ad9545.h:224
uint64_t no_os_mul_u64_u32_shr(uint64_t a, uint32_t mul, unsigned int shift)
unsigned int priority
Definition: ad9545.h:625
struct ad9545_dev * dev
Definition: ad9545.h:687
enum ad9545_output_mode output_mode
Definition: ad9545.h:614
#define pr_err(fmt, args...)
Definition: no_os_print_log.h:88
#define AD9545_SYS_CLK_STABILITY_PERIOD_MASK
Definition: ad9545.h:200
struct ad9545_aux_dpll_clk aux_dpll_clk
Definition: ad9545.h:761
void no_os_rational_best_approximation_u64(uint64_t given_numerator, uint64_t given_denominator, uint64_t max_numerator, uint64_t max_denominator, uint64_t *best_numerator, uint64_t *best_denominator)
#define AD9545_AUX_DPLL_LOOP_BW
Definition: ad9545.h:125
#define AD9545_QX_DIV(x)
Definition: ad9545.h:231
#define AD9545_NCO_OFFSET_FREQ_INT_MSK
Definition: ad9545.h:323
Header file of Delay functions.
#define AD9545_DPLL_MAX_N
Definition: ad9545.h:429
struct ad9545_aux_nco_clk aux_nco_clks[NO_OS_ARRAY_SIZE(ad9545_aux_nco_clk_names)]
Definition: ad9545.h:765
#define AD9545_MX_PIN(x)
Definition: ad9545.h:209
#define AD9545_SYS_CLK_STABILITY_MS
Definition: ad9545.h:418
#define AD9545_PLLX_LOCK(x, y)
Definition: ad9545.h:384
const char * name
Definition: no_os_clk.h:46
#define AD9545_SEL_PRIORITY_MSK
Definition: ad9545.h:351
int ad9545_calib_aplls(struct ad9545_dev *dev)
Definition: ad9545.c:2045
#define NO_OS_DIV_ROUND_CLOSEST_ULL(x, y)
Definition: no_os_util.h:56
int32_t no_os_clk_init(struct no_os_clk_desc **desc, const struct no_os_clk_init_param *param)
@ AD9545_DUAL_DIV
Definition: ad9545.h:537
uint64_t internal_zero_delay_source_rate_hz
Definition: ad9545.h:648
#define AD9545_DPLLX_SOURCE(x, y)
Definition: ad9545.h:257
#define AD9545_APLL_M_DIV_MIN
Definition: ad9545.h:426
#define AD9545_MAX_DIV_RATIO
Definition: ad9545.h:441
unsigned int fast_acq_excess_bw
Definition: ad9545.h:627
unsigned int free_run_freq
Definition: ad9545.h:643
#define AD9545_CONFIG_0
Definition: ad9545.h:110
Definition: ad9361_util.h:69
#define AD9545_NCOX_CENTER_FREQ(x)
Definition: ad9545.h:286
struct no_os_clk_desc ** clks[4]
Definition: ad9545.h:749
#define AD9545_PLL_STATUS
Definition: ad9545.h:193
int32_t(* ad9545_reg_read_func)(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t *reg_data)
Definition: ad9545.h:712
#define AD9545_NCO_CENTER_FREQ_INT_MAX
Definition: ad9545.h:310
bool dpll_used
Definition: ad9545.h:695
struct ad9545_out_clk out_clks[NO_OS_ARRAY_SIZE(ad9545_out_clk_names)]
Definition: ad9545.h:743
#define AD9545_AUX_DPLL_REF_FAULT
Definition: ad9545.h:390
enum ad9545_comm_type comm_type
Definition: ad9545.h:738
#define AD9545_TDCX_DIV(x)
Definition: ad9545.h:334
void * no_os_calloc(size_t nitems, size_t size)
Allocate memory and return a pointer to it, set memory to 0.
Definition: chibios_alloc.c:54
#define NO_OS_ARRAY_SIZE(x)
Definition: no_os_util.h:49
int32_t ad9545_remove(struct ad9545_dev *dev)
Free the memory allocated by ad9545_init().
Definition: ad9545.c:2405
uint64_t no_os_mul_u64_u32_div(uint64_t a, uint32_t mul, uint32_t divisor)
#define AD9545_SYNC_CTRL_DPLL_REF_MSK
Definition: ad9545.h:363
#define AD9545_EN_HITLESS_MSK
Definition: ad9545.h:354
#define AD9545_Q0CC
Definition: ad9545.h:84
#define AD9545_MODULATOR_A1
Definition: ad9545.h:168
enum ad7616_mode mode
Definition: ad7616.h:226
struct no_os_clk_desc * parent_clk
Definition: ad9545.h:660
enum ad9545_single_ended_config s_conf
Definition: ad9545.h:670
bool sys_clk_freq_doubler
Definition: ad9545.h:704
bool source_current
Definition: ad9545.h:613
#define AD9545_CALIB_APLL
Definition: ad9545.h:360
#define AD9545_COMPENSATE_DPLL
Definition: ad9545.h:122
uint8_t num_parents
Definition: ad9545.h:640
#define AD9545_MODULATION_COUNTER_A1
Definition: ad9545.h:166
#define AD9545_R_DIV_MAX
Definition: ad9545.h:421
uint8_t tdc_source
Definition: ad9545.h:631
#define AD9545_CALIB_CLK
Definition: ad9545.h:175
#define AD9545_NSHOT_EN_C0
Definition: ad9545.h:148
#define AD9545_REF_X_OFFSET_LIMIT(x)
Definition: ad9545.h:214
@ AD9545_IN_PULL_UP
Definition: ad9545.h:525
int32_t ad9545_setup(struct ad9545_dev *dev)
Definition: ad9545.c:2330
struct ad9545_dev * dev
Definition: ad9545.h:611
int ad9545_calib_aplls(struct ad9545_dev *dev)
Definition: ad9545.c:2045
Header file of Clock Driver.
struct no_os_clk_desc ** parents
Definition: ad9545.h:641
#define AD9545_COMPENSATE_NCOS_VIA_AUX_DPLL
Definition: ad9545.h:344
void no_os_mdelay(uint32_t msecs)
Wait until msecs milliseconds passed.
Definition: aducm3029_delay.c:126
#define AD9545_PWR_CALIB_CHX(x)
Definition: ad9545.h:276
uint32_t no_os_field_prep(uint32_t mask, uint32_t val)
#define no_os_min(x, y)
Definition: no_os_util.h:59
enum ad9545_diferential_config d_conf
Definition: ad9545.h:671
struct ad9545_sys_clk sys_clk
Definition: ad9545.h:739
@ AD9545_DC_COUPLED
Definition: ad9545.h:530
#define NO_OS_DIV_ROUND_UP(x, y)
Definition: no_os_util.h:52
#define AD9545_BASE_FILTER_MSK
Definition: ad9545.h:356
#define AD9545_APLL_M_DIV_MAX
Definition: ad9545.h:427
uint64_t rate_requested_hz
Definition: ad9545.h:618
struct ad9545_dev * dev
Definition: ad9545.h:636
uint16_t nshot_en_reg
Definition: ad9545.h:543
ad9545_ref_mode
Definition: ad9545.h:516
#define AD9545_DPLLX_FB_MODE(x, y)
Definition: ad9545.h:259
unsigned int address
Definition: ad9545.h:617
#define AD9545_SYNC_CTRL_MODE_MSK
Definition: ad9545.h:364
uint8_t nshot_en_msk
Definition: ad9545.h:544
#define AD9545_MAX_ZERO_DELAY_RATE
Definition: ad9545.h:436
unsigned int address
Definition: ad9545.h:623
#define AD9545_DPLLX_FTW(x)
Definition: ad9545.h:254
#define AD9545_REF_X_RDIV(x)
Definition: ad9545.h:212
ad9545_reg_write_multi_func reg_write_multiple
Definition: ad9545.h:736
#define AD9545_MIN_DIV_RATIO
Definition: ad9545.h:440
unsigned int fast_acq_settle_ms
Definition: ad9545.h:629
struct ad9545_aux_nco_clk aux_nco_clks[NO_OS_ARRAY_SIZE(ad9545_aux_nco_clk_names)]
Definition: ad9545.h:744
bool internal_zero_delay
Definition: ad9545.h:646
unsigned int fast_acq_trigger_mode
Definition: ad9545.h:644
#define AD9545_SOURCEX_FREQ_THRESH(x)
Definition: ad9545.h:223
unsigned int freq_lock_fill_rate
Definition: ad9545.h:667
uint32_t sys_freq_hz
Definition: ad9545.h:707
#define AD9545_NCO_FREQ_INT_MAX
Definition: ad9545.h:331
#define AD9545_REF_X_FREQ_LOCK_DRAIN(x)
Definition: ad9545.h:220
struct ad9545_pll_clk pll_clks[NO_OS_ARRAY_SIZE(ad9545_pll_clk_names)]
Definition: ad9545.h:741
#define NO_OS_DIV_U64(x, y)
Definition: no_os_util.h:115
#define AD9545_DPLL_MAX_FRAC
Definition: ad9545.h:430
#define AD9545_SYS_CLK_FB_DIV
Definition: ad9545.h:116
bool fb_tagging
Definition: ad9545.h:632
@ AD9545_AC_COUPLED_IF
Definition: ad9545.h:522
#define AD9545_AUX_DPLL_LOCK_MSK
Definition: ad9545.h:389
#define AD9545_PRODUCT_ID_LOW
Definition: ad9545.h:111
#define AD9545_COMPNESATE_VIA_AUX_DPLL
Definition: ad9545.h:347
#define AD9545_DPLLX_FAST_MODE(x)
Definition: ad9545.h:280
#define AD9545_APLL_LOCKED(x)
Definition: ad9545.h:412
unsigned int loop_bw_uhz
Definition: ad9545.h:626
ad9545_reg_read_func reg_read
Definition: ad9545.h:733
#define AD9545_TAG_MODE_MSK
Definition: ad9545.h:355
#define AD9545_MAX_REFS
Definition: ad9545.h:424
#define AD9545_IO_UPDATE
Definition: ad9545.h:113
#define AD9545_TDCX_PERIOD(x)
Definition: ad9545.h:335
uint8_t hw_ch_num
Definition: no_os_clk.h:79
#define AD9545_SYS_CLK_INPUT
Definition: ad9545.h:117
#define AD9545_REF_CTRL_DIF_MSK
Definition: ad9545.h:202
Header file for ad9545 Driver.
#define AD9545_MX_TO_TDCX(x)
Definition: ad9545.h:338
int32_t ad9545_remove(struct ad9545_dev *dev)
Free the memory allocated by ad9545_init().
Definition: ad9545.c:2405
struct no_os_spi_desc * spi_desc
Definition: ad9545.h:729
struct ad9545_dev * dev
Definition: ad9545.h:696
uint64_t no_os_mul_u32_u32(uint32_t a, uint32_t b)
unsigned int freq_lock_drain_rate
Definition: ad9545.h:668
Structure holding CLK descriptor.
Definition: no_os_clk.h:75
#define AD9545_REFX_VALID_MSK
Definition: ad9545.h:397
unsigned int address
Definition: ad9545.h:661
ad9545_diferential_config
Definition: ad9545.h:528
#define AD9545_DPLLX_FAST_L1(x, y)
Definition: ad9545.h:265
ad9545_reg_write_func reg_write
Definition: ad9545.h:734
unsigned int freq_thresh_ps
Definition: ad9545.h:680
#define AD9545_NCO_CENTER_FREQ_INT_MSK
Definition: ad9545.h:305
Structure holding SPI descriptor.
Definition: no_os_spi.h:192
unsigned int address
Definition: ad9545.h:688
struct no_os_clk_desc * parent_clk
Definition: ad9545.h:690
#define AD9545_DPLLX_SLEW_RATE(x)
Definition: ad9545.h:255
#define AD9545_UPDATE_REGS
Definition: ad9545.h:206
void * dev_desc
Definition: no_os_clk.h:52
#define AD9545_DPLLX_LOOP_BW(x, y)
Definition: ad9545.h:260
unsigned int phase_lock_fill_rate
Definition: ad9545.h:665
unsigned int source
Definition: ad9545.h:697
uint8_t internal_zero_delay_source
Definition: ad9545.h:647
uint64_t no_os_div_u64_rem(uint64_t dividend, uint32_t divisor, uint32_t *remainder)
int32_t ad9545_spi_reg_write(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t reg_data)
Definition: ad9545_spi.c:77
#define AD9545_DIV_OPS_MUTE_AA_MSK
Definition: ad9545.h:372
uint32_t r_div_ratio
Definition: ad9545.h:655
#define AD9545_SYNC_CTRLX(x)
Definition: ad9545.h:211
#define AD9545_DPLLX_N_DIV(x, y)
Definition: ad9545.h:262
Definition: no_os_clk.h:44
#define AD9545_MODULATOR_A0
Definition: ad9545.h:143
int32_t ad9545_i2c_reg_read_multiple(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t *reg_data, uint16_t count)
Definition: ad9545_i2c.c:99
#define AD9545_FB_PATH_TAG
Definition: ad9545.h:416
#define AD9545_MODULATION_COUNTER_A0
Definition: ad9545.h:140
int32_t ad9545_i2c_reg_write_multiple(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t *reg_data, uint16_t count)
Definition: ad9545_i2c.c:136
#define AD9545_SOURCEX_PHASE_THRESH(x)
Definition: ad9545.h:222
Structure holding I2C address descriptor.
Definition: no_os_i2c.h:101
#define AD9545_DPLL_MAX_MOD
Definition: ad9545.h:431
@ AD9545_AC_COUPLED
Definition: ad9545.h:529
void * no_os_malloc(size_t size)
Allocate memory and return a pointer to it.
Definition: chibios_alloc.c:43
ad9545_reg_read_multi_func reg_read_multiple
Definition: ad9545.h:735
#define AD9545_MISC_AUX_NC1_ERR_MSK
Definition: ad9545.h:388
#define AD9545_REF_X_FREQ_LOCK_FILL(x)
Definition: ad9545.h:219
#define no_os_clamp_t(type, val, min_val, max_val)
Definition: no_os_util.h:71
Header file of I2C Interface.
#define AD9545_DIV_OPS_QX(x)
Definition: ad9545.h:270
#define AD9545_NCOX_OFFSET_FREQ(x)
Definition: ad9545.h:287
#define AD9545_COMPENSATE_TDCS_VIA_AUX_DPLL
Definition: ad9545.h:341
#define AD9545_REF_X_PERIOD(x)
Definition: ad9545.h:213
@ AD9545_SINGLE_DIV
Definition: ad9545.h:536
struct ad9545_ref_in_clk ref_in_clks[NO_OS_ARRAY_SIZE(ad9545_ref_clk_names)]
Definition: ad9545.h:763
uint32_t no_os_field_get(uint32_t mask, uint32_t word)
uint32_t source_ua
Definition: ad9545.h:615
unsigned int address
Definition: ad9545.h:638
int32_t ad9545_spi_reg_read_multiple(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t *reg_data, uint16_t count)
Definition: ad9545_spi.c:98
struct no_os_spi_init_param * spi_init
Definition: ad9545.h:755
int32_t(* ad9545_reg_read_multi_func)(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t *reg_data, uint16_t count)
Definition: ad9545.h:718
unsigned int pin_nr
Definition: ad9545.h:689
#define AD9545_MIN_SYS_CLK_FREQ
Definition: ad9545.h:438
struct ad9545_out_clk out_clks[NO_OS_ARRAY_SIZE(ad9545_out_clk_names)]
Definition: ad9545.h:764
#define AD9545_NCO_CENTER_FREQ_MAX
Definition: ad9545.h:309
#define NO_OS_BIT(x)
Definition: no_os_util.h:45
uint16_t modulation_counter_reg
Definition: ad9545.h:542
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
bool en
Definition: ad9545.h:630
int32_t(* ad9545_reg_write_func)(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t reg_data)
Definition: ad9545.h:715
struct no_os_clk_desc * hw
Definition: ad9545.h:694
uint32_t ref_freq_hz
Definition: ad9545.h:706
#define AD9545_REFX_STATUS(x)
Definition: ad9545.h:281
#define AD9545_APLLX_M_DIV(x)
Definition: ad9545.h:227
struct no_os_clk_desc * hw
Definition: ad9545.h:616
struct no_os_clk_desc * parent_clk
Definition: ad9545.h:619
int32_t ad9545_read_reg_multiple(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t *reg_data, uint16_t count)
Definition: ad9545.c:91
ad9545_single_ended_config
Definition: ad9545.h:521
#define AD9545_AUX_DPLL_CHANGE_LIMIT
Definition: ad9545.h:123
#define AD9545_MODULATOR_EN
Definition: ad9545.h:375
Structure holding the parameters for I2C initialization.
Definition: no_os_i2c.h:64
bool nco_used
Definition: ad9545.h:677
#define AD9545_REF_X_VALID_TIMER(x)
Definition: ad9545.h:216
int32_t(* ad9545_reg_write_multi_func)(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t *reg_data, uint16_t count)
Definition: ad9545.h:722
ad9545_output_mode
Definition: ad9545.h:534
unsigned int phase_lock_drain_rate
Definition: ad9545.h:666
#define AD9545_DRIVER_1A_CONF
Definition: ad9545.h:171
struct ad7616_init_param init_param
Definition: ad7616_sdz.c:113
int32_t ad9545_init(struct ad9545_dev **device, struct ad9545_init_param *init_param)
Definition: ad9545.c:1535
uint32_t d_tol_ppb
Definition: ad9545.h:657
int32_t ad9545_spi_reg_read(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t *reg_data)
Definition: ad9545_spi.c:50
uint8_t monitor_hyst_scale
Definition: ad9545.h:658
@ AD9545_SINGLE_ENDED
Definition: ad9545.h:517
#define AD9545_AUX_DPLL_SOURCE
Definition: ad9545.h:124
struct ad9545_dev * dev
Definition: ad9545.h:678
unsigned int rate_change_limit
Definition: ad9545.h:699
#define AD9545_NCO_CENTER_FREQ_FRAC_WIDTH
Definition: ad9545.h:300
void * dev_desc
Definition: no_os_clk.h:83
#define AD9545_MODULATION_COUNTER_C0
Definition: ad9545.h:142
#define AD9545_RESET_REGS
Definition: ad9545.h:207
struct ad9545_sys_clk sys_clk
Definition: ad9545.h:760
struct ad9545_aux_tdc_clk aux_tdc_clks[NO_OS_ARRAY_SIZE(ad9545_aux_tdc_clk_names)]
Definition: ad9545.h:746
#define AD9545_NSHOT_EN_AB0
Definition: ad9545.h:147
uint8_t hw_ch_num
Definition: no_os_clk.h:48
#define AD9545_CLK_NCO
Definition: ad9545.h:71
struct ad9545_ref_in_clk ref_in_clks[NO_OS_ARRAY_SIZE(ad9545_ref_clk_names)]
Definition: ad9545.h:742
unsigned int phase_thresh_ps
Definition: ad9545.h:681
int32_t ad9545_init(struct ad9545_dev **device, struct ad9545_init_param *init_param)
Definition: ad9545.c:1535
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
struct ad9545_aux_dpll_clk aux_dpll_clk
Definition: ad9545.h:740
#define AD9545_COMPENSATE_NCOS
Definition: ad9545.h:121
#define AD9545_CTRL_CH_NSHOT_MSK
Definition: ad9545.h:381
#define AD9545_PRODUCT_ID_HIGH
Definition: ad9545.h:112
Header file of GPIO Interface.
struct no_os_clk_desc * hw
Definition: ad9545.h:676
int32_t ad9545_spi_reg_write_multiple(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t *reg_data, uint16_t count)
Definition: ad9545_spi.c:131
@ AD9545_DC_COUPLED_1V2
Definition: ad9545.h:523
#define AD9545_REF_X_PHASE_LOCK_FILL(x)
Definition: ad9545.h:217
#define AD9545_CHIP_ID
Definition: ad9545.h:115
#define AD9545_CLK_AUX_TDC
Definition: ad9545.h:72
#define AD9545_MAX_SYS_CLK_FREQ
Definition: ad9545.h:439
unsigned int freq_thresh_ps
Definition: ad9545.h:663
struct no_os_i2c_init_param * i2c_init
Definition: ad9545.h:757
unsigned int parent_index
Definition: ad9545.h:624
int32_t ad9545_i2c_reg_read(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t *reg_data)
Definition: ad9545_i2c.c:48
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
#define AD9545_MODULATOR_B1
Definition: ad9545.h:169
#define AD9545_SYS_CLK_REF_FREQ
Definition: ad9545.h:118
#define AD9545_PLLX_STATUS(x)
Definition: ad9545.h:277
int32_t ad9545_i2c_reg_write(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t reg_data)
Definition: ad9545_i2c.c:77
Header file of utility functions.
enum ad9545_comm_type comm_type
Definition: ad9545.h:759
@ SPI
Definition: adxl372.h:316
#define AD9545_REF_CTRL_REFAA_MSK
Definition: ad9545.h:204
#define AD9545_NSHOT_REQ_CH(x)
Definition: ad9545.h:253
uint64_t rate_requested_hz
Definition: ad9545.h:645
bool ref_used
Definition: ad9545.h:656
struct ad9545_aux_tdc_clk aux_tdc_clks[NO_OS_ARRAY_SIZE(ad9545_aux_tdc_clk_names)]
Definition: ad9545.h:767
#define AD9545_CTRL_CH(x)
Definition: ad9545.h:279
#define AD9545_CLK_OUT
Definition: ad9545.h:69
@ AD9545_DIFFERENTIAL
Definition: ad9545.h:518
bool output_used
Definition: ad9545.h:612
#define pr_warning(fmt, args...)
Definition: no_os_print_log.h:97
#define AD9545_SYS_PLL_STABLE(x)
Definition: ad9545.h:410
#define AD9545_MODULATION_COUNTER_B1
Definition: ad9545.h:167
uint16_t modulator_reg
Definition: ad9545.h:541
int32_t ad9545_setup(struct ad9545_dev *dev)
Definition: ad9545.c:2330
#define AD9545_POWER_DOWN_REF
Definition: ad9545.h:176
#define AD9545_COMPENSATE_TDCS
Definition: ad9545.h:120
uint32_t slew_rate_limit_ps
Definition: ad9545.h:649
#define AD9545_MISC
Definition: ad9545.h:194
struct ad9545_pll_clk pll_clks[NO_OS_ARRAY_SIZE(ad9545_pll_clk_names)]
Definition: ad9545.h:762
int32_t no_os_clk_recalc_rate(struct no_os_clk_desc *desc, uint64_t *rate)
int32_t ad9545_write_reg(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t reg_data)
Definition: ad9545.c:76
int32_t ad9545_write_mask(struct ad9545_dev *dev, uint16_t reg_addr, uint32_t mask, uint8_t data)
Definition: ad9545.c:123
#define AD9545_NCO_OFFSET_FREQ_FRAC_WIDTH
Definition: ad9545.h:318
@ I2C
Definition: ad9545.h:445
struct ad9545_dpll_profile profiles[AD9545_MAX_DPLL_PROFILES]
Definition: ad9545.h:642
#define AD9545_R_DIV_MSK
Definition: ad9545.h:420
ad9545_comm_type
Definition: ad9545.h:443
unsigned int fast_acq_timeout_ms
Definition: ad9545.h:628
struct no_os_clk_desc * parent_clk
Definition: ad9545.h:700
#define AD9545_MODULATION_COUNTER_B0
Definition: ad9545.h:141
#define NO_OS_DIV_ROUND_CLOSEST(x, y)
Definition: no_os_util.h:54
#define AD9545_REF_CTRL_REFA_MSK
Definition: ad9545.h:203
#define AD9545_STABILITY_TIMER
Definition: ad9545.h:119
#define AD9545_DPLLX_FAST_L2(x, y)
Definition: ad9545.h:266
#define AD9545_REF_A_CTRL
Definition: ad9545.h:126
#define AD9545_NSHOT_EN_AB1
Definition: ad9545.h:170
chip_id
Definition: ad9172.h:51
Structure holding the parameters for SPI initialization.
Definition: no_os_spi.h:140
#define AD9545_DRIVER_0A_CONF
Definition: ad9545.h:149
uint64_t no_os_div_u64(uint64_t dividend, uint32_t divisor)