mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-10-18 10:47:47 -04:00
Add Vectored Interrupt Support To SiFive RISC-V Demo (#871)
Update SiFive IAR demo to support vectored interrupts. This is a near copy of https://github.com/FreeRTOS/FreeRTOS/pull/797. Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com> Co-authored-by: Gaurav Aggarwal <aggarg@amazon.com>
This commit is contained in:
parent
1fc8a8ee42
commit
54d4eeaa26
23 changed files with 175 additions and 163 deletions
|
@ -20,7 +20,8 @@
|
||||||
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
*
|
*
|
||||||
* https://www.FreeRTOS.org
|
* https://www.FreeRTOS.org
|
||||||
* https://aws.amazon.com/freertos
|
* https://github.com/FreeRTOS
|
||||||
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef FREERTOS_CONFIG_H
|
#ifndef FREERTOS_CONFIG_H
|
||||||
|
@ -101,15 +102,7 @@
|
||||||
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_pcTaskGetTaskName 1
|
#define INCLUDE_pcTaskGetTaskName 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
* format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
* readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
* is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
* included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
* functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
|
|
@ -20,7 +20,8 @@
|
||||||
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
*
|
*
|
||||||
* https://www.FreeRTOS.org
|
* https://www.FreeRTOS.org
|
||||||
* https://aws.amazon.com/freertos
|
* https://github.com/FreeRTOS
|
||||||
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef FREERTOS_CONFIG_H
|
#ifndef FREERTOS_CONFIG_H
|
||||||
|
@ -101,15 +102,7 @@
|
||||||
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_pcTaskGetTaskName 1
|
#define INCLUDE_pcTaskGetTaskName 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
* format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
* readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
* is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
* included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
* functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
|
|
@ -102,15 +102,7 @@
|
||||||
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_pcTaskGetTaskName 1
|
#define INCLUDE_pcTaskGetTaskName 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
* format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
* readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
* is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
* included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
* functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
|
|
@ -102,15 +102,7 @@
|
||||||
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_pcTaskGetTaskName 1
|
#define INCLUDE_pcTaskGetTaskName 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
* format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
* readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
* is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
* included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
* functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
|
|
@ -102,15 +102,7 @@
|
||||||
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_pcTaskGetTaskName 1
|
#define INCLUDE_pcTaskGetTaskName 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
* format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
* readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
* is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
* included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
* functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
|
|
@ -102,15 +102,7 @@
|
||||||
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_pcTaskGetTaskName 1
|
#define INCLUDE_pcTaskGetTaskName 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
* format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
* readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
* is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
* included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
* functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
|
|
@ -102,15 +102,7 @@
|
||||||
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_pcTaskGetTaskName 1
|
#define INCLUDE_pcTaskGetTaskName 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
* format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
* readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
* is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
* included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
* functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
|
|
@ -102,15 +102,7 @@
|
||||||
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_pcTaskGetTaskName 1
|
#define INCLUDE_pcTaskGetTaskName 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
* format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
* readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
* is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
* included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
* functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
|
|
@ -102,15 +102,7 @@
|
||||||
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_pcTaskGetTaskName 1
|
#define INCLUDE_pcTaskGetTaskName 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
* format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
* readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
* is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
* included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
* functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
|
|
@ -102,15 +102,7 @@
|
||||||
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_pcTaskGetTaskName 1
|
#define INCLUDE_pcTaskGetTaskName 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
* format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
* readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
* is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
* included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
* functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
|
|
@ -104,15 +104,7 @@
|
||||||
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_pcTaskGetTaskName 1
|
#define INCLUDE_pcTaskGetTaskName 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
* format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
* readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
* is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
* included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
* functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
|
|
@ -102,15 +102,7 @@
|
||||||
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_pcTaskGetTaskName 1
|
#define INCLUDE_pcTaskGetTaskName 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
* format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
* readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
* is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
* included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
* functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
|
|
@ -20,7 +20,7 @@
|
||||||
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
*
|
*
|
||||||
* https://www.FreeRTOS.org
|
* https://www.FreeRTOS.org
|
||||||
* https://aws.amazon.com/freertos
|
* https://github.com/FreeRTOS
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -102,15 +102,7 @@
|
||||||
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_pcTaskGetTaskName 1
|
#define INCLUDE_pcTaskGetTaskName 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
* format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
* readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
* is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
* included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
* functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
|
|
@ -20,7 +20,8 @@
|
||||||
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
*
|
*
|
||||||
* https://www.FreeRTOS.org
|
* https://www.FreeRTOS.org
|
||||||
* https://aws.amazon.com/freertos
|
* https://github.com/FreeRTOS
|
||||||
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef FREERTOS_CONFIG_H
|
#ifndef FREERTOS_CONFIG_H
|
||||||
|
@ -101,15 +102,7 @@
|
||||||
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_pcTaskGetTaskName 1
|
#define INCLUDE_pcTaskGetTaskName 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
* format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
* readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
* is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
* included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
* functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
|
|
@ -20,7 +20,7 @@
|
||||||
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
*
|
*
|
||||||
* https://www.FreeRTOS.org
|
* https://www.FreeRTOS.org
|
||||||
* https://aws.amazon.com/freertos
|
* https://github.com/FreeRTOS
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -99,15 +99,7 @@ to exclude the API function. */
|
||||||
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
#define INCLUDE_xEventGroupSetBitsFromISR 1
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_pcTaskGetTaskName 1
|
#define INCLUDE_pcTaskGetTaskName 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
#ifdef _DEBUG
|
#ifdef _DEBUG
|
||||||
|
|
|
@ -0,0 +1,2 @@
|
||||||
|
# RISC-V SiFive HiFive1 Rev B Demo
|
||||||
|
View https://www.freertos.org/RTOS-RISC-V-FreedomStudio-IAR-HiFive-RevB.html for more information on how to run this demo
|
|
@ -454,7 +454,7 @@
|
||||||
</option>
|
</option>
|
||||||
<option>
|
<option>
|
||||||
<name>CThirdPartyDriverDll</name>
|
<name>CThirdPartyDriverDll</name>
|
||||||
<state>Browse to your third-party driver</state>
|
<state>###Uninitialized###</state>
|
||||||
</option>
|
</option>
|
||||||
<option>
|
<option>
|
||||||
<name>CThirdPartyLogFileCheck</name>
|
<name>CThirdPartyLogFileCheck</name>
|
||||||
|
|
|
@ -483,7 +483,7 @@
|
||||||
</option>
|
</option>
|
||||||
<option>
|
<option>
|
||||||
<name>AsmDefines</name>
|
<name>AsmDefines</name>
|
||||||
<state>portasmHANDLE_INTERRUPT=vApplicationHandleTrap</state>
|
<state></state>
|
||||||
</option>
|
</option>
|
||||||
<option>
|
<option>
|
||||||
<name>PreInclude</name>
|
<name>PreInclude</name>
|
||||||
|
@ -553,7 +553,7 @@
|
||||||
<option>
|
<option>
|
||||||
<name>OOCOutputFormat</name>
|
<name>OOCOutputFormat</name>
|
||||||
<version>0</version>
|
<version>0</version>
|
||||||
<state>0</state>
|
<state>2</state>
|
||||||
</option>
|
</option>
|
||||||
<option>
|
<option>
|
||||||
<name>OCOutputOverride</name>
|
<name>OCOutputOverride</name>
|
||||||
|
@ -561,7 +561,7 @@
|
||||||
</option>
|
</option>
|
||||||
<option>
|
<option>
|
||||||
<name>OOCOutputFile</name>
|
<name>OOCOutputFile</name>
|
||||||
<state></state>
|
<state>RTOSDemo.bin</state>
|
||||||
</option>
|
</option>
|
||||||
<option>
|
<option>
|
||||||
<name>OOCCommandLineProducer</name>
|
<name>OOCCommandLineProducer</name>
|
||||||
|
@ -569,7 +569,7 @@
|
||||||
</option>
|
</option>
|
||||||
<option>
|
<option>
|
||||||
<name>OOCObjCopyEnable</name>
|
<name>OOCObjCopyEnable</name>
|
||||||
<state>0</state>
|
<state>1</state>
|
||||||
</option>
|
</option>
|
||||||
</data>
|
</data>
|
||||||
</settings>
|
</settings>
|
||||||
|
@ -2009,4 +2009,7 @@
|
||||||
<file>
|
<file>
|
||||||
<name>$PROJ_DIR$\main.c</name>
|
<name>$PROJ_DIR$\main.c</name>
|
||||||
</file>
|
</file>
|
||||||
|
<file>
|
||||||
|
<name>$PROJ_DIR$\vector_table.S</name>
|
||||||
|
</file>
|
||||||
</project>
|
</project>
|
||||||
|
|
|
@ -58,6 +58,17 @@
|
||||||
or 0 to run the more comprehensive test and demo application. */
|
or 0 to run the more comprehensive test and demo application. */
|
||||||
#define mainCREATE_SIMPLE_BLINKY_DEMO_ONLY 0
|
#define mainCREATE_SIMPLE_BLINKY_DEMO_ONLY 0
|
||||||
|
|
||||||
|
/* Set to 1 to use direct mode and set to 0 to use vectored mode.
|
||||||
|
*
|
||||||
|
* VECTOR MODE=Direct --> all traps into machine mode cause the pc to be set to the
|
||||||
|
* vector base address (BASE) in the mtvec register.
|
||||||
|
*
|
||||||
|
* VECTOR MODE=Vectored --> all synchronous exceptions into machine mode cause the
|
||||||
|
* pc to be set to the BASE, whereas interrupts cause the pc to be set to the
|
||||||
|
* address BASE plus four times the interrupt cause number.
|
||||||
|
*/
|
||||||
|
#define mainVECTOR_MODE_DIRECT 0
|
||||||
|
|
||||||
/* UART hardware constants. */
|
/* UART hardware constants. */
|
||||||
#define mainUART_BASE_ADDRESS ( *( volatile uint32_t * ) 0x20000000UL )
|
#define mainUART_BASE_ADDRESS ( *( volatile uint32_t * ) 0x20000000UL )
|
||||||
#define mainUART_TX_DATA 0x00
|
#define mainUART_TX_DATA 0x00
|
||||||
|
@ -99,6 +110,9 @@ or 0 to run the more comprehensive test and demo application. */
|
||||||
|
|
||||||
/*-----------------------------------------------------------*/
|
/*-----------------------------------------------------------*/
|
||||||
|
|
||||||
|
extern void freertos_risc_v_trap_handler( void );
|
||||||
|
extern void freertos_vector_table( void );
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* main_blinky() is used when mainCREATE_SIMPLE_BLINKY_DEMO_ONLY is set to 1.
|
* main_blinky() is used when mainCREATE_SIMPLE_BLINKY_DEMO_ONLY is set to 1.
|
||||||
* main_full() is used when mainCREATE_SIMPLE_BLINKY_DEMO_ONLY is set to 0.
|
* main_full() is used when mainCREATE_SIMPLE_BLINKY_DEMO_ONLY is set to 0.
|
||||||
|
@ -172,6 +186,16 @@ static void prvSetupHardware( void )
|
||||||
mainUART0_TXCTRL_REG |= mainUART_TXEN_BIT;
|
mainUART0_TXCTRL_REG |= mainUART_TXEN_BIT;
|
||||||
mainUART0_GPIO_SEL_REG &= mainUART0_PIN;
|
mainUART0_GPIO_SEL_REG &= mainUART0_PIN;
|
||||||
mainUART0_GPIO_SEL_EN |= mainUART0_PIN;
|
mainUART0_GPIO_SEL_EN |= mainUART0_PIN;
|
||||||
|
|
||||||
|
#if( mainVECTOR_MODE_DIRECT == 1 )
|
||||||
|
{
|
||||||
|
__asm__ volatile( "csrw mtvec, %0" :: "r"( freertos_risc_v_trap_handler ) );
|
||||||
|
}
|
||||||
|
#else
|
||||||
|
{
|
||||||
|
__asm__ volatile( "csrw mtvec, %0" :: "r"( ( uintptr_t )freertos_vector_table | 0x1 ) );
|
||||||
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
/*-----------------------------------------------------------*/
|
/*-----------------------------------------------------------*/
|
||||||
|
|
||||||
|
@ -263,19 +287,26 @@ void vApplicationTickHook( void )
|
||||||
}
|
}
|
||||||
/*-----------------------------------------------------------*/
|
/*-----------------------------------------------------------*/
|
||||||
|
|
||||||
/* Called from the kernel's port layer to handle device specific external
|
void freertos_risc_v_application_interrupt_handler( uint32_t ulMcause )
|
||||||
* interrupts. */
|
|
||||||
void vApplicationHandleTrap( uint32_t mcause )
|
|
||||||
{
|
{
|
||||||
char pcCause[ 20 ];
|
char pcCause[ 20 ];
|
||||||
|
|
||||||
#warning vApplicationHandleTrap not implemented.
|
|
||||||
/* Not implemented yet! */
|
/* Not implemented yet! */
|
||||||
sprintf( pcCause, "%u", mcause );
|
sprintf( pcCause, "%u", ulMcause );
|
||||||
vSendString( pcCause );
|
configPRINT_STRING( pcCause );
|
||||||
configASSERT( mcause == 0 );
|
configASSERT( ulMcause == 0 );
|
||||||
}
|
}
|
||||||
|
/*-----------------------------------------------------------*/
|
||||||
|
|
||||||
|
void freertos_risc_v_application_exception_handler( uint32_t ulMcause )
|
||||||
|
{
|
||||||
|
char pcCause[ 20 ];
|
||||||
|
|
||||||
|
/* Not implemented yet! */
|
||||||
|
sprintf( pcCause, "%u", ulMcause );
|
||||||
|
configPRINT_STRING( pcCause );
|
||||||
|
configASSERT( ulMcause == 0 );
|
||||||
|
}
|
||||||
/*-----------------------------------------------------------*/
|
/*-----------------------------------------------------------*/
|
||||||
|
|
||||||
void *malloc( size_t xSize )
|
void *malloc( size_t xSize )
|
||||||
|
|
101
FreeRTOS/Demo/RISC-V_RV32_SiFive_HiFive1-RevB_IAR/vector_table.S
Normal file
101
FreeRTOS/Demo/RISC-V_RV32_SiFive_HiFive1-RevB_IAR/vector_table.S
Normal file
|
@ -0,0 +1,101 @@
|
||||||
|
/*
|
||||||
|
* FreeRTOS V202112.00
|
||||||
|
* Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
||||||
|
*
|
||||||
|
* Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||||
|
* this software and associated documentation files (the "Software"), to deal in
|
||||||
|
* the Software without restriction, including without limitation the rights to
|
||||||
|
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||||
|
* the Software, and to permit persons to whom the Software is furnished to do so,
|
||||||
|
* subject to the following conditions:
|
||||||
|
*
|
||||||
|
* The above copyright notice and this permission notice shall be included in all
|
||||||
|
* copies or substantial portions of the Software.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||||
|
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||||
|
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||||
|
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||||
|
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
|
*
|
||||||
|
* https://www.FreeRTOS.org
|
||||||
|
* https://github.com/FreeRTOS
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
EXTERN freertos_risc_v_exception_handler
|
||||||
|
EXTERN freertos_risc_v_interrupt_handler
|
||||||
|
EXTERN freertos_risc_v_mtimer_interrupt_handler
|
||||||
|
|
||||||
|
SECTION `.text`:CODE:ROOT(7)
|
||||||
|
CODE
|
||||||
|
.option norvc
|
||||||
|
PUBLIC freertos_vector_table
|
||||||
|
|
||||||
|
freertos_vector_table:
|
||||||
|
IRQ_0:
|
||||||
|
j freertos_risc_v_exception_handler
|
||||||
|
IRQ_1:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_2:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_3:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_4:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_5:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_6:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_7:
|
||||||
|
j freertos_risc_v_mtimer_interrupt_handler
|
||||||
|
IRQ_8:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_9:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_10:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_11:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_12:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_13:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_14:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_15:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC0:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC1:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC2:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC3:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC4:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC5:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC6:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC7:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC8:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC9:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC10:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC11:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC12:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC13:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC14:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
IRQ_LC15:
|
||||||
|
j freertos_risc_v_interrupt_handler
|
||||||
|
/*-----------------------------------------------------------*/
|
|
@ -1 +1 @@
|
||||||
Subproject commit b0a8bd8f28d0138b5eb70e8b53da3e9d17ce8d40
|
Subproject commit f789a0e7907feca1a9019637219f0fd113a6c380
|
|
@ -118,15 +118,7 @@
|
||||||
#define INCLUDE_xTimerPendFunctionCall 1
|
#define INCLUDE_xTimerPendFunctionCall 1
|
||||||
#define INCLUDE_xTaskGetCurrentTaskHandle 1
|
#define INCLUDE_xTaskGetCurrentTaskHandle 1
|
||||||
#define INCLUDE_xTaskAbortDelay 1
|
#define INCLUDE_xTaskAbortDelay 1
|
||||||
|
#define configUSE_STATS_FORMATTING_FUNCTIONS 0
|
||||||
/* This demo makes use of one or more example stats formatting functions. These
|
|
||||||
* format the raw data provided by the uxTaskGetSystemState() function in to human
|
|
||||||
* readable ASCII form. See the notes in the implementation of vTaskList() within
|
|
||||||
* FreeRTOS/Source/tasks.c for limitations. configUSE_STATS_FORMATTING_FUNCTIONS
|
|
||||||
* is set to 2 so the formatting functions are included without the stdio.h being
|
|
||||||
* included in tasks.c. That is because this project defines its own sprintf()
|
|
||||||
* functions. */
|
|
||||||
#define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
|
||||||
|
|
||||||
/* Assert call defined for debug builds. */
|
/* Assert call defined for debug builds. */
|
||||||
extern void vAssertCalled( const char * pcFile,
|
extern void vAssertCalled( const char * pcFile,
|
||||||
|
|
|
@ -4,7 +4,7 @@ description: "This is the standard distribution of FreeRTOS."
|
||||||
|
|
||||||
dependencies:
|
dependencies:
|
||||||
- name: "FreeRTOS-Kernel"
|
- name: "FreeRTOS-Kernel"
|
||||||
version: "b0a8bd8"
|
version: "f789a0e79"
|
||||||
repository:
|
repository:
|
||||||
type: "git"
|
type: "git"
|
||||||
url: "https://github.com/FreeRTOS/FreeRTOS-Kernel.git"
|
url: "https://github.com/FreeRTOS/FreeRTOS-Kernel.git"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue