sysmon
Xilinx SDK Drivers API Documentation
xsysmon.h File Reference

Data Structures

struct  XSysMon_Config
 This typedef contains configuration information for the System Monitor/ADC device. More...
 
struct  XSysMon
 The driver's instance data. More...
 

Macros

#define XSysMon_IsEventSamplingModeSet(InstancePtr)
 This macro checks if the SysMonitor/ADC device is in Event Sampling mode. More...
 
#define XSysMon_IsDrpBusy(InstancePtr)
 This macro checks if the Dynamic Reconfiguration Port (DRP) transaction from the JTAG is in progress. More...
 
#define XSysMon_IsDrpLocked(InstancePtr)
 This macro checks if the Dynamic Reconfiguration Port (DRP) is locked by the JTAG. More...
 
#define XSysMon_RawToTemperature(AdcData)   ((((float)(AdcData)/65536.0f)/0.00198421639f ) - 273.15f)
 This macro converts System Monitor/ADC Raw Data to Temperature(centigrades). More...
 
#define XSysMon_RawToVoltage(AdcData)   ((((float)(AdcData))* (3.0f))/65536.0f)
 This macro converts System Monitor/ADC Raw Data to Voltage(volts). More...
 
#define XSysMon_TemperatureToRaw(Temperature)   ((int)(((Temperature) + 273.15f)*65536.0f*0.00198421639f))
 This macro converts Temperature in centigrades to System Monitor/ADC Raw Data. More...
 
#define XSysMon_VoltageToRaw(Voltage)   ((int)((Voltage)*65536.0f/3.0f))
 This macro converts Voltage in Volts to System Monitor/ADC Raw Data. More...
 
Indexes for the different channels.
#define XSM_CH_TEMP   0x0
 On Chip Temperature. More...
 
#define XSM_CH_VCCINT   0x1
 VCCINT. More...
 
#define XSM_CH_VCCAUX   0x2
 VCCAUX. More...
 
#define XSM_CH_VPVN   0x3
 VP/VN Dedicated analog inputs. More...
 
#define XSM_CH_VREFP   0x4
 VREFP. More...
 
#define XSM_CH_VREFN   0x5
 VREFN. More...
 
#define XSM_CH_VBRAM   0x6
 VBRAM - 7 Series and Zynq. More...
 
#define XSM_CH_SUPPLY_CALIB   0x07
 Supply Calib Data Reg. More...
 
#define XSM_CH_ADC_CALIB   0x08
 ADC Offset Channel Reg. More...
 
#define XSM_CH_GAINERR_CALIB   0x09
 Gain Error Channel Reg. More...
 
#define XSM_CH_VCCPINT   0x0D
 On-chip PS VCCPINT Channel, Zynq. More...
 
#define XSM_CH_VCCPAUX   0x0E
 On-chip PS VCCPAUX Channel, Zynq. More...
 
#define XSM_CH_VCCPDRO   0x0F
 On-chip PS VCCPDRO Channel, Zynq. More...
 
#define XSM_CH_AUX_MIN   16
 Channel number for 1st Aux Channel. More...
 
#define XSM_CH_AUX_MAX   31
 Channel number for Last Aux channel. More...
 
#define XSM_CH_VUSR0   32
 VUSER0 Supply - UltraScale. More...
 
#define XSM_CH_VUSR1   33
 VUSER1 Supply - UltraScale. More...
 
#define XSM_CH_VUSR2   34
 VUSER2 Supply - UltraScale. More...
 
#define XSM_CH_VUSR3   35
 VUSER3 Supply - UltraScale. More...
 
Indexes for reading the Calibration Coefficient Data.
#define XSM_CALIB_SUPPLY_OFFSET_COEFF   0
 Supply Offset Calib Coefficient. More...
 
#define XSM_CALIB_ADC_OFFSET_COEFF   1
 ADC Offset Calib Coefficient. More...
 
#define XSM_CALIB_GAIN_ERROR_COEFF   2
 Gain Error Calib Coefficient. More...
 
Indexes for reading the Minimum/Maximum Measurement Data.
#define XSM_MAX_TEMP   0
 Maximum Temperature Data. More...
 
#define XSM_MAX_VCCINT   1
 Maximum VCCINT Data. More...
 
#define XSM_MAX_VCCAUX   2
 Maximum VCCAUX Data. More...
 
#define XSM_MAX_VCCBRAM   3
 Maximum VCCBRAM Data, 7 Series/Zynq. More...
 
#define XSM_MIN_TEMP   4
 Minimum Temperature Data. More...
 
#define XSM_MIN_VCCINT   5
 Minimum VCCINT Data. More...
 
#define XSM_MIN_VCCAUX   6
 Minimum VCCAUX Data. More...
 
