no-OS
|
AD917X API interface header file. More...
Go to the source code of this file.
Classes | |
struct | ad917x_jesd_link_stat_t |
struct | ad917x_handle_t |
Enumerations | |
enum | ad917x_dds_select_t { AD917X_DDSM = 0, AD917X_DDSC = 1 } |
enum | ad917x_dac_select_t { AD917X_DAC_NONE = 0, AD917X_DAC0 = 1, AD917X_DAC1 = 2 } |
enum | ad917x_channel_select_t { AD917X_CH_NONE = 0, AD917X_CH_0 = NO_OS_BIT(0), AD917X_CH_1 = NO_OS_BIT(1), AD917X_CH_2 = NO_OS_BIT(2), AD917X_CH_3 = NO_OS_BIT(3), AD917X_CH_4 = NO_OS_BIT(4), AD917X_CH_5 = NO_OS_BIT(5) } |
enum | ad917x_jesd_serdes_pll_flg_t { AD917X_PLL_LOCK_STAT = 0x1, AD917X_PLL_REG_RDY = 0x2, AD917X_PLL_CAL_STAT = 0x4, AD917X_PLL_LOSSLOCK = 0x8 } |
Functions | |
int32_t | ad917x_init (ad917x_handle_t *h) |
Initialize AD917X Device This API must be called first before any other API calls. It performs internal API initialization of the memory and API states. If AD917X handle member hw_open is not NULL it shall call the function to which it points. This feature may be used to get and initialize the hardware resources required by the API and the AD917X devices. For example GPIO, SPI etc. More... | |
int32_t | ad917x_deinit (ad917x_handle_t *h) |
De-initialize the AD917X Device. More... | |
int32_t | ad917x_reset (ad917x_handle_t *h, uint8_t hw_reset) |
Reset the AD917X. More... | |
int32_t | ad917x_get_chip_id (ad917x_handle_t *h, adi_chip_id_t *chip_id) |
Get Chip Identification Data. More... | |
int32_t | ad917x_register_write (ad917x_handle_t *h, const uint16_t address, const uint8_t data) |
Perform SPI register write access to AD917X Device. More... | |
int32_t | ad917x_register_read (ad917x_handle_t *h, const uint16_t address, uint8_t *data) |
Perform SPI register read access to AD917X Device. More... | |
int32_t | ad917x_get_revision (ad917x_handle_t *h, uint8_t *rev_major, uint8_t *rev_minor, uint8_t *rev_rc) |
Get API Revision Data. More... | |
int32_t | ad917x_set_dac_pll_config (ad917x_handle_t *h, uint8_t dac_pll_en, uint8_t m_div, uint8_t n_div, uint8_t vco_div) |
Configure the On Chip DAC PLL. More... | |
int32_t | ad917x_set_dac_clk_freq (ad917x_handle_t *h, uint64_t dac_clk_freq_hz) |
Set the DAC CLK Frequency. More... | |
int32_t | ad917x_get_dac_clk_freq (ad917x_handle_t *h, uint64_t *dac_clk_freq_hz) |
Get the DAC CLK Frequency. More... | |
int32_t | ad917x_get_dac_clk_status (ad917x_handle_t *h, uint8_t *pll_lock_stat, uint8_t *dll_lock_stat) |
Get DAC CLK Status. More... | |
int32_t | ad917x_set_clkout_config (ad917x_handle_t *h, uint8_t l_div) |
Set CLKOUT configuration. More... | |
int32_t | ad917x_set_dac_clk (ad917x_handle_t *h, uint64_t dac_clk_freq_hz, uint8_t dac_pll_en, uint64_t ref_clk_freq_hz) |
Configure the DAC Clock Input path based on a the desired dac clock frequency, the applied reference clock and the onchip PLL. More... | |
int32_t | ad917x_jesd_config_datapath (ad917x_handle_t *h, uint8_t dual_en, uint8_t jesd_mode, uint8_t ch_intpl, uint8_t dp_intpl) |
Configure the JESD Datapath for AD917X. More... | |
int32_t | ad917x_jesd_get_cfg_status (ad917x_handle_t *h, uint8_t *cfg_valid) |
Get JESD Configuration Status. More... | |
int32_t | ad917x_jesd_get_cfg_param (ad917x_handle_t *h, jesd_param_t *jesd_param) |
Read back all current JESD parameter settings. More... | |
int32_t | ad917x_jesd_set_sysref_enable (ad917x_handle_t *h, uint8_t en) |
Enable SysRef Input. More... | |
int32_t | ad917x_jesd_get_sysref_enable (ad917x_handle_t *h, uint8_t *en) |
Get the current SYSREF Input. More... | |
int32_t | ad917x_jesd_set_lmfc_delay (ad917x_handle_t *h, jesd_link_t link, uint8_t delay, uint8_t var) |
Set the LMFC Delay and Variance for the JESD Links. More... | |
int32_t | ad917x_jesd_set_syncoutb_enable (ad917x_handle_t *h, jesd_syncoutb_t syncoutb, uint8_t en) |
Enable the SYNCOUTB Output Signal. More... | |
int32_t | ad917x_jesd_set_scrambler_enable (ad917x_handle_t *h, uint8_t en) |
Enable the de-scrambler for the JESD Interface. More... | |
int32_t | ad917x_jesd_set_lane_xbar (ad917x_handle_t *h, uint8_t logical_lane, uint8_t physical_lane) |
Configure the Lane Cross Bar in the JESD datalink layer. More... | |
int32_t | ad917x_jesd_get_lane_xbar (ad917x_handle_t *h, uint8_t *phy_log_map) |
Get current Lane Cross Bar configuration for the JESD datalink layer. More... | |
int32_t | ad917x_jesd_invert_lane (ad917x_handle_t *h, uint8_t logical_lane, uint8_t invert) |
Invert or un-invert logical lanes. More... | |
int32_t | ad917x_jesd_enable_datapath (ad917x_handle_t *h, uint8_t lanes_msk, uint8_t run_cal, uint8_t en) |
Enable the JESD Interface. More... | |
int32_t | ad917x_jesd_get_pll_status (ad917x_handle_t *h, uint8_t *pll_status) |
Get SERDES PLL Status. More... | |
int32_t | ad917x_jesd_enable_link (ad917x_handle_t *h, jesd_link_t link, uint8_t en) |
Enable JESD Link. More... | |
int32_t | ad917x_jesd_get_link_status (ad917x_handle_t *h, jesd_link_t link, ad917x_jesd_link_stat_t *link_status) |
Get JESD Link Status. More... | |
int32_t | ad917x_set_page_idx (ad917x_handle_t *h, const uint32_t dac, const uint32_t channel) |
Select Page. More... | |
int32_t | ad917x_get_page_idx (ad917x_handle_t *h, int32_t *dac, int32_t *channel) |
Get select page index. More... | |
int32_t | ad917x_set_channel_gain (ad917x_handle_t *h, const uint16_t gain) |
Set Channel gain. More... | |
int32_t | ad917x_get_channel_gain (ad917x_handle_t *h, uint16_t *gain) |
Get Channel gain. More... | |
int32_t | ad917x_set_dc_cal_tone_amp (ad917x_handle_t *h, const uint16_t amp) |
Set DC Calibration tone. More... | |
int32_t | ad917x_nco_get_phase_offset (ad917x_handle_t *h, const ad917x_dac_select_t dacs, uint16_t *dacs_po, const ad917x_channel_select_t channels, uint16_t *ch_po) |
Get NCO phase offset. More... | |
int32_t | ad917x_nco_set_phase_offset (ad917x_handle_t *h, const ad917x_dac_select_t dacs, const uint16_t dacs_po, const ad917x_channel_select_t channels, const uint16_t ch_po) |
Set NCO phase offset. More... | |
int32_t | ad917x_nco_set_ftw (ad917x_handle_t *h, const ad917x_dds_select_t nco, const uint64_t ftw, const uint64_t acc_modulus, const uint64_t acc_delta) |
Set FTW, ACC and MOD values. More... | |
int32_t | ad917x_nco_get_ftw (ad917x_handle_t *h, const ad917x_dds_select_t nco, uint64_t *ftw, uint64_t *acc_modulus, uint64_t *acc_delta) |
Get FTW, ACC and MOD values. More... | |
int32_t | ad917x_nco_set (ad917x_handle_t *h, const ad917x_dac_select_t dacs, const ad917x_channel_select_t channels, const int64_t carrier_freq_hz, const uint16_t amplitude, int32_t dc_test_tone_en, int32_t ddsm_cal_dc_input_en) |
Set NCO. More... | |
int32_t | ad917x_nco_enable (ad917x_handle_t *h, const ad917x_dac_select_t dacs, const ad917x_channel_select_t channels) |
NCO Enable. More... | |
int32_t | ad917x_ddsm_cal_dc_input_set (ad917x_handle_t *h, int32_t ddsm_cal_dc_input_en) |
Set Main DAC Cal DC Input. More... | |
int32_t | ad917x_ddsm_cal_dc_input_get (ad917x_handle_t *h, int32_t *ddsm_cal_dc_input_en) |
Get Main DAC Cal DC Input. More... | |
int32_t | ad917x_dc_test_tone_set (ad917x_handle_t *h, int32_t dc_test_tone_en) |
Set DC Test Tone enable status. More... | |
int32_t | ad917x_dc_test_tone_get (ad917x_handle_t *h, int32_t *dc_test_tone_en) |
Get DC Test Tone enable status. More... | |
int32_t | ad917x_nco_channel_freq_get (ad917x_handle_t *h, ad917x_channel_select_t channel, int64_t *carrier_freq_hz) |
Get Channel NCO frequency. More... | |
int32_t | ad917x_nco_main_freq_get (ad917x_handle_t *h, ad917x_dac_select_t dac, int64_t *carrier_freq_hz) |
Get Main DAC NCO frequency. More... | |
AD917X API interface header file.
This file contains all the publicly exposed methods and data structures to interface with the AD917X API.
Release 1.1.X
Copyright(c) 2017 Analog Devices, Inc. All Rights Reserved. This software is proprietary to Analog Devices, Inc. and its licensors. By using this software you agree to the terms of the associated Analog Devices Software License Agreement.