PolarFire® System-on-Chip (SoC) Applications - Configuring the Microprocessor Subsystem (MSS) Component
PolarFire® SoC Applications - Configuring the MSS Component
On this page, we will configure the Microprocessor Subsystem (MSS) component; this is a required step for any design using the MSS. We need to specify the part we will use, the peripherals we will use, the memory configuration we would like, and the clocking configuration. You will learn how to configure the MSS component for the PolarFire System-on-Chip (SoC) Discovery Kit, and create, manage, and generate an MSS component for any PolarFire SoC.
Configuring the MSS
Launch the MSS Configurator
Launching MSS Configurator
After installing Libero® SoC, the MSS Configurator icon is automatically added to your desktop. Double-click on the MSS icon to launch the MSS Configurator.
Otherwise, launch MSS Configurator manually from the installation path.
By default, MSS Configurator is in the following path:
C:\Microchip\Libero_SoC_{LIBERO_SOC_VERSION}\Libero_SoC\Designer\bin64\
Open the path shown above in your file explorer and launch the pfsoc_mss.exe program. Once you launch the MSS Configurator, you should see the window shown in the accompanying image.

Creating a New MSS Configuration
Create Project
To create a project, open the MSS Configurator and navigate to Project > New or press Ctrl + N.

Device Selection
When you click or press on the new project, you will see this sub-window.

Here, you need to enter your Die and Package information.
- Module Name: Your MSS component name, in this case, it is DemoProject
- Die: Your SoC Die parameter (MPFS095T) for the Discovery Kit
- Package: Your SoC Die parameter (FCSG325) for the Discovery Kit
- Speed: Your SoC Die parameter (-1) for the Discovery Kit
You can get board SoC information by reading your SoC manual.
Then, when you have passed all the required information, click OK.
Determining Peripheral Connections From Schematics
Extracting Connections
Before enabling peripherals, we need to understand how the mikroBUS™ socket Serial Peripheral Interface (SPI) interface is connected to the SoC, so we need to get a schematic of the board.
See the PolarFire SoC Discovery Kit schematic.
In the schematic, we need to find the required connection; in our case, it is the mikroBUS socket. Here we see four pins interacting with SPI:
- MBUS_SPI_CS > Chip select
- MBUS_SPI_CLK > Serial clock
- MBUS_SPI_MISO > Receive data
- MBUS_SPI_MOSI >Transmit data

Now we need to understand the names of the Field-Programmable Gate Array (FPGA) pins that are connected to mikroBUS sockets (search for "MBUS_SPI_" pins).

Now we see all pins are connected to the BANK-1, which is the fabric bank, and now we can extract the pins' names.
- MBUS_SPI_CS > pin C16
- MBUS_SPI_CLK > pin E17
- MBUS_SPI_MISO > pin E11
- MBUS_SPI_MOSI > pin A18
Configuring Peripherals
Enabling Peripherals
As we are routing the I/Os through the fabric on the PolarFire SoC Discovery Kit, we can use any SPI peripheral. As we have to use dedicated MSS I/Os, we need to ensure we use the SPI connected to those I/Os. In the MSS Configurator, the Peripherals tab shows all peripherals and their connections. Click on SPI_0.

As we see, the SPI 0 peripheral has three connection methods.
- MSS I/Os Bank2
- MSS I/Os Bank4
- Fabric I/O
As we know, the mikroBUS socket SPI interface is connected through the Fabric I/Os, let's choose the Fabric I/O option.

Once you see the SPI_0 connected to the Fabric I/O, it means the peripheral ports are connected to the Fabric. We also need to expose the Target Select 1 to the Fabric I/O to use the chip select pin in the program. You will see the following:

Also, we need a Universal Asynchronous Receiver/Transmitter (UART) interface to talk with the SoC, so let's enable it. Using the guide shown above, you can find the connection of the MMUART_0 peripheral required to have a connection between MSS and USB port. On the PolarFire SoC Discovery Kit, the MMUART_0 Peripheral is connected to the MSS I/Os Bank2 A. Set the IO Connection value as MSS I/Os Bank2 A. In the MSS Configurator, we see the Peripherals tab where we need to open the MMUART_0 Peripheral.

Configuring The L2 Cache
Share L2 Cache between Cache, LIM, and Scratchpad
Now we need to configure the L2 cache so we can use some of it as RAM for our application. Switch to the L2 Cache tab.

You should have this view. The number of ways allocated to each can be set via the entry boxes in the top left of the screen:
- L2-LIM WAYs
- Scratchpad WAYs
We can configure up to 15 ways as LIM or Scratchpad, but for this example, four ways of each are enough.

This is all that needs to be configured in this tab.
Configuring Clocks
Clock Management
The PolarFire SoC Discovery Kit has one clock source, OSCILLATOR (OSC), so we need to configure our design clock based on its physical parameters. In the schematic, the oscillator has a 125 MHz frequency.

To configure the clock switch to the Clocks tab in MSS Configurator, and change the Clock Sources Frequency option from 100 to 125 MHz.

That's all we need to configure in MSS. Let's generate the MSS.
Generating MSS
Generating MSS
To generate the MSS, navigate to Project > Generate or press Ctrl + E or click on the icon in the top-left corner.

Checking Generation
After successfully generating, you will see this message in the log window:
In the MSS generation path, you will have the following files:
- DemoProject.cfg: MSS Configuration file for MSS Configurator
- DemoProject.cxz: MSS component for import to Libero SoC
- DemoProject_mss_cfg.xml: MSS subsystem XML representation for the SoftConsole®
- DemoProject_Report.html: MSS peripherals and components usage report file
Watch this MSS Configurator Run Through video on YouTube® to learn the key points and main concepts of MSS and Libero SoC.