#define XSM_MIN_VCCBRAM   7
 Minimum VCCBRAM Data, 7 Series/Zynq. More...
 
#define XSM_MAX_VCCPINT   8
 Maximum VCCPINT Data, Zynq. More...
 
#define XSM_MAX_VCCPAUX   9
 Maximum VCCPAUX Data, Zynq. More...
 
#define XSM_MAX_VCCPDRO   0xA
 Maximum VCCPDRO Data, Zynq. More...
 
#define XSM_MIN_VCCPINT   0xC
 Minimum VCCPINT Data, Zynq. More...
 
#define XSM_MIN_VCCPAUX   0xD
 Minimum VCCPAUX Data, Zynq. More...
 
#define XSM_MIN_VCCPDRO   0xE
 Minimum VCCPDRO Data, Zynq. More...
 
#define XSM_MAX_VUSR0   0x80
 Maximum VUSR0 Data, Ultrascale. More...
 
#define XSM_MAX_VUSR1   0x81
 Maximum VUSR1 Data, Ultrascale. More...
 
#define XSM_MAX_VUSR2   0x82
 Maximum VUSR2 Data, Ultrascale. More...
 
#define XSM_MAX_VUSR3   0x83
 Maximum VUSR3 Data, Ultrascale. More...
 
#define XSM_MIN_VUSR0   0x88
 Minimum VUSR0 Data, Ultrascale. More...
 
#define XSM_MIN_VUSR1   0x89
 Minimum VUSR1 Data, Ultrascale. More...
 
#define XSM_MIN_VUSR2   0x8A
 Minimum VUSR2 Data, Ultrascale. More...
 
#define XSM_MIN_VUSR3   0x8B
 Minimum VUSR3 Data, Ultrascale. More...
 
Alarm Threshold(Limit) Register (ATR) indexes.
#define XSM_ATR_TEMP_UPPER   0
 High user Temperature. More...
 
#define XSM_ATR_VCCINT_UPPER   1
 VCCINT high voltage limit. More...
 
#define XSM_ATR_VCCAUX_UPPER   2
 VCCAUX high voltage limit. More...
 
#define XSM_ATR_OT_UPPER   3
 Lower Over Temperature limit. More...
 
#define XSM_ATR_TEMP_LOWER   4
 Low user Temperature. More...
 
#define XSM_ATR_VCCINT_LOWER   5
 VCCINT low voltage limit. More...
 
#define XSM_ATR_VCCAUX_LOWER   6
 VCCAUX low voltage limit. More...
 
#define XSM_ATR_OT_LOWER   7
 Lower Over Temperature limit. More...
 
#define XSM_ATR_VBRAM_UPPER   8
 VBRAM high voltage limit. More...
 
#define XSM_ATR_VCCPINT_UPPER   9
 VCCPINT Upper Alarm, Zynq. More...
 
#define XSM_ATR_VCCPAUX_UPPER   0xA
 VCCPAUX Upper Alarm, Zynq. More...
 
#define XSM_ATR_VCCPDRO_UPPER   0xB
 VCCPDRO Upper Alarm, Zynq. More...
 
#define XSM_ATR_VBRAM_LOWER   0xC
 VRBAM Lower Alarm, 7 Series and Zynq. More...
 
#define XSM_ATR_VCCPINT_LOWER   0xD
 VCCPINT Lower Alarm, Zynq. More...
 
#define XSM_ATR_VCCPAUX_LOWER   0xE
 VCCPAUX Lower Alarm, Zynq. More...
 
#define XSM_ATR_VCCPDRO_LOWER   0xF
 VCCPDRO Lower Alarm, Zynq. More...
 
#define XSM_ATR_VUSR0_UPPER   0x10
 VUSER0 Upper Alarm, Ultrascale. More...
 
#define XSM_ATR_VUSR1_UPPER   0x11
 VUSER1 Upper Alarm, Ultrascale. More...
 
#define XSM_ATR_VUSR2_UPPER   0x12
 VUSER2 Upper Alarm, Ultrascale. More...
 
#define XSM_ATR_VUSR3_UPPER   0x13
 VUSER3 Upper Alarm, Ultrascale. More...
 
#define XSM_ATR_VUSR0_LOWER   0x18
 VUSER0 Lower Alarm, Ultrascale. More...
 
#define XSM_ATR_VUSR1_LOWER   0x19
 VUSER1 Lower Alarm, Ultrascale. More...
 
#define XSM_ATR_VUSR2_LOWER   0x1A
 VUSER2 Lower Alarm, Ultrascale. More...
 
#define XSM_ATR_VUSR3_LOWER   0x1B
 VUSER3 Lower Alarm, Ultrascale. More...
 
Averaging to be done for the channels.
#define XSM_AVG_0_SAMPLES   0
 No Averaging. More...
 
#define XSM_AVG_16_SAMPLES   1
 Average 16 samples. More...
 
