sysmonpsv
Vitis Drivers API Documentation
xsysmonpsv.h File Reference

Macros

#define XSYSMONPSV_H_
 < prevent circular inclusions More...
 
#define XSysMonPsv_GetAlarmMask(InstancePtr, Supply)   Mask = 1U << (InstancePtr->Supply_List[Supply] / 32U)
 This macro returns the XSYSMONPSV_NEW_ALARMn_MASK for a configured supply. More...
 

Enumerations

enum  XSysMonPsv_Threshold { XSYSMONPSV_TH_LOWER, XSYSMONPSV_TH_UPPER }
 This typedef defines Threshold types. More...
 
enum  XSysMonPsv_Val {
  XSYSMONPSV_VAL, XSYSMONPSV_VAL_MIN, XSYSMONPSV_VAL_MAX, XSYSMONPSV_VAL_VREF_MIN,
  XSYSMONPSV_VAL_VREF_MAX
}
 This typedef defines value types for voltage readings. More...
 
enum  XSysMonPsv_VoltageScale { XSYSMONPSV_1V_UNIPOLAR, XSYSMONPSV_2V_UNIPOLAR, XSYSMONPSV_4V_UNIPOLAR, XSYSMONPSV_1V_BIPOLAR }
 This typedef defines types of supply values. More...
 

Functions

s64 XSysMonPsv_CfgInitialize (XSysMonPsv *InstancePtr, XSysMonPsv_Config *CfgPtr)
 This function initializes XSysMonPsv device/instance. More...
 
void XSysMonPsv_SystemReset (XSysMonPsv *InstancePtr)
 This function resets the SystemMonitor. More...
 
void XSysMonPsv_EnRegGate (XSysMonPsv *InstancePtr, u8 Enable)
 This function Gates the register outputs. More...
 
void XSysMonPsv_SetPMBusAddress (XSysMonPsv *InstancePtr, u8 Address)
 This function sets the PMBus address for the System Monitor. More...
 
void XSysMonPsv_PMBusEnable (XSysMonPsv *InstancePtr, u8 Enable)
 This function enables/disbles the PMBus on the System Monitor. More...
 
void XSysMonPsv_PMBusEnableCmd (XSysMonPsv *InstancePtr, u8 Enable)
 This function restricts or de-restrict all PMBs commands. More...
 
void XSysMonPsv_SelectExtInterface (XSysMonPsv *InstancePtr, u8 Interface)
 This function selects I2C or PMBus interface to which traffic from SMBus is routed to. More...
 
void XSysMonPsv_StatusReset (XSysMonPsv *InstancePtr, u8 ResetSupply, u8 ResetTemperature)
 This function Resets the Min and Max values of Supplies and Temperature to negative and positive saturation respectively. More...
 
u16 XSysMonPsv_ReadDevTempThreshold (XSysMonPsv *InstancePtr, XSysMonPsv_Threshold ThresholdType)
 This function returns the device temperature threshold for min and max values in signed Q8.7 format. More...
 
void XSysMonPsv_SetDevTempThreshold (XSysMonPsv *InstancePtr, XSysMonPsv_Threshold ThresholdType, u16 Value)
 This function sets Device Temperature Threshold values. More...
 
u16 XSysMonPsv_ReadOTTempThreshold (XSysMonPsv *InstancePtr, XSysMonPsv_Threshold ThresholdType)
 This function returns the OT temperature threshold for min and max values in signed Q8.7 format. More...
 
void XSysMonPsv_SetOTTempThreshold (XSysMonPsv *InstancePtr, XSysMonPsv_Threshold ThresholdType, u16 Value)
 This function sets OT Temperature Threshold values. More...
 
u32 XSysMonPsv_ReadDeviceTemp (XSysMonPsv *InstancePtr, XSysMonPsv_Val Value)
 This function returns the temperature values for the device in signed Q8.7 format. More...
 
