Intel® SoC FPGA Embedded Development Suite
Support for SoC FPGA Software Development, SoC FPGA HPS Architecture, HPS SoC Boot and Configuration, Operating Systems
Announcements
The Intel sign-in experience is changing in February to support enhanced security controls. If you sign in, click here for more information.

Absolute minimum bare metal app

rdb9878
Beginner
186 Views

I'm having a lot of trouble getting u-boot SPL to build/do anything on an Arria V board, so I want to make the absolute bare minimum software app with just enough code to get an HPS GPIO wiggling (GPIO64 in the HPS parameters page), so I can see it on the oscope, and prove it's running something. Can someone review these steps and let me know if anything is missing:

 

1) startup code at 0xffff0000, setup stack pointer, branch to main

2) call "spl_board_init()" from spl.c, which utilizes the "generated" settings from Quartus, which should configure clocks, initialize IO pins with the scan manager/pin mux, unthaw IO banks

3) disable both L4 watchdogs

4) clear reset bit for GPIO2 in the reset manager

5) in the GPIO2 register space, set bit 6 of the DDR register high to configure GPIO64 as output

6) in the GPIO2 register space, set/clear bit 6 of the DR register to toggle GPIO64 pin high/low.

 

0 Kudos
6 Replies
JingyangTeh
Employee
170 Views

Hi


I would not recommend you the approach you are looking at.

It might break some dependency.

Best thing is to keep the SPL to do the stuff from point 1 to 3.

Then your application will be doing the stuff from point 4 to 6.


You could refer to the Intel Hardware Libs Baremetal "Hello World" example.

https://www.intel.com/content/www/us/en/docs/programmable/683211/current/introduction.html


Regards

Jingyang, Teh


rdb9878
Beginner
158 Views

Hello, I will try out that link. In the meantime, could you elaborate on "keep the SPL"? My step 2 was doing "spl_board_init" from the original spl.c (not custom spl.c). Were there more steps involved?

 

Also: Where is the installer for DS-5 Community Edition?

Jeet14
Employee
127 Views

Hi,

Please refer the tutorial on-
1. How to Write and Run a Bare Metal C Program in ARM DS-5 AE for Altera SoCs. Link

2. Bare-Metal Debugging using ARM DS-5 Altera Edition. Link

Also, refer link to download the arm DS 5 tool and go to licensing DS-5 option to register and evaluate for free.

Regards
Tiwari

JingyangTeh
Employee
99 Views

Hi rdb9878


Thanks Jeetesh for providing the links.

You could refer to the links by Jeetesh on helping you with the baremetal application creation.

"Keeping the SPL" means that we will follow the flow of having at least the SPL to do the board initialization procedure.

From my understanding that you would like to only run your baremetal application on the board. I would not recommend that route.

If you refer to the baremetal guide https://www.intel.com/content/www/us/en/docs/programmable/683211/current/bare-metal-overview.html


The SPL is always present to do the board initialization procedure.


Regards

Jingyang, Teh


JingyangTeh
Employee
65 Views

Hi


Any update on this case?


Regards

Jingyang, Teh


JingyangTeh
Employee
29 Views

Hi


Since there are no feedback for this thread, I shall set this thread to close pending. Please login to ‘https://supporttickets.intel.com’, view details of the desire request, and post a feed/response within the next 15 days to allow me to continue to support you. After 15 days, this thread will be transitioned to community support. The community users will be able to help you on your follow-up questions.


If you happened to close this thread you might receive a survey. If you think you would rank your support experience less than 10 out of 10, please allow me to correct it before closing or if the problem can’t be corrected, please let me know the cause so that I may improve your future service experience.


Regards

Jingyang, Teh


Reply