#define XSM_AVG_64_SAMPLES   2
 Average 64 samples. More...
 
#define XSM_AVG_256_SAMPLES   3
 Average 256 samples. More...
 
Channel Sequencer Modes of operation.
#define XSM_SEQ_MODE_SAFE   0
 Default Safe Mode. More...
 
#define XSM_SEQ_MODE_ONEPASS   1
 Onepass through Sequencer. More...
 
#define XSM_SEQ_MODE_CONTINPASS   2
 Continuous Cycling Seqquencer. More...
 
#define XSM_SEQ_MODE_SINGCHAN   3
 Single channel - No Sequencing. More...
 
#define XSM_SEQ_MODE_SIMUL   4
 Simultaneous Cycling Sequencer, 7 Series and Zynq XADC only. More...
 
#define XSM_SEQ_MODE_INDEPENDENT   8
 Independent ADC Sequencer, 7 Series and Zynq XADC only. More...
 

Functions

XSysMon_ConfigXSysMon_LookupConfig (u16 DeviceId)
 Functions in xsysmon_sinit.c. More...
 
int XSysMon_CfgInitialize (XSysMon *InstancePtr, XSysMon_Config *ConfigPtr, UINTPTR EffectiveAddr)
 This function initializes a specific XSysMon device/instance. More...
 
void XSysMon_Reset (XSysMon *InstancePtr)
 This function forces the software reset of the complete SystemMonitor/ADC Hard Macro and the SYSMON ADC Core Logic. More...
 
u32 XSysMon_GetStatus (XSysMon *InstancePtr)
 The functions reads the contents of the Status Register. More...
 
u32 XSysMon_GetAlarmOutputStatus (XSysMon *InstancePtr)
 This function reads the contents of Alarm Output Register. More...
 
void XSysMon_StartAdcConversion (XSysMon *InstancePtr)
 This function starts the ADC conversion in the Single Channel event driven sampling mode. More...
 
void XSysMon_ResetAdc (XSysMon *InstancePtr)
 This function resets the SystemMonitor/ADC Hard Macro in the device. More...
 
u16 XSysMon_GetAdcData (XSysMon *InstancePtr, u8 Channel)
 Get the ADC converted data for the specified channel. More...
 
u16 XSysMon_GetCalibCoefficient (XSysMon *InstancePtr, u8 CoeffType)
 This function gets the calibration coefficient data for the specified parameter. More...
 
u16 XSysMon_GetMinMaxMeasurement (XSysMon *InstancePtr, u8 MeasurementType)
 This function reads the Minimum/Maximum measurement for one of the following parameters : More...
 
void XSysMon_SetAvg (XSysMon *InstancePtr, u8 Average)
 This function sets the number of samples of averaging that is to be done for all the channels in both the single channel mode and sequence mode of operations. More...
 
u8 XSysMon_GetAvg (XSysMon *InstancePtr)
 This function returns the number of samples of averaging configured for all the channels in the Configuration Register 0. More...
 
int XSysMon_SetSingleChParams (XSysMon *InstancePtr, u8 Channel, int IncreaseAcqCycles, int IsEventMode, int IsDifferentialMode)
 The function sets the given parameters in the Configuration Register 0 in the single channel mode. More...
 
void XSysMon_SetAlarmEnables (XSysMon *InstancePtr, u32 AlmEnableMask)
 This function enables the alarm outputs for the specified alarms in the Configuration Registers 1 and 3: More...
 
u32 XSysMon_GetAlarmEnables (XSysMon *InstancePtr)
 This function gets the status of the alarm output enables in the Configuration Register 1. More...
 
void XSysMon_SetCalibEnables (XSysMon *InstancePtr, u16 Calibration)
 This function enables the specified calibration in the Configuration Register 1 : More...
 
u16 XSysMon_GetCalibEnables (XSysMon *InstancePtr)
 This function reads the value of the calibration enables from the Configuration Register 1. More...
 
void XSysMon_SetSequencerMode (XSysMon *InstancePtr, u8 SequencerMode)
 This function sets the specified Channel Sequencer Mode in the Configuration Register 1 : More...
 
u8 XSysMon_GetSequencerMode (XSysMon *InstancePtr)
 This function gets the channel sequencer mode from the Configuration Register 1. More...
 
void XSysMon_SetSequencerEvent (XSysMon *InstancePtr, int IsEventMode)
 The function enables the Event mode or Continuous mode in the sequencer mode. More...
 
void XSysMon_SetExtenalMux (XSysMon *InstancePtr, u8 Channel)
 The function enables the external mux and connects a channel to the mux. More...
 
void XSysMon_SetAdcClkDivisor (XSysMon *InstancePtr, u8 Divisor)
 The function sets the frequency of the ADCCLK by configuring the DCLK to ADCCLK ratio in the Configuration Register #2. More...
 
