Skip to content

Commit

Permalink
Merge pull request #78 from stnolting/dependabot/submodules/neorv32-c…
Browse files Browse the repository at this point in the history
…378975

[Dependabot]: Bump neorv32 from `00d248c` to `c378975`
  • Loading branch information
stnolting committed Jul 29, 2024
2 parents 9bef9fa + 6b9d84f commit da60278
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 12 deletions.
10 changes: 3 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# FreeRTOS for NEORV32
# FreeRTOS on NEORV32

[![neorv32-freertos](https://img.shields.io/github/actions/workflow/status/stnolting/neorv32-freertos/main.yml?branch=main&longCache=true&style=flat-square&label=neorv32-freertos%20sim&logo=Github%20Actions&logoColor=fff)](https://github.com/stnolting/neorv32-freertos/actions/workflows/main.yml)
[![License](https://img.shields.io/github/license/stnolting/neorv32-freertos?longCache=true&style=flat-square&label=License)](https://github.com/stnolting/neorv32-freertos/blob/main/LICENSE)
Expand All @@ -15,14 +15,14 @@ processor-specific features.

## Requirements

#### Tools and framework
#### Tools and Framework

* [NEORV32](https://github.com/stnolting/neorv32) submodule
* [FreeRTOS kernel-only](https://github.com/FreeRTOS/FreeRTOS-Kernel) submodule
* Prebuilt [RISC-V GCC toolchain](https://github.com/stnolting/riscv-gcc-prebuilt)
* [GHDL](https://github.com/ghdl/ghdl) for simulating the processor, optional

#### Minimal processor configuration
#### Minimal Processor Configuration

* CPU architecture and ISA extensions: `rv32i_zicsr_zifencei`
* Memory
Expand All @@ -34,10 +34,6 @@ processor-specific features.
* UART0 as interface console
* general purpose IO controller (GPIO); high-active LED connected to bits 1:0, LED at pin 0 is used as "heart beat"

> [!TIP]
> For more information regarding the processor configuration options see the NEORV32's
[online data sheet](https://stnolting.github.io/neorv32/).


## How To Run

Expand Down
6 changes: 2 additions & 4 deletions demo/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@
#define UART_HW_HANDLE (NEORV32_UART0) // use UART0 (primary UART)

/* External definitions */
extern const unsigned __crt0_max_heap; // may heap size from NEORV32 linker script
extern void blinky(void); // actual show-case application
extern void freertos_risc_v_trap_handler(void); // FreeRTOS core

Expand Down Expand Up @@ -119,13 +118,12 @@ static void prvSetupHardware(void) {
}

// check heap size configuration
uint32_t neorv32_max_heap = (uint32_t)&__crt0_max_heap;
if ((uint32_t)&__crt0_max_heap != (uint32_t)configTOTAL_HEAP_SIZE){
if ((uint32_t)neorv32_heap_size_c != (uint32_t)configTOTAL_HEAP_SIZE){
neorv32_uart_printf(UART_HW_HANDLE,
"WARNING! Incorrect 'configTOTAL_HEAP_SIZE' configuration!\n"
"FreeRTOS configTOTAL_HEAP_SIZE: %u bytes\n"
"NEORV32 makefile heap size: %u bytes\n\n",
(uint32_t)configTOTAL_HEAP_SIZE, neorv32_max_heap);
(uint32_t)configTOTAL_HEAP_SIZE, neorv32_heap_size_c);
}

// check clock frequency configuration
Expand Down
2 changes: 1 addition & 1 deletion neorv32

0 comments on commit da60278

Please sign in to comment.