u32 XSysMonPsv_ReadSupplyThreshold (XSysMonPsv *InstancePtr, XSysMonPsv_Supply Supply, XSysMonPsv_Threshold ThresholdType)
 This function reads the raw value for Supply Threshold. More...
 
u32 XSysMonPsv_ReadSupplyValue (XSysMonPsv *InstancePtr, XSysMonPsv_Supply Supply, XSysMonPsv_Val Value)
 This function reads the raw Supply Value for requested. More...
 
u32 XSysMonPsv_IsNewData (XSysMonPsv *InstancePtr, XSysMonPsv_Supply Supply)
 This function is to be used to check if new data is available for a supply. More...
 
u32 XSysMonPsv_IsAlarmCondition (XSysMonPsv *InstancePtr, XSysMonPsv_Supply Supply)
 This function is to be used to check if the supply value has exceeded the set threshold values. More...
 
u32 XSysMonPsv_SetSupplyUpperThreshold (XSysMonPsv *InstancePtr, XSysMonPsv_Supply Supply, u32 Value)
 This function sets the raw value for Upper Supply Threshold. More...
 
u32 XSysMonPsv_SetSupplyLowerThreshold (XSysMonPsv *InstancePtr, XSysMonPsv_Supply Supply, u32 Value)
 This function sets the raw value for Lower Supply Threshold. More...
 
void XSysMonPsv_SetTempMode (XSysMonPsv *InstancePtr, u32 Mode)
 This function sets the alarm mode for Temperature alarms. More...
 
void XSysMonPsv_SetOTMode (XSysMonPsv *InstancePtr, u32 Mode)
 This function sets the alarm mode for OT alarm. More...
 
u32 XSysMonPsv_ReadAlarmConfig (XSysMonPsv *InstancePtr, XSysMonPsv_Supply Supply)
 This function reads the current Supply Alarm Config. More...
 
u32 XSysMonPsv_SetAlarmConfig (XSysMonPsv *InstancePtr, XSysMonPsv_Supply Supply, u32 Config)
 This function sets Alarm config for a supply. More...
 
int XSysMonPsv_ReadTempProcessed (XSysMonPsv *InstancePtr, XSysMonPsv_TempType Type, float *Val)
 This function reads temperature and returns value in degree celsius. More...
 
int XSysMonPsv_ReadTempRaw (XSysMonPsv *InstancePtr, XSysMonPsv_TempType Type, u32 *Val)
 This function reads temperature and returns value in raw format. More...
 
int XSysMonPsv_ReadTempProcessedSat (XSysMonPsv *InstancePtr, int SatId, float *Val)
 This function reads temperature of each satellite in degree celsius. More...
 
int XSysMonPsv_ReadTempRawSat (XSysMonPsv *InstancePtr, int SatId, u32 *Val)
 This function reads temperature of each satellite in raw format. More...
 
int XSysMonPsv_SetTempThresholdUpper (XSysMonPsv *InstancePtr, XSysMonPsv_TempEvt Event, u32 Val)
 This function sets temperature upper threshold. More...
 
int XSysMonPsv_SetTempThresholdLower (XSysMonPsv *InstancePtr, XSysMonPsv_TempEvt Event, u32 Val)
 This function sets temperature lower threshold. More...
 
int XSysMonPsv_GetTempThresholdUpper (XSysMonPsv *InstancePtr, XSysMonPsv_TempEvt Event, u32 *Val)
 This function gets temperature upper threshold. More...
 
int XSysMonPsv_GetTempThresholdLower (XSysMonPsv *InstancePtr, XSysMonPsv_TempEvt Event, u32 *Val)
 This function gets temperature lower threshold. More...
 
int XSysMonPsv_ReadSupplyProcessed (XSysMonPsv *InstancePtr, int Supply, float *Val)
 This function reads voltage for the supply. More...
 
int XSysMonPsv_ReadSupplyRaw (XSysMonPsv *InstancePtr, u32 Supply, u32 *Val)
 This function reads voltage for the supply in raw. More...
 
