PS System Monitor#

UltraScale+ has multiple system monitors (sysmon). There are system monitors in the PS and the PL. The system monitor in the PL is always present, but has extended capabilities if the SYSMON IP-core is instantiated (see https://www.xilinx.com/products/intellectual-property/system-management-wiz.html). This software module only deals with the PS system monitor and provides a wrapper to access part of the available information, especially the chip temperature. Information:

The wrapper is heavily based on the vendor provided example:

Example#

The following example initializes the PS SYSMON and reads out the four available platform states. Note that reading all four values once takes approx \(1.5-2\,\mu s\). Since the values, especially the temperature, are not time critical, consider not reading the SYSMON in the control interrupt.

#include "xparameters.h"
#include "uz/uz_sysmon_ps/uz_sysmon_ps.h"

main(){
    uz_sysmon_ps_t * sysmon_instance=uz_sysmon_ps_init(XPAR_XSYSMONPSU_0_DEVICE_ID);
    float temp=0.0f;
    float vcc_lp=0.0f;
    float vcc_fp=0.0f;
    float fcc_aux=0.0f;
    while(1){
        temp = uz_sysmon_ps_read_temperature_degree_celsius(sysmon_instance);
        vcc_lp =  uz_sysmon_ps_read_vcc_psint_lp_volt(sysmon_instance);
        vcc_fp =  uz_sysmon_ps_read_vcc_psint_fp_volt(sysmon_instance);
        fcc_aux = uz_sysmon_ps_read_vcc_psaux_volt(sysmon_instance);
    }
}

Reference#

typedef struct uz_sysmon_ps_t uz_sysmon_ps_t#

Typedef for uz_sysmon_ps object definition.

uz_sysmon_ps_t *uz_sysmon_ps_init(uint16_t sysmon_device_id)#

Initializes an instance of the SYSMON_PS driver. Must not be called more than once!

Parameters:
  • sysmon_device_id – Device id of the SYSMON. Pass the define XPAR_XSYSMONPSU_0_DEVICE_ID from xparameters.h to uz_sysmon_ps_init.

Returns:

uz_sysmon_ps_t*

float uz_sysmon_ps_read_temperature_degree_celsius(uz_sysmon_ps_t *self)#

Reads the on-chip temperature of the PS system.

Parameters:
  • self – Pointer to driver instance

Returns:

float On-chip temperature in degree celsius

float uz_sysmon_ps_read_vcc_psint_lp_volt(uz_sysmon_ps_t *self)#

Reads the supply voltage of the low power domain (LP)

Parameters:
  • self

Returns:

float Low power domain supply voltage PSINTLP in volt.

float uz_sysmon_ps_read_vcc_psint_fp_volt(uz_sysmon_ps_t *self)#

Reads the supply voltage of the full power domain (LP)

Parameters:
  • self

Returns:

float full power domain supply voltage PSINTFP in volt.

float uz_sysmon_ps_read_vcc_psaux_volt(uz_sysmon_ps_t *self)#

Reads the supply voltage of PSAUX.

Parameters:
  • self

Returns:

float Low power domain supply voltage PSAUX in volt.