no-OS
All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
ad9545.h
Go to the documentation of this file.
1/***************************************************************************/
33
34#ifndef AD9545_H_
35#define AD9545_H_
36
37#include <stdint.h>
38#include "no_os_util.h"
39#include "no_os_delay.h"
40#include "no_os_clk.h"
41#include "no_os_gpio.h"
42#include "no_os_i2c.h"
43#include "no_os_spi.h"
44
45/* Input Driver Mode */
46#define DRIVER_MODE_AC_COUPLED_IF 0
47#define DRIVER_MODE_DC_COUPLED_1V2 1
48#define DRIVER_MODE_DC_COUPLED_1V8 2
49#define DRIVER_MODE_IN_PULL_UP 3
50
51/* Input Driver Mode */
52#define DRIVER_MODE_AC_COUPLED 0
53#define DRIVER_MODE_DC_COUPLED 1
54#define DRIVER_MODE_DC_COUPLED_LVDS 2
55
56/* Output Driver Mode */
57#define DRIVER_MODE_SINGLE_DIV_DIF 0
58#define DRIVER_MODE_SINGLE_DIV 1
59#define DRIVER_MODE_DUAL_DIV 2
60
61/* Clock types */
62#define AD9545_CLK_OUT 0
63#define AD9545_CLK_PLL 1
64#define AD9545_CLK_NCO 2
65#define AD9545_CLK_AUX_TDC 3
66
67/* PLL addresses */
68#define AD9545_PLL0 0
69#define AD9545_PLL1 1
70
71/* Outputs addresses */
72#define AD9545_Q0A 0
73#define AD9545_Q0AA 1
74#define AD9545_Q0B 2
75#define AD9545_Q0BB 3
76#define AD9545_Q0C 4
77#define AD9545_Q0CC 5
78#define AD9545_Q1A 6
79#define AD9545_Q1AA 7
80#define AD9545_Q1B 8
81#define AD9545_Q1BB 9
82
83/* NCO addresses */
84#define AD9545_NCO0 0
85#define AD9545_NCO1 1
86
87/* TDC addresses */
88#define AD9545_CLK_AUX_TDC0 0
89#define AD9545_CLK_AUX_TDC1 1
90
91/* Ex:
92 * Output Q0C clock: <&ad9545_clock AD9545_CLK_OUT AD9545_Q0C>;
93 * PLL0 clock: <&ad9545_clock AD9545_CLK_PLL AD9545_PLL0>;
94 * NCO1 clock: <&ad9545_clock AD9545_CLK_NCO AD9545_NCO1>;
95 */
96#define BYTE_ADDR_H NO_OS_GENMASK(14, 8)
97#define BYTE_ADDR_L NO_OS_GENMASK(7, 0)
98
99/*
100 * ad9545 registers definition
101 */
102
103#define AD9545_CONFIG_0 0x0000
104#define AD9545_PRODUCT_ID_LOW 0x0004
105#define AD9545_PRODUCT_ID_HIGH 0x0005
106#define AD9545_IO_UPDATE 0x000F
107#define AD9545_M0_PIN 0x0102
108#define AD9545_CHIP_ID 0x0121
109#define AD9545_SYS_CLK_FB_DIV 0x0200
110#define AD9545_SYS_CLK_INPUT 0x0201
111#define AD9545_SYS_CLK_REF_FREQ 0x0202
112#define AD9545_STABILITY_TIMER 0x0207
113#define AD9545_COMPENSATE_TDCS 0x0280
114#define AD9545_COMPENSATE_NCOS 0x0281
115#define AD9545_COMPENSATE_DPLL 0x0282
116#define AD9545_AUX_DPLL_CHANGE_LIMIT 0x0283
117#define AD9545_AUX_DPLL_SOURCE 0x0284
118#define AD9545_AUX_DPLL_LOOP_BW 0x0285
119#define AD9545_REF_A_CTRL 0x0300
120#define AD9545_REF_A_RDIV 0x0400
121#define AD9545_REF_A_PERIOD 0x0404
122#define AD9545_REF_A_OFFSET_LIMIT 0x040C
123#define AD9545_REF_A_MONITOR_HYST 0x040F
124#define AD9545_REF_A_VALID_TIMER 0x0410
125#define AD9545_PHASE_LOCK_THRESH 0x0800
126#define AD9545_PHASE_LOCK_FILL_RATE 0x0803
127#define AD9545_PHASE_LOCK_DRAIN_RATE 0x0804
128#define AD9545_FREQ_LOCK_THRESH 0x0805
129#define AD9545_FREQ_LOCK_FILL_RATE 0x0808
130#define AD9545_FREQ_LOCK_DRAIN_RATE 0x0809
131#define AD9545_DPLL0_FTW 0x1000
132#define AD9545_DPLL0_SLEW_RATE 0x1011
133#define AD9545_MODULATION_COUNTER_A0 0x10C2
134#define AD9545_MODULATION_COUNTER_B0 0x10C6
135#define AD9545_MODULATION_COUNTER_C0 0x10CA
136#define AD9545_MODULATOR_A0 0x10CF
137#define AD9545_MODULATOR_B0 0x10D0
138#define AD9545_MODULATOR_C0 0x10D1
139#define AD9545_NSHOT_REQ_CH0 0x10D3
140#define AD9545_NSHOT_EN_AB0 0x10D4
141#define AD9545_NSHOT_EN_C0 0x10D5
142#define AD9545_DRIVER_0A_CONF 0x10D7
143#define AD9545_SYNC_CTRL0 0x10DB
144#define AD9545_APLL0_M_DIV 0x1081
145#define AD9545_Q0A_DIV 0x1100
146#define AD9545_Q0A_PHASE 0x1104
147#define AD9545_Q0A_PHASE_CONF 0x1108
148#define AD9545_DPLL0_EN 0x1200
149#define AD9545_DPLL0_SOURCE 0x1201
150#define AD9545_DPLL0_ZERO_DELAY_FB 0x1202
151#define AD9545_DPLL0_FB_MODE 0x1203
152#define AD9545_DPLL0_LOOP_BW 0x1204
153#define AD9545_DPLL0_HITLESS_N 0x1208
154#define AD9545_DPLL0_N_DIV 0x120C
155#define AD9545_DPLL0_FRAC 0x1210
156#define AD9545_DPLL0_MOD 0x1213
157#define AD9545_DPLL0_FAST_L1 0x1216
158#define AD9545_DPLL0_FAST_L2 0x1217
159#define AD9545_MODULATION_COUNTER_A1 0x14C2
160#define AD9545_MODULATION_COUNTER_B1 0x14C6
161#define AD9545_MODULATOR_A1 0x14CF
162#define AD9545_MODULATOR_B1 0x14D0
163#define AD9545_NSHOT_EN_AB1 0x14D4
164#define AD9545_DRIVER_1A_CONF 0x14D7
165#define AD9545_Q1A_DIV 0x1500
166#define AD9545_Q1A_PHASE 0x1504
167#define AD9545_Q1A_PHASE_CONF 0x1508
168#define AD9545_CALIB_CLK 0x2000
169#define AD9545_POWER_DOWN_REF 0x2001
170#define AD9545_PWR_CALIB_CH0 0x2100
171#define AD9545_CTRL_CH0 0x2101
172#define AD9545_DIV_OPS_Q0A 0x2102
173#define AD9545_DPLL0_MODE 0x2105
174#define AD9545_DPLL0_FAST_MODE 0x2106
175#define AD9545_DIV_OPS_Q1A 0x2202
176#define AD9545_NCO0_CENTER_FREQ 0x2800
177#define AD9545_NCO0_OFFSET_FREQ 0x2807
178#define AD9545_NCO0_TAG_RATIO 0x280B
179#define AD9545_NCO0_TAG_DELTA 0x280D
180#define AD9545_NCO0_TYPE_ADJUST 0x280F
181#define AD9545_NCO0_DELTA_RATE_LIMIT 0x2810
182#define AD9545_NCO0_DELTA_ADJUST 0x2814
183#define AD9545_NCO0_CYCLE_ADJUST 0x2819
184#define AD9545_TDC0_DIV 0x2A00
185#define AD9545_TDC0_PERIOD 0x2A01
186#define AD9545_PLL_STATUS 0x3001
187#define AD9545_MISC 0x3002
188#define AD9545_TEMP0 0x3003
189#define AD9545_REFA_STATUS 0x3005
190#define AD9545_PLL0_STATUS 0x3100
191#define AD9545_PLL0_OPERATION 0x3101
192
193#define AD9545_SYS_CLK_STABILITY_PERIOD_MASK NO_OS_GENMASK(19, 0)
194
195#define AD9545_REF_CTRL_DIF_MSK NO_OS_GENMASK(3, 2)
196#define AD9545_REF_CTRL_REFA_MSK NO_OS_GENMASK(5, 4)
197#define AD9545_REF_CTRL_REFAA_MSK NO_OS_GENMASK(7, 6)
198
199#define AD9545_UPDATE_REGS 0x1
200#define AD9545_RESET_REGS 0x81
201
202#define AD9545_MX_PIN(x) (AD9545_M0_PIN + (x))
203
204#define AD9545_SYNC_CTRLX(x) (AD9545_SYNC_CTRL0 + ((x) * 0x400))
205#define AD9545_REF_X_RDIV(x) (AD9545_REF_A_RDIV + ((x) * 0x20))
206#define AD9545_REF_X_PERIOD(x) (AD9545_REF_A_PERIOD + ((x) * 0x20))
207#define AD9545_REF_X_OFFSET_LIMIT(x) (AD9545_REF_A_OFFSET_LIMIT + ((x) * 0x20))
208#define AD9545_REF_X_MONITOR_HYST(x) (AD9545_REF_A_MONITOR_HYST + ((x) * 0x20))
209#define AD9545_REF_X_VALID_TIMER(x) (AD9545_REF_A_VALID_TIMER + ((x) * 0x20))
210#define AD9545_REF_X_PHASE_LOCK_FILL(x) (AD9545_PHASE_LOCK_FILL_RATE + ((x) * 0x20))
211#define AD9545_REF_X_PHASE_LOCK_DRAIN(x) (AD9545_PHASE_LOCK_DRAIN_RATE + ((x) * 0x20))
212#define AD9545_REF_X_FREQ_LOCK_FILL(x) (AD9545_FREQ_LOCK_FILL_RATE + ((x) * 0x20))
213#define AD9545_REF_X_FREQ_LOCK_DRAIN(x) (AD9545_FREQ_LOCK_DRAIN_RATE + ((x) * 0x20))
214
215#define AD9545_SOURCEX_PHASE_THRESH(x) (AD9545_PHASE_LOCK_THRESH + ((x) * 0x20))
216#define AD9545_SOURCEX_FREQ_THRESH(x) (AD9545_FREQ_LOCK_THRESH + ((x) * 0x20))
217#define AD9545_NCOX_PHASE_THRESH(x) (AD9545_SOURCEX_PHASE_THRESH((x) + 4))
218#define AD9545_NCOX_FREQ_THRESH(x) (AD9545_SOURCEX_FREQ_THRESH((x) + 4))
219
220#define AD9545_APLLX_M_DIV(x) (AD9545_APLL0_M_DIV + ((x) * 0x400))
221
222#define AD9545_Q0_DIV(x) (AD9545_Q0A_DIV + ((x) * 0x9))
223#define AD9545_Q1_DIV(x) (AD9545_Q1A_DIV + ((x) * 0x9))
224#define AD9545_QX_DIV(x) ({ \
225 typeof(x) x_ = (x); \
226 \
227 (x_ > 5) ? AD9545_Q1_DIV(x_ - 6) : AD9545_Q0_DIV(x_); \
228})
229
230#define AD9545_Q0_PHASE(x) (AD9545_Q0A_PHASE + ((x) * 0x9))
231#define AD9545_Q1_PHASE(x) (AD9545_Q1A_PHASE + ((x) * 0x9))
232#define AD9545_QX_PHASE(x) ({ \
233 typeof(x) x_ = (x); \
234 \
235 (x_ > 5) ? AD9545_Q1_PHASE(x_ - 6) : AD9545_Q0_PHASE(x_); \
236})
237
238#define AD9545_Q0_PHASE_CONF(x) (AD9545_Q0A_PHASE_CONF + ((x) * 0x9))
239#define AD9545_Q1_PHASE_CONF(x) (AD9545_Q1A_PHASE_CONF + ((x) * 0x9))
240#define AD9545_QX_PHASE_CONF(x) ({ \
241 typeof(x) x_ = (x); \
242 \
243 (x_ > 5) ? AD9545_Q1_PHASE_CONF(x_ - 6) : AD9545_Q0_PHASE_CONF(x_); \
244})
245
246#define AD9545_NSHOT_REQ_CH(x) (AD9545_NSHOT_REQ_CH0 + ((x) * 0x400))
247#define AD9545_DPLLX_FTW(x) (AD9545_DPLL0_FTW + ((x) * 0x400))
248#define AD9545_DPLLX_SLEW_RATE(x) (AD9545_DPLL0_SLEW_RATE + ((x) * 0x400))
249#define AD9545_DPLLX_EN(x, y) (AD9545_DPLL0_EN + ((x) * 0x400) + ((y) * 0x20))
250#define AD9545_DPLLX_SOURCE(x, y) (AD9545_DPLL0_SOURCE + ((x) * 0x400) + ((y) * 0x20))
251#define AD9545_DPLLX_FB_PATH(x, y) (AD9545_DPLL0_ZERO_DELAY_FB + ((x) * 0x400) + ((y) * 0x20))
252#define AD9545_DPLLX_FB_MODE(x, y) (AD9545_DPLL0_FB_MODE + ((x) * 0x400) + ((y) * 0x20))
253#define AD9545_DPLLX_LOOP_BW(x, y) (AD9545_DPLL0_LOOP_BW + ((x) * 0x400) + ((y) * 0x20))
254#define AD9545_DPLLX_HITLESS_N(x, y) (AD9545_DPLL0_HITLESS_N + ((x) * 0x400) + ((y) * 0x20))
255#define AD9545_DPLLX_N_DIV(x, y) (AD9545_DPLL0_N_DIV + ((x) * 0x400) + ((y) * 0x20))
256#define AD9545_DPLLX_FRAC_DIV(x, y) (AD9545_DPLL0_FRAC + ((x) * 0x400) + ((y) * 0x20))
257#define AD9545_DPLLX_MOD_DIV(x, y) (AD9545_DPLL0_MOD + ((x) * 0x400) + ((y) * 0x20))
258#define AD9545_DPLLX_FAST_L1(x, y) (AD9545_DPLL0_FAST_L1 + ((x) * 0x400) + ((y) * 0x20))
259#define AD9545_DPLLX_FAST_L2(x, y) (AD9545_DPLL0_FAST_L2 + ((x) * 0x400) + ((y) * 0x20))
260
261#define AD9545_DIV_OPS_Q0(x) (AD9545_DIV_OPS_Q0A + (x))
262#define AD9545_DIV_OPS_Q1(x) (AD9545_DIV_OPS_Q1A + (x))
263#define AD9545_DIV_OPS_QX(x) ({ \
264 typeof(x) x_ = (x) / 2; \
265 \
266 (x_ > 2) ? AD9545_DIV_OPS_Q1(x_ - 3) : AD9545_DIV_OPS_Q0(x_); \
267})
268
269#define AD9545_PWR_CALIB_CHX(x) (AD9545_PWR_CALIB_CH0 + ((x) * 0x100))
270#define AD9545_PLLX_STATUS(x) (AD9545_PLL0_STATUS + ((x) * 0x100))
271#define AD9545_PLLX_OPERATION(x) (AD9545_PLL0_OPERATION + ((x) * 0x100))
272#define AD9545_CTRL_CH(x) (AD9545_CTRL_CH0 + ((x) * 0x100))
273#define AD9545_DPLLX_FAST_MODE(x) (AD9545_DPLL0_FAST_MODE + ((x) * 0x100))
274#define AD9545_REFX_STATUS(x) (AD9545_REFA_STATUS + (x))
275
276#define AD9545_PROFILE_SEL_MODE_MSK NO_OS_GENMASK(3, 2)
277#define AD9545_PROFILE_SEL_MODE(x) no_os_field_prep(AD9545_PROFILE_SEL_MODE_MSK, x)
278
279#define AD9545_NCOX_CENTER_FREQ(x) (AD9545_NCO0_CENTER_FREQ + ((x) * 0x40))
280#define AD9545_NCOX_OFFSET_FREQ(x) (AD9545_NCO0_OFFSET_FREQ + ((x) * 0x40))
281#define AD9545_NCOX_TAG_RATIO(x) (AD9545_NCO0_TAG_RATIO + ((x) * 0x40))
282#define AD9545_NCOX_TAG_DELTA(x) (AD9545_NCO0_TAG_DELTA + ((x) * 0x40))
283#define AD9545_NCOX_TYPE_ADJUST(x) (AD9545_NCO0_TYPE_ADJUST + ((x) * 0x40))
284#define AD9545_NCOX_DELTA_RATE_LIMIT(x) (AD9545_NCO0_DELTA_RATE_LIMIT + ((x) * 0x40))
285#define AD9545_NCOX_DELTA_ADJUST(x) (AD9545_NCO0_DELTA_ADJUST + ((x) * 0x40))
286#define AD9545_NCOX_CYCLE_ADJUST(x) (AD9545_NCO0_CYCLE_ADJUST + ((x) * 0x40))
287
288/*
289 * AD9545 AUX NCO center frequency register has 16-bit integer part and
290 * 40-bit fractional part.
291 */
292#define AD9545_NCO_CENTER_FREQ_INT_WIDTH 16
293#define AD9545_NCO_CENTER_FREQ_FRAC_WIDTH 40
294#define AD9545_NCO_CENTER_FREQ_WIDTH (AD9545_NCO_CENTER_FREQ_INT_WIDTH + \
295 AD9545_NCO_CENTER_FREQ_FRAC_WIDTH)
296
297#define AD9545_NCO_CENTER_FREQ_MSK NO_OS_GENMASK_ULL(AD9545_NCO_CENTER_FREQ_WIDTH - 1, 0)
298#define AD9545_NCO_CENTER_FREQ_INT_MSK NO_OS_GENMASK_ULL(AD9545_NCO_CENTER_FREQ_WIDTH - 1, \
299 AD9545_NCO_CENTER_FREQ_FRAC_WIDTH)
300#define AD9545_NCO_CENTER_FREQ_FRAC_MSK NO_OS_GENMASK_ULL(AD9545_NCO_CENTER_FREQ_FRAC_WIDTH - 1, 0)
301
302#define AD9545_NCO_CENTER_FREQ_MAX no_os_field_max_u64(AD9545_NCO_CENTER_FREQ_MSK)
303#define AD9545_NCO_CENTER_FREQ_INT_MAX no_os_field_max_u64(AD9545_NCO_CENTER_FREQ_INT_MSK)
304#define AD9545_NCO_CENTER_FREQ_FRAC_MAX no_os_field_max_u64(AD9545_NCO_CENTER_FREQ_FRAC_MSK)
305
306/*
307 * AD9545 AUX NCO offset frequency register has 8-bit integer part and
308 * 24-bit fractional part.
309 */
310#define AD9545_NCO_OFFSET_FREQ_INT_WIDTH 8
311#define AD9545_NCO_OFFSET_FREQ_FRAC_WIDTH 24
312#define AD9545_NCO_OFFSET_FREQ_WIDTH (AD9545_NCO_OFFSET_FREQ_INT_WIDTH + \
313 AD9545_NCO_OFFSET_FREQ_FRAC_WIDTH)
314
315#define AD9545_NCO_OFFSET_FREQ_MSK NO_OS_GENMASK_ULL(AD9545_NCO_OFFSET_FREQ_WIDTH - 1, 0)
316#define AD9545_NCO_OFFSET_FREQ_INT_MSK NO_OS_GENMASK_ULL(AD9545_NCO_OFFSET_FREQ_WIDTH - 1, \
317 AD9545_NCO_OFFSET_FREQ_FRAC_WIDTH)
318#define AD9545_NCO_OFFSET_FREQ_FRAC_MSK NO_OS_GENMASK_ULL(AD9545_NCO_OFFSET_FREQ_FRAC_WIDTH - 1, 0)
319
320#define AD9545_NCO_OFFSET_FREQ_MAX no_os_field_max(AD9545_NCO_OFFSET_FREQ_MSK)
321#define AD9545_NCO_OFFSET_FREQ_INT_MAX no_os_field_max(AD9545_NCO_OFFSET_FREQ_INT_MSK)
322#define AD9545_NCO_OFFSET_FREQ_FRAC_MAX no_os_field_max(AD9545_NCO_OFFSET_FREQ_FRAC_MSK)
323
324#define AD9545_NCO_FREQ_INT_MAX (AD9545_NCO_CENTER_FREQ_INT_MAX + \
325 AD9545_NCO_OFFSET_FREQ_INT_MAX)
326
327#define AD9545_TDCX_DIV(x) (AD9545_TDC0_DIV + ((x) * 0x9))
328#define AD9545_TDCX_PERIOD(x) (AD9545_TDC0_PERIOD + ((x) * 0x9))
329
330/* AD9545 MX PIN bitfields */
331#define AD9545_MX_TO_TDCX(x) (0x30 + (x))
332
333/* AD9545 COMPENSATE TDCS bitfields */
334#define AD9545_COMPENSATE_TDCS_VIA_AUX_DPLL 0x4
335
336/* AD9545 COMPENSATE NCOS bitfields */
337#define AD9545_COMPENSATE_NCOS_VIA_AUX_DPLL 0x44
338
339/* AD9545 COMPENSATE DPLL bitfields */
340#define AD9545_COMPNESATE_VIA_AUX_DPLL 0x44
341
342/* define AD9545_DPLLX_EN bitfields */
343#define AD9545_EN_PROFILE_MSK NO_OS_BIT(0)
344#define AD9545_SEL_PRIORITY_MSK NO_OS_GENMASK(5, 1)
345
346/* define AD9545_DPLLX_FB_MODE bitfields */
347#define AD9545_EN_HITLESS_MSK NO_OS_BIT(0)
348#define AD9545_TAG_MODE_MSK NO_OS_GENMASK(4, 2)
349#define AD9545_BASE_FILTER_MSK NO_OS_BIT(7)
350
351/* AD9545_PWR_CALIB_CHX bitfields */
352#define AD9545_PWR_DOWN_CH NO_OS_BIT(0)
353#define AD9545_CALIB_APLL NO_OS_BIT(1)
354
355/* AD9545_SYNC_CTRLX bitfields */
356#define AD9545_SYNC_CTRL_DPLL_REF_MSK NO_OS_BIT(2)
357#define AD9545_SYNC_CTRL_MODE_MSK NO_OS_GENMASK(1, 0)
358
359/* AD9545_QX_PHASE_CONF bitfields */
360#define AD9545_QX_HALF_DIV_MSK NO_OS_BIT(5)
361#define AD9545_QX_PHASE_32_MSK NO_OS_BIT(6)
362
363/* AD9545_DIV_OPS_QX bitfields */
364#define AD9545_DIV_OPS_MUTE_A_MSK NO_OS_BIT(2)
365#define AD9545_DIV_OPS_MUTE_AA_MSK NO_OS_BIT(3)
366
367/* AD9545 Modulator bitfields */
368#define AD9545_MODULATOR_EN NO_OS_BIT(0)
369
370/* AD9545_NSHOT_REQ_CH bitfields */
371#define AD9545_NSHOT_NR_MSK NO_OS_GENMASK(5, 0)
372
373/* AD9545_CTRL_CH bitfields */
374#define AD9545_CTRL_CH_NSHOT_MSK NO_OS_BIT(0)
375
376/* AD9545_PLL_STATUS bitfields */
377#define AD9545_PLLX_LOCK(x, y) ((1 << (4 + (x))) & (y))
378
379/* AD9545_MISC bitfields */
380#define AD9545_MISC_AUX_NC0_ERR_MSK NO_OS_GENMASK(5, 4)
381#define AD9545_MISC_AUX_NC1_ERR_MSK NO_OS_GENMASK(7, 6)
382#define AD9545_AUX_DPLL_LOCK_MSK NO_OS_BIT(1)
383#define AD9545_AUX_DPLL_REF_FAULT NO_OS_BIT(2)
384
385/* AD9545_REFX_STATUS bitfields */
386#define AD9545_REFX_SLOW_MSK NO_OS_BIT(0)
387#define AD9545_REFX_FAST_MSK NO_OS_BIT(1)
388#define AD9545_REFX_JITTER_MSK NO_OS_BIT(2)
389#define AD9545_REFX_FAULT_MSK NO_OS_BIT(3)
390#define AD9545_REFX_VALID_MSK NO_OS_BIT(4)
391#define AD9545_REFX_LOS_MSK NO_OS_BIT(5)
392
393/* AD9545_PLL0_STATUS bitfields */
394#define AD9545_PLL_LOCKED NO_OS_BIT(0)
395
396/* AD9545_PLL0_OPERATION bitfields */
397#define AD9545_PLL_FREERUN NO_OS_BIT(0)
398#define AD9545_PLL_HOLDOVER NO_OS_BIT(1)
399#define AD9545_PLL_ACTIVE NO_OS_BIT(3)
400#define AD9545_PLL_ACTIVE_PROFILE NO_OS_GENMASK(6, 4)
401
402#define AD9545_SYS_PLL_STABLE_MSK NO_OS_GENMASK(1, 0)
403#define AD9545_SYS_PLL_STABLE(x) (((x) & AD9545_SYS_PLL_STABLE_MSK) == 0x3)
404
405#define AD9545_APLL_LOCKED(x) ((x) & NO_OS_BIT(3))
406
407/* AD9545 tagging modes */
408#define AD9545_NO_TAGGING 0
409#define AD9545_FB_PATH_TAG 2
410
411#define AD9545_SYS_CLK_STABILITY_MS 50
412
413#define AD9545_R_DIV_MSK NO_OS_GENMASK(29, 0)
414#define AD9545_R_DIV_MAX 0x40000000
415#define AD9545_IN_MAX_TDC_FREQ_HZ 200000
416
417#define AD9545_MAX_REFS 4
418
419#define AD9545_APLL_M_DIV_MIN 1
420#define AD9545_APLL_M_DIV_MAX 255
421
422#define AD9545_DPLL_MAX_N 1073741823
423#define AD9545_DPLL_MAX_FRAC 16777215
424#define AD9545_DPLL_MAX_MOD 16777215
425#define AD9545_MAX_DPLL_PROFILES 6
426
427#define AD9545_MAX_NSHOT_PULSES 63
428
429#define AD9545_MAX_ZERO_DELAY_RATE 200000000
430
431#define AD9545_MIN_SYS_CLK_FREQ 2250
432#define AD9545_MAX_SYS_CLK_FREQ 2415
433#define AD9545_MIN_DIV_RATIO 4
434#define AD9545_MAX_DIV_RATIO 256
435
440
441static const unsigned int ad9545_apll_rate_ranges_hz[2][2] = {
442 {2424000000U, 3232000000U}, {3232000000U, 4040000000U}
443};
444
445static const unsigned int ad9545_apll_pfd_rate_ranges_hz[2] = {
446 162000000U, 350000000U
447};
448
449static const unsigned short ad9545_vco_calibration_op[][2] = {
450 {AD9545_CALIB_CLK, 0},
454};
455
456static const uint8_t ad9545_tdc_source_mapping[] = {
457 0, 1, 2, 3, 8, 9,
458};
459
460static const uint32_t ad9545_fast_acq_excess_bw_map[] = {
461 0, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024,
462};
463
464static const uint32_t ad9545_fast_acq_timeout_map[] = {
465 1, 10, 50, 100, 500, 1000, 10000, 50000,
466};
467
468static const uint32_t ad9545_hyst_scales_bp[] = {
469 0, 3125, 6250, 12500, 25000, 50000, 75000, 87500
470};
471
472static const uint32_t ad9545_out_source_ua[] = {
473 7500, 12500, 15000
474};
475
476static const uint32_t ad9545_rate_change_limit_map[] = {
477 715, 1430, 2860, 5720, 11440, 22880, 45760,
478};
479
480static const char * const ad9545_ref_m_clk_names[] = {
481 "Ref-M0", "Ref-M1", "Ref-M2",
482};
483
484static const char * const ad9545_ref_clk_names[] = {
485 "Ref-A", "Ref-AA", "Ref-B", "Ref-BB",
486};
487
488static const char * const ad9545_in_clk_names[] = {
489 "Ref-A-Div", "Ref-AA-Div", "Ref-B-Div", "Ref-BB-Div",
490};
491
492static const char * const ad9545_out_clk_names[] = {
493 "Q0A-div", "Q0AA-div", "Q0B-div", "Q0BB-div", "Q0C-div", "Q0CC-div", "Q1A-div", "Q1AA-div",
494 "Q1B-div", "Q1BB-div",
495};
496
497static const char * const ad9545_pll_clk_names[] = {
498 "PLL0", "PLL1",
499};
500
501static const char * const ad9545_aux_nco_clk_names[] = {
502 "AUX_NCO0", "AUX_NCO1",
503};
504
505static const char * const ad9545_aux_tdc_clk_names[] = {
506 "AUX_TDC0", "AUX_TDC1",
507};
508
513
520
526
532
539
540static const struct ad9545_outputs_regs ad9545_out_regs[] = {
541 {
542 .modulator_reg = AD9545_MODULATOR_A0,
543 .modulation_counter_reg = AD9545_MODULATION_COUNTER_A0,
544 .nshot_en_reg = AD9545_NSHOT_EN_AB0,
545 .nshot_en_msk = NO_OS_BIT(0),
546 },
547 {
548 .modulator_reg = AD9545_MODULATOR_A0,
549 .modulation_counter_reg = AD9545_MODULATION_COUNTER_A0,
550 .nshot_en_reg = AD9545_NSHOT_EN_AB0,
551 .nshot_en_msk = NO_OS_BIT(2),
552 },
553 {
554 .modulator_reg = AD9545_MODULATOR_B0,
555 .modulation_counter_reg = AD9545_MODULATION_COUNTER_B0,
556 .nshot_en_reg = AD9545_NSHOT_EN_AB0,
557 .nshot_en_msk = NO_OS_BIT(4),
558 },
559 {
560 .modulator_reg = AD9545_MODULATOR_B0,
561 .modulation_counter_reg = AD9545_MODULATION_COUNTER_B0,
562 .nshot_en_reg = AD9545_NSHOT_EN_AB0,
563 .nshot_en_msk = NO_OS_BIT(6),
564 },
565 {
566 .modulator_reg = AD9545_MODULATOR_C0,
567 .modulation_counter_reg = AD9545_MODULATION_COUNTER_C0,
568 .nshot_en_reg = AD9545_NSHOT_EN_C0,
569 .nshot_en_msk = NO_OS_BIT(0),
570 },
571 {
572 .modulator_reg = AD9545_MODULATOR_C0,
573 .modulation_counter_reg = AD9545_MODULATION_COUNTER_C0,
574 .nshot_en_reg = AD9545_NSHOT_EN_C0,
575 .nshot_en_msk = NO_OS_BIT(2),
576 },
577 {
578 .modulator_reg = AD9545_MODULATOR_A1,
579 .modulation_counter_reg = AD9545_MODULATION_COUNTER_A1,
580 .nshot_en_reg = AD9545_NSHOT_EN_AB1,
581 .nshot_en_msk = NO_OS_BIT(0),
582 },
583 {
584 .modulator_reg = AD9545_MODULATOR_A1,
585 .modulation_counter_reg = AD9545_MODULATION_COUNTER_A1,
586 .nshot_en_reg = AD9545_NSHOT_EN_AB1,
587 .nshot_en_msk = NO_OS_BIT(2),
588 },
589 {
590 .modulator_reg = AD9545_MODULATOR_B1,
591 .modulation_counter_reg = AD9545_MODULATION_COUNTER_B1,
592 .nshot_en_reg = AD9545_NSHOT_EN_AB1,
593 .nshot_en_msk = NO_OS_BIT(4),
594 },
595 {
596 .modulator_reg = AD9545_MODULATOR_B1,
597 .modulation_counter_reg = AD9545_MODULATION_COUNTER_B1,
598 .nshot_en_reg = AD9545_NSHOT_EN_AB1,
599 .nshot_en_msk = NO_OS_BIT(6),
600 },
601};
602
614
616 unsigned int address;
617 unsigned int parent_index;
618 unsigned int priority;
619 unsigned int loop_bw_uhz;
620 unsigned int fast_acq_excess_bw;
622 unsigned int fast_acq_settle_ms;
623 bool en;
624 uint8_t tdc_source;
626};
627
644
667
672 unsigned int address;
673 unsigned int freq_thresh_ps;
674 unsigned int phase_thresh_ps;
675};
676
681 unsigned int address;
682 unsigned int pin_nr;
684};
685
690 unsigned int source;
691 unsigned int loop_bw_mhz;
692 unsigned int rate_change_limit;
694};
695
702
703struct ad9545_dev;
704
705typedef int32_t (*ad9545_reg_read_func)(struct ad9545_dev *dev,
706 uint16_t reg_addr,
707 uint8_t *reg_data);
708typedef int32_t (*ad9545_reg_write_func)(struct ad9545_dev *dev,
709 uint16_t reg_addr,
710 uint8_t reg_data);
711typedef int32_t (*ad9545_reg_read_multi_func)(struct ad9545_dev *dev,
712 uint16_t reg_addr,
713 uint8_t *reg_data,
714 uint16_t count);
715typedef int32_t (*ad9545_reg_write_multi_func)(struct ad9545_dev *dev,
716 uint16_t reg_addr,
717 uint8_t *reg_data,
718 uint16_t count);
719
721 /* SPI */
723 /* I2C */
725 /* Device Settings */
730 /* Device Settings */
734 struct ad9545_pll_clk pll_clks[NO_OS_ARRAY_SIZE(ad9545_pll_clk_names)];
735 struct ad9545_ref_in_clk ref_in_clks[NO_OS_ARRAY_SIZE(ad9545_ref_clk_names)];
736 struct ad9545_out_clk out_clks[NO_OS_ARRAY_SIZE(ad9545_out_clk_names)];
738 ad9545_aux_nco_clk_names)];
740 ad9545_aux_tdc_clk_names)];
741 /* CLK descriptors */
742 struct no_os_clk_desc **clks[4];
743
744};
745
747 /* SPI */
749 /* I2C */
751 /* Device Settings */
755 struct ad9545_pll_clk pll_clks[NO_OS_ARRAY_SIZE(ad9545_pll_clk_names)];
756 struct ad9545_ref_in_clk ref_in_clks[NO_OS_ARRAY_SIZE(ad9545_ref_clk_names)];
757 struct ad9545_out_clk out_clks[NO_OS_ARRAY_SIZE(ad9545_out_clk_names)];
759 ad9545_aux_nco_clk_names)];
761 ad9545_aux_tdc_clk_names)];
762
763};
764
765/* Reads a single byte from the specified SPI register address */
766int32_t ad9545_spi_reg_read(struct ad9545_dev *dev,
767 uint16_t reg_addr,
768 uint8_t *reg_data);
769
770/* Reads multiple bytes starting from the specified SPI register address */
772 uint16_t reg_addr,
773 uint8_t *reg_data,
774 uint16_t count);
775/* Writes a single byte to the specified SPI register address */
776int32_t ad9545_spi_reg_write(struct ad9545_dev *dev,
777 uint16_t reg_addr,
778 uint8_t reg_data);
779/* Writes multiple bytes starting from the specified SPI register address */
781 uint16_t reg_addr,
782 uint8_t *reg_data,
783 uint16_t count);
784/* Reads a single byte from the specified I2C register address */
785int32_t ad9545_i2c_reg_read(struct ad9545_dev *dev,
786 uint16_t reg_addr,
787 uint8_t *reg_data);
788/* Writes a single byte to the specified I2C register address */
789int32_t ad9545_i2c_reg_write(struct ad9545_dev *dev,
790 uint16_t reg_addr,
791 uint8_t reg_data);
792/* Reads multiple bytes starting from the specified I2C register address */
794 uint16_t reg_addr,
795 uint8_t *reg_data,
796 uint16_t count);
797/* Writes multiple bytes starting from the specified I2C register address */
799 uint16_t reg_addr,
800 uint8_t *reg_data,
801 uint16_t count);
802/* Modifies specific bits in the specified register and writes the new value. */
803int32_t ad9545_write_mask(struct ad9545_dev *dev,
804 uint16_t reg_addr,
805 uint32_t mask,
806 uint8_t data);
807
808/* Calibrates the APLLs of the AD9545 device. */
810
811/* Device Setup */
812int32_t ad9545_setup(struct ad9545_dev *dev);
813
814/* Device Initialization */
815int32_t ad9545_init(struct ad9545_dev **device,
817
818/* Free resources */
819int32_t ad9545_remove(struct ad9545_dev *dev);
820
821
822#endif // AD9545_H_
struct ad7616_init_param init_param
Definition ad7616_sdz.c:107
ad9545_ref_mode
Definition ad9545.h:509
@ AD9545_DIFFERENTIAL
Definition ad9545.h:511
@ AD9545_SINGLE_ENDED
Definition ad9545.h:510
ad9545_single_ended_config
Definition ad9545.h:514
@ AD9545_IN_PULL_UP
Definition ad9545.h:518
@ AD9545_DC_COUPLED_1V8
Definition ad9545.h:517
@ AD9545_DC_COUPLED_1V2
Definition ad9545.h:516
@ AD9545_AC_COUPLED_IF
Definition ad9545.h:515
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
#define AD9545_NSHOT_EN_AB0
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_MODULATOR_B0
Definition ad9545.h:137
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 ad9545_init(struct ad9545_dev **device, struct ad9545_init_param *init_param)
Definition ad9545.c:1528
#define AD9545_MODULATION_COUNTER_C0
Definition ad9545.h:135
#define AD9545_MODULATOR_A1
Definition ad9545.h:161
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
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:715
#define AD9545_MODULATION_COUNTER_B1
Definition ad9545.h:160
int32_t(* ad9545_reg_read_func)(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t *reg_data)
Definition ad9545.h:705
#define AD9545_UPDATE_REGS
Definition ad9545.h:199
int32_t ad9545_write_mask(struct ad9545_dev *dev, uint16_t reg_addr, uint32_t mask, uint8_t data)
Definition ad9545.c:116
#define AD9545_MODULATION_COUNTER_B0
Definition ad9545.h:134
int32_t ad9545_i2c_reg_write(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t reg_data)
Definition ad9545_i2c.c:77
ad9545_diferential_config
Definition ad9545.h:521
@ AD9545_DC_COUPLED
Definition ad9545.h:523
@ AD9545_DC_COUPLED_LVDS
Definition ad9545.h:524
@ AD9545_AC_COUPLED
Definition ad9545.h:522
ad9545_output_mode
Definition ad9545.h:527
@ AD9545_SINGLE_DIV
Definition ad9545.h:529
@ AD9545_DUAL_DIV
Definition ad9545.h:530
@ AD9545_SINGLE_DIV_DIF
Definition ad9545.h:528
#define AD9545_MODULATION_COUNTER_A1
Definition ad9545.h:159
int32_t(* ad9545_reg_write_func)(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t reg_data)
Definition ad9545.h:708
#define AD9545_MODULATOR_B1
Definition ad9545.h:162
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:711
#define AD9545_NSHOT_EN_AB1
Definition ad9545.h:163
#define AD9545_IO_UPDATE
Definition ad9545.h:106
#define AD9545_MODULATOR_C0
Definition ad9545.h:138
ad9545_comm_type
Definition ad9545.h:436
#define AD9545_NSHOT_EN_C0
Definition ad9545.h:141
int32_t ad9545_setup(struct ad9545_dev *dev)
Definition ad9545.c:2323
#define AD9545_CALIB_CLK
Definition ad9545.h:168
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_MAX_DPLL_PROFILES
Definition ad9545.h:425
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
int32_t ad9545_remove(struct ad9545_dev *dev)
Free the memory allocated by ad9545_init().
Definition ad9545.c:2398
#define AD9545_MODULATION_COUNTER_A0
Definition ad9545.h:133
#define AD9545_MODULATOR_A0
Definition ad9545.h:136
int ad9545_calib_aplls(struct ad9545_dev *dev)
Definition ad9545.c:2038
int32_t ad9545_spi_reg_read(struct ad9545_dev *dev, uint16_t reg_addr, uint8_t *reg_data)
Definition ad9545_spi.c:50
@ I2C
Definition adxl372.h:311
@ SPI
Definition adxl372.h:310
Header file of Clock Driver.
Header file of Delay functions.
Header file of GPIO Interface.
Header file of I2C Interface.
Header file of SPI Interface.
Header file of utility functions.
#define NO_OS_ARRAY_SIZE(x)
Definition no_os_util.h:43
#define NO_OS_BIT(x)
Definition no_os_util.h:39
Definition ad9545.h:686
bool dpll_used
Definition ad9545.h:688
unsigned int loop_bw_mhz
Definition ad9545.h:691
unsigned int rate_change_limit
Definition ad9545.h:692
struct no_os_clk_desc * hw
Definition ad9545.h:687
struct ad9545_dev * dev
Definition ad9545.h:689
struct no_os_clk_desc * parent_clk
Definition ad9545.h:693
unsigned int source
Definition ad9545.h:690
Definition ad9545.h:668
unsigned int address
Definition ad9545.h:672
bool nco_used
Definition ad9545.h:670
unsigned int phase_thresh_ps
Definition ad9545.h:674
struct no_os_clk_desc * hw
Definition ad9545.h:669
struct ad9545_dev * dev
Definition ad9545.h:671
unsigned int freq_thresh_ps
Definition ad9545.h:673
Definition ad9545.h:677
struct no_os_clk_desc * hw
Definition ad9545.h:678
struct no_os_clk_desc * parent_clk
Definition ad9545.h:683
bool tdc_used
Definition ad9545.h:679
struct ad9545_dev * dev
Definition ad9545.h:680
unsigned int pin_nr
Definition ad9545.h:682
unsigned int address
Definition ad9545.h:681
Definition ad9545.h:720
struct ad9545_pll_clk pll_clks[NO_OS_ARRAY_SIZE(ad9545_pll_clk_names)]
Definition ad9545.h:734
struct ad9545_out_clk out_clks[NO_OS_ARRAY_SIZE(ad9545_out_clk_names)]
Definition ad9545.h:736
struct no_os_i2c_desc * i2c_desc
Definition ad9545.h:724
struct ad9545_aux_dpll_clk aux_dpll_clk
Definition ad9545.h:733
ad9545_reg_write_func reg_write
Definition ad9545.h:727
enum ad9545_comm_type comm_type
Definition ad9545.h:731
struct no_os_spi_desc * spi_desc
Definition ad9545.h:722
ad9545_reg_read_multi_func reg_read_multiple
Definition ad9545.h:728
struct ad9545_aux_nco_clk aux_nco_clks[NO_OS_ARRAY_SIZE(ad9545_aux_nco_clk_names)]
Definition ad9545.h:737
struct ad9545_aux_tdc_clk aux_tdc_clks[NO_OS_ARRAY_SIZE(ad9545_aux_tdc_clk_names)]
Definition ad9545.h:739
struct no_os_clk_desc ** clks[4]
Definition ad9545.h:742
ad9545_reg_write_multi_func reg_write_multiple
Definition ad9545.h:729
struct ad9545_sys_clk sys_clk
Definition ad9545.h:732
ad9545_reg_read_func reg_read
Definition ad9545.h:726
struct ad9545_ref_in_clk ref_in_clks[NO_OS_ARRAY_SIZE(ad9545_ref_clk_names)]
Definition ad9545.h:735
Definition ad9545.h:615
unsigned int parent_index
Definition ad9545.h:617
unsigned int address
Definition ad9545.h:616
unsigned int loop_bw_uhz
Definition ad9545.h:619
unsigned int fast_acq_settle_ms
Definition ad9545.h:622
unsigned int fast_acq_excess_bw
Definition ad9545.h:620
unsigned int fast_acq_timeout_ms
Definition ad9545.h:621
uint8_t tdc_source
Definition ad9545.h:624
bool en
Definition ad9545.h:623
bool fb_tagging
Definition ad9545.h:625
unsigned int priority
Definition ad9545.h:618
Definition ad9545.h:746
struct ad9545_ref_in_clk ref_in_clks[NO_OS_ARRAY_SIZE(ad9545_ref_clk_names)]
Definition ad9545.h:756
struct no_os_spi_init_param * spi_init
Definition ad9545.h:748
struct ad9545_pll_clk pll_clks[NO_OS_ARRAY_SIZE(ad9545_pll_clk_names)]
Definition ad9545.h:755
struct ad9545_aux_nco_clk aux_nco_clks[NO_OS_ARRAY_SIZE(ad9545_aux_nco_clk_names)]
Definition ad9545.h:758
struct ad9545_aux_tdc_clk aux_tdc_clks[NO_OS_ARRAY_SIZE(ad9545_aux_tdc_clk_names)]
Definition ad9545.h:760
struct ad9545_aux_dpll_clk aux_dpll_clk
Definition ad9545.h:754
struct ad9545_out_clk out_clks[NO_OS_ARRAY_SIZE(ad9545_out_clk_names)]
Definition ad9545.h:757
enum ad9545_comm_type comm_type
Definition ad9545.h:752
struct no_os_i2c_init_param * i2c_init
Definition ad9545.h:750
struct ad9545_sys_clk sys_clk
Definition ad9545.h:753
Definition ad9545.h:603
unsigned int address
Definition ad9545.h:610
uint32_t source_ua
Definition ad9545.h:608
struct no_os_clk_desc * parent_clk
Definition ad9545.h:612
enum ad9545_output_mode output_mode
Definition ad9545.h:607
bool source_current
Definition ad9545.h:606
struct ad9545_dev * dev
Definition ad9545.h:604
struct no_os_clk_desc * hw
Definition ad9545.h:609
bool output_used
Definition ad9545.h:605
uint64_t rate_requested_hz
Definition ad9545.h:611
Definition ad9545.h:533
uint8_t nshot_en_msk
Definition ad9545.h:537
uint16_t modulator_reg
Definition ad9545.h:534
uint16_t nshot_en_reg
Definition ad9545.h:536
uint16_t modulation_counter_reg
Definition ad9545.h:535
Definition ad9545.h:628
uint8_t num_parents
Definition ad9545.h:633
unsigned int address
Definition ad9545.h:631
unsigned int fast_acq_trigger_mode
Definition ad9545.h:637
struct ad9545_dpll_profile profiles[AD9545_MAX_DPLL_PROFILES]
Definition ad9545.h:635
unsigned int free_run_freq
Definition ad9545.h:636
struct no_os_clk_desc ** parents
Definition ad9545.h:634
uint8_t internal_zero_delay_source
Definition ad9545.h:640
struct ad9545_dev * dev
Definition ad9545.h:629
uint64_t rate_requested_hz
Definition ad9545.h:638
bool pll_used
Definition ad9545.h:630
uint32_t slew_rate_limit_ps
Definition ad9545.h:642
uint64_t internal_zero_delay_source_rate_hz
Definition ad9545.h:641
struct no_os_clk_desc * hw
Definition ad9545.h:632
bool internal_zero_delay
Definition ad9545.h:639
Definition ad9545.h:645
struct no_os_clk_desc * hw
Definition ad9545.h:646
unsigned int phase_lock_fill_rate
Definition ad9545.h:658
bool ref_used
Definition ad9545.h:649
unsigned int freq_lock_drain_rate
Definition ad9545.h:661
unsigned int freq_thresh_ps
Definition ad9545.h:656
uint32_t r_div_ratio
Definition ad9545.h:648
unsigned int phase_thresh_ps
Definition ad9545.h:657
unsigned int phase_lock_drain_rate
Definition ad9545.h:659
uint32_t valid_t_ms
Definition ad9545.h:652
uint32_t d_tol_ppb
Definition ad9545.h:650
struct ad9545_dev * dev
Definition ad9545.h:647
unsigned int freq_lock_fill_rate
Definition ad9545.h:660
enum ad9545_single_ended_config s_conf
Definition ad9545.h:663
enum ad9545_diferential_config d_conf
Definition ad9545.h:664
struct no_os_clk_desc * parent_clk
Definition ad9545.h:653
uint8_t monitor_hyst_scale
Definition ad9545.h:651
enum ad9545_ref_mode mode
Definition ad9545.h:655
unsigned int address
Definition ad9545.h:654
Definition ad9545.h:696
uint32_t sys_freq_hz
Definition ad9545.h:700
bool sys_clk_freq_doubler
Definition ad9545.h:697
uint32_t ref_freq_hz
Definition ad9545.h:699
bool sys_clk_crystal
Definition ad9545.h:698
Definition ad9361_util.h:63
Structure holding CLK descriptor.
Definition no_os_clk.h:69
Structure holding I2C address descriptor.
Definition no_os_i2c.h:89
Structure holding the parameters for I2C initialization.
Definition no_os_i2c.h:52
Structure holding SPI descriptor.
Definition no_os_spi.h:180
Structure holding the parameters for SPI initialization.
Definition no_os_spi.h:128