Syntax
X<DUT>_Config* X<DUT>_LookupConfig(uintptr BaseAddress);
X<DUT>_Config* X<DUT>_LookupConfig(u16 DeviceId);
Description
This function is used to obtain the configuration information of the
specified BaseAddress or DeviceID. Where:
-
BaseAddress - The BaseAddress as defined in xparameters.h.
-
DeviceId - Device ID as defined in xparameters.h.
Note: The
DeviceId is no longer populated into the driver config struct. Instead
the BaseAddress is used to identify the driver
instance. The DeviceId will also not be populated
in the xparameters.h file. Software applications
using these drivers developed in the classic Vitis or
Vitis HLS tools will need to be updated to reflect
this change using #ifdef SDT as shown in the
following example:
#ifndef SDT
#define GPIO_EXAMPLE_DEVICE_ID XPAR_GPIO_0_DEVICE_ID
#else
#define XGPIO_AXI_BASEADDRESS XPAR_XGPIO_0_BASEADDR
#endif
Return
A pointer to a X<DUT>_LookupConfig variable that holds the configuration
information of the specified BaseAddress or device whose ID is
DeviceId. Returns NULL if no
match is found.