int XSysMonPsv_SetSupplyThresholdUpper (XSysMonPsv *InstancePtr, u32 Supply, u32 Val)
 This function sets upper threshold voltage for the supply. More...
 
int XSysMonPsv_SetSupplyThresholdLower (XSysMonPsv *InstancePtr, int Supply, u32 Val)
 This function sets loser threshold voltage for the supply. More...
 
int XSysMonPsv_GetSupplyThresholdUpper (XSysMonPsv *InstancePtr, u32 Supply, u32 *Val)
 This function gets upper threshold voltage for the supply. More...
 
int XSysMonPsv_GetSupplyThresholdLower (XSysMonPsv *InstancePtr, u32 Supply, u32 *Val)
 This function gets lower threshold voltage for the supply. More...
 
void XSysMonPsv_IntrEnable (XSysMonPsv *InstancePtr, u32 Mask, u8 IntrNum)
 This function enables the specified interrupts in the device. More...
 
void XSysMonPsv_IntrDisable (XSysMonPsv *InstancePtr, u32 Mask, u8 IntrNum)
 This function disables the specified interrupts in the device. More...
 
u32 XSysMonPsv_IntrGetEnabled (XSysMonPsv *InstancePtr, u8 IntrNum)
 This function returns the enabled interrupts read from the Interrupt Mask Register (IMR). More...
 
u32 XSysMonPsv_IntrGetStatus (XSysMonPsv *InstancePtr)
 This function returns the interrupt status read from Interrupt Status Register(ISR). More...
 
void XSysMonPsv_IntrClear (XSysMonPsv *InstancePtr, u32 Mask)
 This function clears the specified interrupts in the Interrupt Status Register (ISR). More...
 
void XSysMonPsv_SetNewDataIntSrc (XSysMonPsv *InstancePtr, XSysMonPsv_Supply Supply, u32 Mask)
 This function sets a supply as a source new data interrupt. More...
 
XSysMonPsv_ConfigXSysMonPsv_LookupConfig (void)
 This function looks for the device configuration based on the unique device ID. More...
 

Variables

This array contains the names of the supplies
const char * XSysMonPsv_Supply_Arr []
 Names of the supplies enabled in the design. More...
 

Macro Definition Documentation

#define XSysMonPsv_GetAlarmMask (   InstancePtr,
  Supply 
)    Mask = 1U << (InstancePtr->Supply_List[Supply] / 32U)

This macro returns the XSYSMONPSV_NEW_ALARMn_MASK for a configured supply.

Parameters
InstancePtris the instance of sysmon driver
Supplyis a type enum of supply enabled
Returns
A 32 bit mask to be used for configuring interrupts
Note
None

Enumeration Type Documentation

This typedef defines Threshold types.

Enumerator
XSYSMONPSV_TH_LOWER 

Lower Threshold.

XSYSMONPSV_TH_UPPER 

Upper Threshold.

This typedef defines value types for voltage readings.

Enumerator
XSYSMONPSV_VAL 

Current Value for temperature (for production silicon only) and supply.

XSYSMONPSV_VAL_MIN 

Minimum Value reached since reset.

XSYSMONPSV_VAL_MAX 

Maximum Value reached since reset.

XSYSMONPSV_VAL_VREF_MIN 

Minimum value reached for a temperature since last VRef.

XSYSMONPSV_VAL_VREF_MAX 

Maximum value reached for a temperature since last VRef.

This typedef defines types of supply values.

Enumerator
XSYSMONPSV_1V_UNIPOLAR 

1V unipolar fmt

XSYSMONPSV_2V_UNIPOLAR 

2V unipolar fmt

XSYSMONPSV_4V_UNIPOLAR 

4V unipolar fmt

XSYSMONPSV_1V_BIPOLAR 

1V bipolar fmt

Variable Documentation

const char* XSysMonPsv_Supply_Arr[]

Names of the supplies enabled in the design.

Referenced by SysMonPsvIntrExample(), and SysMonPsvPolledExample().