no-OS
adf4106.h
Go to the documentation of this file.
1 /**************************************************************************/
41 #ifndef __ADF4106_H__
42 #define __ADF4106_H__
43 
44 /*****************************************************************************/
45 /****************************** Include Files ********************************/
46 /*****************************************************************************/
47 #include <stdint.h>
48 #include "no_os_delay.h"
49 #include "no_os_gpio.h"
50 #include "no_os_spi.h"
51 
52 /*****************************************************************************/
53 /* Device specific MACROs */
54 /*****************************************************************************/
55 /* GPIOs */
56 #define ADF4106_LE_OUT no_os_gpio_direction_output(dev->gpio_le, \
57  NO_OS_GPIO_HIGH)
58 #define ADF4106_LE_LOW no_os_gpio_set_value(dev->gpio_le, \
59  NO_OS_GPIO_LOW)
60 #define ADF4106_LE_HIGH no_os_gpio_set_value(dev->gpio_le, \
61  NO_OS_GPIO_HIGH)
62 
63 #define ADF4106_CE_OUT no_os_gpio_direction_output(dev->gpio_ce, \
64  NO_OS_GPIO_HIGH)
65 #define ADF4106_CE_LOW no_os_gpio_set_value(dev->gpio_ce, \
66  NO_OS_GPIO_LOW)
67 #define ADF4106_CE_HIGH no_os_gpio_set_value(dev->gpio_ce, \
68  NO_OS_GPIO_HIGH)
69 
70 #define ADF4106_LE2_OUT no_os_gpio_direction_output(dev->gpio_le2, \
71  NO_OS_GPIO_HIGH)
72 #define ADF4106_LE2_LOW no_os_gpio_set_value(dev->gpio_le2, \
73  NO_OS_GPIO_LOW)
74 #define ADF4106_LE2_HIGH no_os_gpio_set_value(dev->gpio_le2, \
75  NO_OS_GPIO_HIGH)
76 
77 #define ADF4106_CE2_OUT no_os_gpio_direction_output(dev->gpio_ce2, \
78  NO_OS_GPIO_HIGH)
79 #define ADF4106_CE2_LOW no_os_gpio_set_value(dev->gpio_ce2, \
80  NO_OS_GPIO_LOW)
81 #define ADF4106_CE2_HIGH no_os_gpio_set_value(dev->gpio_ce2, \
82  NO_OS_GPIO_HIGH)
83 
84 /* Control Bits */
85 #define ADF4106_CTRL_MASK 0x3
86 
87 #define ADF4106_CTRL_R_COUNTER 0 /* Reference Counter */
88 #define ADF4106_CTRL_N_COUNTER 1 /* N Counter */
89 #define ADF4106_CTRL_FUNCTION_LATCH 2 /* Function Latch*/
90 #define ADF4106_CTRL_INIT_LATCH 3 /* Initialization Latch*/
91 
92 /* Reference Counter Latch */
93 
94 #define ADF4106_R_COUNTER_OFFSET 2
95 #define ADF4106_R_COUNTER_MASK 0x3FFFul
96 #define ADF4106_R_COUNTER(x) ((x) & ADF4106_R_COUNTER_MASK) \
97  << ADF4106_R_COUNTER_OFFSET
98 /* Anti-backlash Pulse Width options */
99 #define ADF4106_R_ABP_OFFSET 16
100 #define ADF4106_R_ABP_MASK 0x3
101 #define ADF4106_R_ABP(x) ((x) & ADF4106_R_ABP_MASK) \
102  << ADF4106_R_ABP_OFFSET
103 #define ADF4106_R_ABP_2_9NS 0
104 #define ADF4106_R_ABP_1_3NS 1
105 #define ADF4106_R_ABP_6_0NS 2
106 
107 /* Test Mode Bits */
108 #define ADF4106_R_TMB_OFFSET 18
109 #define ADF4106_R_TMB_MASK 0x1
110 #define ADF4106_R_TMB(x) ((x) & ADF4106_R_TMB_MASK) \
111  << ADF4106_R_TMB_OFFSET
112 #define ADF4106_R_TMB_NORMAL 0
113 /* Lock Detect Precision */
114 #define ADF4106_R_LDP_OFFSET 20
115 #define ADF4106_R_LDP_MASK 0x1
116 #define ADF4106_R_LDP(x) ((x) & ADF4106_R_LDP_MASK) \
117  << ADF4106_R_LDP_OFFSET
118 #define ADF4106_R_LDP_3 0
119 #define ADF4106_R_LDP_5 1
120 
121 /* N Counter Latch */
122 #define ADF4106_N_COUNTER_A_OFFSET 2
123 #define ADF4106_N_COUNTER_A_MASK 0x3F
124 #define ADF4106_N_COUNTER_A(x) ((x) & ADF4106_N_COUNTER_A_MASK) \
125  << ADF4106_N_COUNTER_A_OFFSET
126 #define ADF4106_N_COUNTER_B_OFFSET 8
127 #define ADF4106_N_COUNTER_B_MASK 0x1FFF
128 #define ADF4106_N_COUNTER_B(x) ((x) & ADF4106_N_COUNTER_B_MASK) \
129  << ADF4106_N_COUNTER_B_OFFSET
130 /* Charge Pump Gain Settings */
131 #define ADF4106_N_CP_OFFSET 21
132 #define ADF4106_N_CP_MASK 0x1
133 #define ADF4106_N_CP(x) ((x) & ADF4106_N_CP_MASK) \
134  << ADF4106_N_CP_OFFSET
135 #define ADF4106_N_CP_GAIN_1 0
136 #define ADF4106_N_CP_GAIN_2 1
137 
138 /********* Function and Initialization register offsets and masks ************/
139 /* Counter Reset Bit */
140 #define ADF4106_CR_OFFSET 2
141 #define ADF4106_CR_MASK 0x1ul
142 #define ADF4106_CR(x) ((x) & ADF4106_CR_MASK) \
143  << ADF4106_CR_OFFSET
144 /* Power Down Bit 1 */
145 #define ADF4106_PD1_OFFSET 3
146 #define ADF4106_PD1_MASK 0x1
147 #define ADF4106_PD1(x) ((x) & ADF4106_PD1_MASK) \
148  << ADF4106_PD1_OFFSET
149 /* Muxout Control */
150 #define ADF4106_MUXOUT_OFFSET 4
151 #define ADF4106_MUXOUT_MASK 0x7
152 #define ADF4106_MUXOUT(x) ((x) & ADF4106_MUXOUT_MASK) \
153  << ADF4106_MUXOUT_OFFSET
154 /* Phase Detector Polarity */
155 #define ADF4106_PDPOL_OFFSET 7
156 #define ADF4106_PDPOL_MASK 0x1
157 #define ADF4106_PDPOL(x) ((x) & ADF4106_PDPOL_MASK) \
158  << ADF4106_PDPOL_OFFSET
159 /* Charge Pump Output*/
160 #define ADF4106_CP_OFFSET 8
161 #define ADF4106_CP_MASK 0x1
162 #define ADF4106_CP(x) ((x) & ADF4106_CP_MASK) \
163  << ADF4106_CP_OFFSET
164 /* Fast-lock Mode */
165 #define ADF4106_FASTLOCK_OFFSET 9
166 #define ADF4106_FASTLOCK_MASK 0x3
167 #define ADF4106_FASTLOCK(x) ((x) & ADF4106_FASTLOCK_MASK) \
168  << ADF4106_FASTLOCK_OFFSET
169 /* Timer Counter Control */
170 #define ADF4106_TCC_OFFSET 11
171 #define ADF4106_TCC_MASK 0xF
172 #define ADF4106_TCC(x) ((x) & ADF4106_TCC_MASK) \
173  << ADF4106_TCC_OFFSET
174 /* Current Setting Position */
175 #define ADF4106_CS1_OFFSET 15
176 #define ADF4106_CS1_MASK 0x7
177 #define ADF4106_CS1(x) ((x) << ADF4106_CS1_OFFSET)
178 #define ADF4106_CS2_OFFSET 18
179 #define ADF4106_CS2_MASK 0x7
180 #define ADF4106_CS2(x) ((x) << ADF4106_CS2_OFFSET)
181 
182 /* Synchronous or asynchronous power down*/
183 #define ADF4106_PD2_OFFSET 21
184 #define ADF4106_PD2_MASK 0x1
185 #define ADF4106_PD2(x) ((x) & ADF4106_PD2_MASK) \
186  << ADF4106_PD2_OFFSET
187 /* Prescaler value */
188 #define ADF4106_PS_OFFSET 22
189 #define ADF4106_PS_MASK 0x3
190 #define ADF4106_PS(x) ((x) & ADF4106_PS_MASK) \
191  << ADF4106_PS_OFFSET
192 
193 /* Counter Reset Bit Definition */
194 #define ADF4106_CR_NORMAL 0
195 #define ADF4106_CR_RESET 1
196 /* Power Down Bit 1 Definition */
197 #define ADF4106_PD1_NORMAL 0
198 #define ADF4106_PD1_POWER_DOWN 1
199 /* Muxout Control Definition */
200 #define ADF4106_MUXOUT_3STATE 0
201 #define ADF4106_MUXOUT_DLOCK_DETECT 1
202 #define ADF4106_MUXOUT_NDIV_OUTPUT 2
203 #define ADF4106_MUXOUT_AVDD 3
204 #define ADF4106_MUXOUT_RDIV_OUTPUT 4
205 #define ADF4106_MUXOUT_NCH_OPENDRAIN 5
206 #define ADF4106_MUXOUT_SERIAL_OUTPUT 6
207 #define ADF4106_MUXOUT_DGND 7
208 /* Phase Detector Polarity Definition */
209 #define ADF4106_PDPOL_NEGATIVE 0
210 #define ADF4106_PDPOL_POSITIVE 1
211 /* Charge Pump Output Definition */
212 #define ADF4106_CP_NORMAL 0
213 #define ADF4106_CP_THREE_STATE 1
214 /* Fast-lock Mode Definition */
215 #define ADF4106_FASTLOCK_DISABLE 0
216 #define ADF4106_FASTLOCK_MODE1 1
217 #define ADF4106_FASTLOCK_MODE2 3
218 /* Timer Counter Control Definition */
219 #define ADF4106_TCC_3 0
220 #define ADF4106_TCC_7 1
221 #define ADF4106_TCC_11 2
222 #define ADF4106_TCC_15 3
223 #define ADF4106_TCC_19 4
224 #define ADF4106_TCC_23 5
225 #define ADF4106_TCC_27 6
226 #define ADF4106_TCC_31 7
227 #define ADF4106_TCC_35 8
228 #define ADF4106_TCC_39 9
229 #define ADF4106_TCC_43 10
230 #define ADF4106_TCC_47 11
231 #define ADF4106_TCC_51 12
232 #define ADF4106_TCC_55 13
233 #define ADF4106_TCC_59 14
234 #define ADF4106_TCC_63 15
235 /* Current Settings Definitions */
236 #define ADF4106_CS_0_62 0
237 #define ADF4106_CS_1_25 1
238 #define ADF4106_CS_1_87 2
239 #define ADF4106_CS_2_5 3
240 #define ADF4106_CS_3_12 4
241 #define ADF4106_CS_3_75 5
242 #define ADF4106_CS_4_37 6
243 #define ADF4106_CS_5_0 7
244 /* Synchronous or asynchronous power down Definition */
245 #define ADF4106_ASYNC_PWD 0
246 #define ADF4106_SYNC_PWD 1
247 /* Prescaler value Definition */
248 #define ADF4106_PS_8_9 0
249 #define ADF4106_PS_16_17 1
250 #define ADF4106_PS_32_33 2
251 #define ADF4106_PS_64_65 3
252 
253 /* Default prescaler for ADF4001 and ADF4002 */
254 #define ADF4106_PRESCALE(x) (8 << (x))
255 
256 /*****************************************************************************/
257 /************************** Types Declarations *******************************/
258 /*****************************************************************************/
259 
267 
269  uint32_t ref_in;
270 
272  uint32_t pfd_max;
273 
275  uint16_t ref_counter : 14;
280  uint8_t anti_backlash_width : 2;
282  uint8_t test_mode_bits : 1;
287 
288  /* N Latch */
290  uint8_t a_n_counter : 6;
292  uint16_t b_n_counter : 13;
294  uint8_t cp_gain : 1;
295 
296  /* Functional/Initialization latch */
298  uint8_t counter_reset : 1;
300  uint8_t power_down1 : 1;
302  uint8_t muxout_control : 3;
304  uint8_t phase_detector_pol : 1;
306  uint8_t cp_type : 1;
308  uint8_t fast_lock_mode : 2;
316  uint8_t current_setting1 : 3;
320  uint8_t current_setting2 : 3;
322  uint8_t power_down2 : 1;
324  uint8_t prescaler_value : 2;
325 
326 };
327 
328 /* Supported devices */
333 };
334 
335 /* Initialization methods */
340 };
341 
347 };
348 
349 struct adf4106_dev {
350  /* SPI */
352  /* GPIO */
357  /* Device Settings */
361  /* Internal buffers for each latch */
362  uint32_t r_latch;
363  uint32_t n_latch;
364  uint32_t f_latch;
365  uint32_t i_latch;
366 };
367 
369  /* SPI */
371  /* GPIO */
376  /* Device Settings */
380 };
381 
382 /*****************************************************************************/
383 /* Functions Prototypes */
384 /*****************************************************************************/
385 /* Initialize the communication with the device */
386 int8_t adf4106_init(struct adf4106_dev **device,
388 
389 /* Free the resources allocated by adf4106_init(). */
390 int32_t adf4106_remove(struct adf4106_dev *dev);
391 
392 /* Update register function */
393 void adf4106_update_latch(struct adf4106_dev *dev,
394  uint32_t latch_data);
395 
396 /* Return the value of a desired latch */
397 uint32_t adf4106_read_latch(struct adf4106_dev *dev,
398  uint8_t latch_type);
399 
400 /* PLL initialization functions */
401 void adf4106_init_latch_method(struct adf4106_dev *dev);
402 void adf4106_init_cepin_method(struct adf4106_dev *dev);
404 
405 /* Set the frequency to a desired value */
406 uint64_t adf4106_set_frequency(struct adf4106_dev *dev,
407  uint64_t frequency);
408 
409 #endif // __ADF4106_H__
ADF4106_N_CP
#define ADF4106_N_CP(x)
Definition: adf4106.h:133
adf4106_settings_t::test_mode_bits
uint8_t test_mode_bits
Definition: adf4106.h:282
ADF4106_CE_HIGH
#define ADF4106_CE_HIGH
Definition: adf4106.h:67
adf4106_dev
Definition: adf4106.h:349
ADF4106_PS_OFFSET
#define ADF4106_PS_OFFSET
Definition: adf4106.h:188
adf4106_init_param::gpio_le
struct no_os_gpio_init_param gpio_le
Definition: adf4106.h:372
adf4106.h
Header file of ADF4106 driver. This driver supporting the following devices : ADF4001,...
no_os_gpio_init_param
Structure holding the parameters for GPIO initialization.
Definition: no_os_gpio.h:85
adf4106_init_param::gpio_le2
struct no_os_gpio_init_param gpio_le2
Definition: adf4106.h:374
adf4106_settings_t::timer_counter_control
uint8_t timer_counter_control
Definition: adf4106.h:312
ADF4106_CS1
#define ADF4106_CS1(x)
Definition: adf4106.h:177
ADF4106_R_TMB
#define ADF4106_R_TMB(x)
Definition: adf4106.h:110
adf4106_settings_t::pfd_max
uint32_t pfd_max
Definition: adf4106.h:272
ADF4106_CS2
#define ADF4106_CS2(x)
Definition: adf4106.h:180
adf4106_init_param::gpio_ce2
struct no_os_gpio_init_param gpio_ce2
Definition: adf4106.h:375
no_os_spi_write_and_read
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:82
ID_ADF4106
@ ID_ADF4106
Definition: adf4106.h:332
ADF4106_CTRL_N_COUNTER
#define ADF4106_CTRL_N_COUNTER
Definition: adf4106.h:88
ADF4106_CR
#define ADF4106_CR(x)
Definition: adf4106.h:142
no_os_spi.h
Header file of SPI Interface.
adf4106_settings_t::ref_in
uint32_t ref_in
Definition: adf4106.h:269
adf4106_set_frequency
uint64_t adf4106_set_frequency(struct adf4106_dev *dev, uint64_t frequency)
Sets the output frequency.
Definition: adf4106.c:418
adf4106_dev::gpio_ce2
struct no_os_gpio_desc * gpio_ce2
Definition: adf4106.h:356
ADF4106_CTRL_INIT_LATCH
#define ADF4106_CTRL_INIT_LATCH
Definition: adf4106.h:90
adf4106_remove
int32_t adf4106_remove(struct adf4106_dev *dev)
Free the resources allocated by adf4106_init().
Definition: adf4106.c:162
adf4106_dev::adf4106_st
struct adf4106_settings_t adf4106_st
Definition: adf4106.h:359
adf4106_init
int8_t adf4106_init(struct adf4106_dev **device, struct adf4106_init_param init_param)
Initialize SPI and Initial Values for ADF4106 Board.
Definition: adf4106.c:96
adf4106_dev::r_latch
uint32_t r_latch
Definition: adf4106.h:362
chip_info
const struct adf4106_chip_info chip_info[]
Definition: adf4106.c:62
FREQ_5_2_GHZ
#define FREQ_5_2_GHZ
Definition: adf4106.c:56
ADF4106_LE_LOW
#define ADF4106_LE_LOW
Definition: adf4106.h:58
INIT_LATCH
@ INIT_LATCH
Definition: adf4106.h:337
no_os_delay.h
Header file of Delay functions.
adf4106_dev::f_latch
uint32_t f_latch
Definition: adf4106.h:364
adf4106_tune_rcounter
uint16_t adf4106_tune_rcounter(struct adf4106_dev *dev, uint16_t r_counter)
Increases the R counter value until the ADF4106_PDF_MAX_FREQ is greater than PFD frequency.
Definition: adf4106.c:397
ADF4106_PDPOL
#define ADF4106_PDPOL(x)
Definition: adf4106.h:157
adf4106_dev::gpio_ce
struct no_os_gpio_desc * gpio_ce
Definition: adf4106.h:354
device
Definition: ad9361_util.h:75
adf4106_init
int8_t adf4106_init(struct adf4106_dev **device, struct adf4106_init_param init_param)
Initialize SPI and Initial Values for ADF4106 Board.
Definition: adf4106.c:96
adf4106_settings_t::fast_lock_mode
uint8_t fast_lock_mode
Definition: adf4106.h:308
adf4106_settings_t::phase_detector_pol
uint8_t phase_detector_pol
Definition: adf4106.h:304
ADF4106_R_ABP
#define ADF4106_R_ABP(x)
Definition: adf4106.h:101
DATA_MASK_MID8
#define DATA_MASK_MID8
Definition: adf4106.c:49
ADF4106_CTRL_MASK
#define ADF4106_CTRL_MASK
Definition: adf4106.h:85
adf4106_set_frequency
uint64_t adf4106_set_frequency(struct adf4106_dev *dev, uint64_t frequency)
Sets the output frequency.
Definition: adf4106.c:418
ADF4106_R_COUNTER_MASK
#define ADF4106_R_COUNTER_MASK
Definition: adf4106.h:95
ADF4106_CTRL_FUNCTION_LATCH
#define ADF4106_CTRL_FUNCTION_LATCH
Definition: adf4106.h:89
adf4106_init_param::adf4106_st
struct adf4106_settings_t adf4106_st
Definition: adf4106.h:379
ADF4106_TCC
#define ADF4106_TCC(x)
Definition: adf4106.h:172
ADF4106_N_COUNTER_A
#define ADF4106_N_COUNTER_A(x)
Definition: adf4106.h:124
ADF4106_R_COUNTER
#define ADF4106_R_COUNTER(x)
Definition: adf4106.h:96
adf4106_settings_t::lock_detect_precision
uint8_t lock_detect_precision
Definition: adf4106.h:286
adf4106_init_counte_reset_method
void adf4106_init_counte_reset_method(struct adf4106_dev *dev)
Counter reset method.
Definition: adf4106.c:313
adf4106_settings_t::a_n_counter
uint8_t a_n_counter
Definition: adf4106.h:290
ADF4106_CE_OUT
#define ADF4106_CE_OUT
Definition: adf4106.h:63
no_os_mdelay
void no_os_mdelay(uint32_t msecs)
Wait until msecs milliseconds passed.
Definition: delay.c:130
ADF4106_MUXOUT
#define ADF4106_MUXOUT(x)
Definition: adf4106.h:152
adf4106_settings_t::current_setting2
uint8_t current_setting2
Definition: adf4106.h:320
ADF4106_R_LDP
#define ADF4106_R_LDP(x)
Definition: adf4106.h:116
adf4106_dev::i_latch
uint32_t i_latch
Definition: adf4106.h:365
adf4106_settings_t::anti_backlash_width
uint8_t anti_backlash_width
Definition: adf4106.h:280
ID_ADF4002
@ ID_ADF4002
Definition: adf4106.h:331
adf4106_settings_t::power_down2
uint8_t power_down2
Definition: adf4106.h:322
adf4106_init_cepin_method
void adf4106_init_cepin_method(struct adf4106_dev *dev)
CE Pin method.
Definition: adf4106.c:271
adf4106_init_cepin_method
void adf4106_init_cepin_method(struct adf4106_dev *dev)
CE Pin method.
Definition: adf4106.c:271
adf4106_chip_info::vco_max_frequency
uint64_t vco_max_frequency
Definition: adf4106.h:343
ADF4106_CR_RESET
#define ADF4106_CR_RESET
Definition: adf4106.h:195
adf4106_chip_info
Definition: adf4106.h:342
adf4106_init_t
adf4106_init_t
Definition: adf4106.h:336
ADF4106_PRESCALE
#define ADF4106_PRESCALE(x)
Definition: adf4106.h:254
ADF4106_PS_32_33
#define ADF4106_PS_32_33
Definition: adf4106.h:250
ADF4106_PS_16_17
#define ADF4106_PS_16_17
Definition: adf4106.h:249
adf4106_init_param::this_device
enum adf4106_type_t this_device
Definition: adf4106.h:377
DATA_OFFSET_LSB8
#define DATA_OFFSET_LSB8
Definition: adf4106.c:52
INIT_COUNTER_RESET
@ INIT_COUNTER_RESET
Definition: adf4106.h:339
adf4106_update_latch
void adf4106_update_latch(struct adf4106_dev *dev, uint32_t latch_data)
Update one of the latch via the SPI interface.
Definition: adf4106.c:186
ADF4106_CTRL_R_COUNTER
#define ADF4106_CTRL_R_COUNTER
Definition: adf4106.h:87
ADF4106_CE_LOW
#define ADF4106_CE_LOW
Definition: adf4106.h:65
ADF4106_N_COUNTER_B_MASK
#define ADF4106_N_COUNTER_B_MASK
Definition: adf4106.h:127
adf4106_dev::this_device
enum adf4106_type_t this_device
Definition: adf4106.h:360
adf4106_init_param
Definition: adf4106.h:368
no_os_gpio_remove
int32_t no_os_gpio_remove(struct no_os_gpio_desc *desc)
Free the resources allocated by no_os_gpio_get().
Definition: no_os_gpio.c:95
no_os_spi_desc
Structure holding SPI descriptor.
Definition: no_os_spi.h:132
adf4106_update_latch
void adf4106_update_latch(struct adf4106_dev *dev, uint32_t latch_data)
Update one of the latch via the SPI interface.
Definition: adf4106.c:186
adf4106_settings_t::power_down1
uint8_t power_down1
Definition: adf4106.h:300
adf4106_dev::chip_info
struct adf4106_chip_info chip_info
Definition: adf4106.h:358
no_os_gpio_desc
Structure holding the GPIO descriptor.
Definition: no_os_gpio.h:102
DATA_OFFSET_MSB8
#define DATA_OFFSET_MSB8
Definition: adf4106.c:48
adf4106_settings_t::cp_gain
uint8_t cp_gain
Definition: adf4106.h:294
adf4106_settings_t::counter_reset
uint8_t counter_reset
Definition: adf4106.h:298
adf4106_settings_t::ref_counter
uint16_t ref_counter
Definition: adf4106.h:275
adf4106_dev::spi_desc
no_os_spi_desc * spi_desc
Definition: adf4106.h:351
ADF4106_CR_NORMAL
#define ADF4106_CR_NORMAL
Definition: adf4106.h:194
adf4106_dev::gpio_le
struct no_os_gpio_desc * gpio_le
Definition: adf4106.h:353
no_os_gpio_get
int32_t no_os_gpio_get(struct no_os_gpio_desc **desc, const struct no_os_gpio_init_param *param)
Obtain the GPIO decriptor.
Definition: no_os_gpio.c:55
ADF4106_FASTLOCK
#define ADF4106_FASTLOCK(x)
Definition: adf4106.h:167
ID_ADF4001
@ ID_ADF4001
Definition: adf4106.h:330
ADF4106_CP
#define ADF4106_CP(x)
Definition: adf4106.h:162
ADF4106_PD2
#define ADF4106_PD2(x)
Definition: adf4106.h:185
ADF4106_LE_OUT
#define ADF4106_LE_OUT
Definition: adf4106.h:56
adf4106_init_counte_reset_method
void adf4106_init_counte_reset_method(struct adf4106_dev *dev)
Counter reset method.
Definition: adf4106.c:313
adf4106_chip_info::pfd_min_frequency
uint32_t pfd_min_frequency
Definition: adf4106.h:346
DATA_MASK_LSB8
#define DATA_MASK_LSB8
Definition: adf4106.c:51
ADF4106_N_COUNTER_B
#define ADF4106_N_COUNTER_B(x)
Definition: adf4106.h:128
ADF4106_PS_8_9
#define ADF4106_PS_8_9
Definition: adf4106.h:248
init_param
struct ad7616_init_param init_param
Definition: ad7616_sdz.c:96
ADF4106_PD1
#define ADF4106_PD1(x)
Definition: adf4106.h:147
adf4106_init_param::init_method
enum adf4106_init_t init_method
Definition: adf4106.h:378
adf4106_settings_t::b_n_counter
uint16_t b_n_counter
Definition: adf4106.h:292
adf4106_settings_t::cp_type
uint8_t cp_type
Definition: adf4106.h:306
adf4106_dev::n_latch
uint32_t n_latch
Definition: adf4106.h:363
adf4106_settings_t::prescaler_value
uint8_t prescaler_value
Definition: adf4106.h:324
ADF4106_N_COUNTER_A_MASK
#define ADF4106_N_COUNTER_A_MASK
Definition: adf4106.h:123
adf4106_read_latch
uint32_t adf4106_read_latch(struct adf4106_dev *dev, uint8_t latch_type)
Return the value of a desired latch.
Definition: adf4106.c:367
adf4106_init_param::spi_init
no_os_spi_init_param spi_init
Definition: adf4106.h:370
no_os_spi_remove
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:70
adf4106_init_latch_method
void adf4106_init_latch_method(struct adf4106_dev *dev)
Initialization latch method.
Definition: adf4106.c:230
no_os_gpio.h
Header file of GPIO Interface.
adf4106_read_latch
uint32_t adf4106_read_latch(struct adf4106_dev *dev, uint8_t latch_type)
Return the value of a desired latch.
Definition: adf4106.c:367
no_os_spi_init
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:51
adf4106_settings_t
store the value of all the latch and the input reference frequency
Definition: adf4106.h:266
ADF4106_CR_MASK
#define ADF4106_CR_MASK
Definition: adf4106.h:141
INIT_CEPIN
@ INIT_CEPIN
Definition: adf4106.h:338
adf4106_dev::gpio_le2
struct no_os_gpio_desc * gpio_le2
Definition: adf4106.h:355
FREQ_2_4_GHZ
#define FREQ_2_4_GHZ
Definition: adf4106.c:55
adf4106_init_param::gpio_ce
struct no_os_gpio_init_param gpio_ce
Definition: adf4106.h:373
DATA_MASK_MSB8
#define DATA_MASK_MSB8
Definition: adf4106.c:47
DATA_OFFSET_MID8
#define DATA_OFFSET_MID8
Definition: adf4106.c:50
adf4106_chip_info::vco_min_frequency
uint32_t vco_min_frequency
Definition: adf4106.h:345
adf4106_type_t
adf4106_type_t
Definition: adf4106.h:329
adf4106_chip_info::pfd_max_frequency
uint32_t pfd_max_frequency
Definition: adf4106.h:344
adf4106_remove
int32_t adf4106_remove(struct adf4106_dev *dev)
Free the resources allocated by adf4106_init().
Definition: adf4106.c:162
adf4106_settings_t::muxout_control
uint8_t muxout_control
Definition: adf4106.h:302
ADF4106_LE_HIGH
#define ADF4106_LE_HIGH
Definition: adf4106.h:60
adf4106_init_latch_method
void adf4106_init_latch_method(struct adf4106_dev *dev)
Initialization latch method.
Definition: adf4106.c:230
no_os_spi_init_param
Structure holding the parameters for SPI initialization.
Definition: no_os_spi.h:112
adf4106_settings_t::current_setting1
uint8_t current_setting1
Definition: adf4106.h:316