Custom made BSP

Dears, I try to create new BSP intended for custom-made board with Microsemi PolarFire SoC for RTEMS 6.1. As I did bread-boarding on Beagle-V Fire and configured beaglevfire BSP for the board, I would like to create new BSP as derivative of riscv/beaglevfire BSP. The name of the new BSP will be Auriga.

I tried to make copies of files related to beaglevfire and named them auriga.

src\bsps\riscv\riscv\config\beaglevfire.cfg
copied to
src\bsps\riscv\riscv\config\auriga.cfg

src\bsps\riscv\riscv\dts\beaglevfire.dts
copied to
src\bsps\riscv\riscv\dts\auriga.dts

…\src\bsps\taurus\riscv\include\bsp\beaglevfire.h
copied to
…\src\bsps\taurus\riscv\include\bsp\auriga.h

I created config.ini containing:
[riscv/auriga]
BUILD_TESTS = False
RTEMS_POSIX_API = True
RTEMS_SMP = True
BSP_START_COPY_FDT_FROM_U_BOOT = False
BSP_VERBOSE_FATAL_EXTENSION = False

When I wanted to configure waf to build BSP by command
./waf configure --prefix=$HOME/sandbox/rtems/6 -v

I obtained this:
Setting top to : /home/ldk/sandbox/src
Setting out to : /home/ldk/sandbox/src/build
Configure RTEMS version : 6.1
Configure board support package (BSP) : riscv/auriga
No such base BSP: ‘riscv/auriga’
(complete log in /home/ldk/sandbox/src/build/config.log)

There is the contents of the file config.log

project configured on Thu Dec 4 17:22:30 2025 by

waf 2.1.4 (abi 20, python 30c03f0 on linux)

using ./waf configure --prefix=/home/ldk/sandbox/rtems/6 -v


Setting top to
/home/ldk/sandbox/src

Setting out to
/home/ldk/sandbox/src/build

Configure RTEMS version
6.1

Configure board support package (BSP)
riscv/auriga
from /home/ldk/sandbox/src: No such base BSP: ‘riscv/auriga’

I read the manual but it describes complex procedure of deploynment which requires git. I do not want to upload my files anywhere. Moreover, the manual looks obsolete. It speaks about some .bset files. However, there are no .bset files in installation of RTEMS 6.1

I have moved on.

Ignore the post.

SOLVED
The post can be deleted.

Hi there what was the solution? It would be good for others to know if they come across this post thank you.

Also welcome to RTEMS. :slight_smile:

The principal think to do is to create file bspxxxx.yml in src/spec/build/bsps/…

As I work with riscv, the name of the new file is
<BASE_DIR>/src/spec/build/bsps/riscv/riscv/bspauriga.yml

This file was derived from file
<BASE_DIR>/src/spec/build/bsps/riscv/riscv/bspbeaglevfire.yml
It is my case. Other user will search for such existing BSP which is the most similar to his application.

In the file bspauriga.yml, it is necessary to modify the line with BSP name, in my case to
bsp: auriga

Once I did that, build system knew new BSP riscv/auriga

The BSP can be configured by modifying other .yml files.

I did NOT create any file like
<BASE_DIR>/src/bsps/riscv/riscv/config/xxxxxx.cfg
The new BSP works without it.

I found it is possible not to enable DTB in file optdtb.yml and therefore, it is not necessary to create .dts file and the corresponding .h file containing DTB.

Anyway, I try to create and use DTB for this BSP.

Building and usage of user DTB is pretty easy - if you know how :slight_smile:

As I did not know how, I had to experiment and here is the result:

I started by file beaglevfire.dts which is human-readible contrary to DTB table.
I made a copy named auriga.dts and modified according to my hardware configuration.

dtc -@ -I dts -O dtb -o system.dtb auriga.dts
xxd -i system.dtb > auriga.h

Of course, any other file name can be chosen instead of system.dtb, it is temporary file only and can be deleted.

I modified auriga.h so that it looked similarly to beaglevfire.h - prevent multiple includes and add other necessary includes.

Then, it was necessary to:

  • Enable DTB table in file <BASE_DIR>\src\spec\build\bsps\optdtb.yml
  • Specify path to auriga.h in file <BASE_DIR>\src\spec\build\bsps\optdtbheaderpath.yml
  • Disable of usage of FDT from uboot in file <BASE_DIR>\src\spec\build\bsps\optfdtuboot.yml

All other configuration must be consistent. In my case, it was necessary to increase number of external interrupts in file
<BASE_DIR>\src\spec\build\bsps\riscv\optextirqmax.yml