u8 XSysMon_GetAdcClkDivisor (XSysMon *InstancePtr)
 The function gets the ADCCLK divisor from the Configuration Register 2. More...
 
int XSysMon_SetSeqChEnables (XSysMon *InstancePtr, u64 ChEnableMask)
 This function enables the specified channels in the ADC Channel Selection Sequencer Registers. More...
 
u64 XSysMon_GetSeqChEnables (XSysMon *InstancePtr)
 This function gets the channel enable bits status from the ADC Channel Selection Sequencer Registers. More...
 
int XSysMon_SetSeqAvgEnables (XSysMon *InstancePtr, u64 AvgEnableChMask)
 This function enables the averaging for the specified channels in the ADC Channel Averaging Enable Sequencer Registers. More...
 
u64 XSysMon_GetSeqAvgEnables (XSysMon *InstancePtr)
 This function returns the channels for which the averaging has been enabled in the ADC Channel Averaging Enables Sequencer Registers. More...
 
int XSysMon_SetSeqInputMode (XSysMon *InstancePtr, u32 InputModeChMask)
 This function sets the Analog input mode for the specified channels in the ADC Channel Analog-Input Mode Sequencer Registers. More...
 
u32 XSysMon_GetSeqInputMode (XSysMon *InstancePtr)
 This function gets the Analog input mode for all the channels from the ADC Channel Analog-Input Mode Sequencer Registers. More...
 
int XSysMon_SetSeqAcqTime (XSysMon *InstancePtr, u32 AcqCyclesChMask)
 This function sets the number of Acquisition cycles in the ADC Channel Acquisition Time Sequencer Registers. More...
 
u32 XSysMon_GetSeqAcqTime (XSysMon *InstancePtr)
 This function gets the status of acquisition from the ADC Channel Acquisition Time Sequencer Registers. More...
 
void XSysMon_SetAlarmThreshold (XSysMon *InstancePtr, u8 AlarmThrReg, u16 Value)
 This functions sets the contents of the given Alarm Threshold Register. More...
 
u16 XSysMon_GetAlarmThreshold (XSysMon *InstancePtr, u8 AlarmThrReg)
 This function returns the contents of the specified Alarm Threshold Register. More...
 
void XSysMon_SetOverTemp (XSysMon *InstancePtr, u16 Value)
 This function sets the powerdown temperature for the OverTemp signal in the OT Powerdown register. More...
 
u16 XSysMon_GetOverTemp (XSysMon *InstancePtr)
 This function returns the powerdown temperature of the OverTemp signal in the OT Powerdown register. More...
 
void XSysMon_EnableUserOverTemp (XSysMon *InstancePtr)
 This function enables programming of the powerdown temperature for the OverTemp signal in the OT Powerdown register. More...
 
void XSysMon_DisableUserOverTemp (XSysMon *InstancePtr)
 This function disables programming of the powerdown temperature for the OverTemp signal in the OT Powerdown register. More...
 
void XSysMon_EnableTempUpdate (XSysMon *InstancePtr)
 This function enables the Temperature updation logic so that temperature can be sent over TEMP_OUT port. More...
 
void XSysMon_DisableTempUpdate (XSysMon *InstancePtr)
 This function disables the Temperature updation logic for TEMP_OUT port. More...
 
void XSysMon_SetTempWaitCycles (XSysMon *InstancePtr, u16 WaitCycles)
 This function sets the number of Wait Cycles for Temperature updation logic. More...
 
int XSysMon_SelfTest (XSysMon *InstancePtr)
 Functions in xsysmon_selftest.c. More...
 
void XSysMon_IntrGlobalEnable (XSysMon *InstancePtr)
 Functions in xsysmon_intr.c. More...
 
void XSysMon_IntrGlobalDisable (XSysMon *InstancePtr)
 This function disables the global interrupt in the Global Interrupt Enable Register (GIER) so that the interrupt output from the System Monitor/ADC device is disabled. More...
 
void XSysMon_IntrEnable (XSysMon *InstancePtr, u32 Mask)
 This function enables the specified interrupts in the device. More...
 
void XSysMon_IntrDisable (XSysMon *InstancePtr, u32 Mask)
 This function disables the specified interrupts in the device. More...
 
u32 XSysMon_IntrGetEnabled (XSysMon *InstancePtr)
 This function returns the enabled interrupts read from the Interrupt Enable Register (IPIER). More...
 
u32 XSysMon_IntrGetStatus (XSysMon *InstancePtr)
 This function returns the interrupt status read from Interrupt Status Register(IPISR). More...
 
void XSysMon_IntrClear (XSysMon *InstancePtr, u32 Mask)
 This function clears the specified interrupts in the Interrupt Status Register (IPISR). More...