no-OS
Loading...
Searching...
No Matches
adf4371.h File Reference

Header file of ADF4371 Driver. More...

#include <stdint.h>
#include "no_os_spi.h"
Include dependency graph for adf4371.h:

Classes

struct  adf4371_channel_config
 
struct  adf4371_cp_settings
 
struct  adf4371_chan_spec
 
struct  adf4371_dev
 
struct  adf4371_init_param
 

Functions

int32_t adf4371_init (struct adf4371_dev **device, const struct adf4371_init_param *init_param)
 
int32_t adf4371_remove (struct adf4371_dev *device)
 
int32_t adf4371_clk_recalc_rate_chan (struct adf4371_dev *dev, uint32_t chan, uint64_t *rate)
 
int32_t adf4371_clk_round_rate_dev (struct adf4371_dev *dev, uint64_t rate, uint64_t *rounded_rate)
 
int32_t adf4371_clk_set_rate_chan (struct adf4371_dev *dev, uint32_t chan, uint64_t rate)
 

Variables

const struct no_os_clk_platform_ops adf4371_clk_ops
 adf4371 clock ops
 

Detailed Description

Header file of ADF4371 Driver.

Author
DBogdan (drago.nosp@m.s.bo.nosp@m.gdan@.nosp@m.anal.nosp@m.og.co.nosp@m.m)

Copyright 2020(c) Analog Devices, Inc.

SPDX-License-Identifier: BSD-3-Clause

Function Documentation

◆ adf4371_clk_recalc_rate_chan()

int32_t adf4371_clk_recalc_rate_chan ( struct adf4371_dev * dev,
uint32_t chan,
uint64_t * rate )

Recalculate rate corresponding to a channel.

Parameters
dev- The device structure.
chan- Channel number.
rate- Channel rate.
Returns
0 in case of success, negative error code otherwise.

◆ adf4371_clk_round_rate_dev()

int32_t adf4371_clk_round_rate_dev ( struct adf4371_dev * dev,
uint64_t rate,
uint64_t * rounded_rate )

Calculate closest possible rate

Parameters
dev- The device structure
rate- The desired rate.
rounded_rate- The closest possible rate of desired rate.
Returns
0 in case of success, negative error code otherwise.

◆ adf4371_clk_set_rate_chan()

int32_t adf4371_clk_set_rate_chan ( struct adf4371_dev * dev,
uint32_t chan,
uint64_t rate )

Set channel rate.

Parameters
dev- The device structure.
chan- Channel number.
rate- Channel rate.
Returns
0 in case of success, negative error code otherwise.

◆ adf4371_init()

int32_t adf4371_init ( struct adf4371_dev ** device,
const struct adf4371_init_param * init_param )

Initialize the device.

Parameters
device- The device structure.
init_param- The structure that contains the device initial parameters.
Returns
0 in case of success, negative error code otherwise.

◆ adf4371_remove()

int32_t adf4371_remove ( struct adf4371_dev * device)

Remove the device - release resources.

Parameters
device- The device structure.
Returns
0 in case of success, negative error code otherwise.

Variable Documentation

◆ adf4371_clk_ops

const struct no_os_clk_platform_ops adf4371_clk_ops
extern

adf4371 clock ops