mirror of
https://github.com/FreeRTOS/FreeRTOS.git
synced 2025-12-14 08:04:35 +08:00
Hygiene changes of old Demo folders and temporary removal of submodules (#666)
* Remove submodules of community and partner contribution repos, and stale directory of FreeRTOS+UDP * Obselete NTP demo and rename of HTTP server demo folder * Update manifest.yml
This commit is contained in:
6
.gitmodules
vendored
6
.gitmodules
vendored
@@ -52,9 +52,3 @@
|
|||||||
[submodule "FreeRTOS-Plus/Source/Application-Protocols/coreSNTP"]
|
[submodule "FreeRTOS-Plus/Source/Application-Protocols/coreSNTP"]
|
||||||
path = FreeRTOS-Plus/Source/Application-Protocols/coreSNTP
|
path = FreeRTOS-Plus/Source/Application-Protocols/coreSNTP
|
||||||
url = https://github.com/FreeRTOS/coreSNTP.git
|
url = https://github.com/FreeRTOS/coreSNTP.git
|
||||||
[submodule "FreeRTOS/Demo/ThirdParty/FreeRTOS-Partner-Supported-Demos"]
|
|
||||||
path = FreeRTOS/Demo/ThirdParty/Partner-Supported-Demos
|
|
||||||
url = https://github.com/FreeRTOS/FreeRTOS-Partner-Supported-Demos
|
|
||||||
[submodule "FreeRTOS/Demo/ThirdParty/FreeRTOS-Community-Supported-Demos"]
|
|
||||||
path = FreeRTOS/Demo/ThirdParty/Community-Supported-Demos
|
|
||||||
url = https://github.com/FreeRTOS/FreeRTOS-Community-Supported-Demos
|
|
||||||
|
|||||||
@@ -0,0 +1,5 @@
|
|||||||
|
[{000214A0-0000-0000-C000-000000000046}]
|
||||||
|
Prop3=19,2
|
||||||
|
[InternetShortcut]
|
||||||
|
URL=https://www.freertos.org/sntp-library.html
|
||||||
|
IDList=
|
||||||
@@ -0,0 +1,5 @@
|
|||||||
|
FreeRTOS 2020107.00 adds a new SNTPv4 client library, [FreeRTOS/coreSNTP](https://github.com/FreeRTOS/coreSNTP),
|
||||||
|
and an [accompanying demo](..\..\..\coreSNTP_Windows_Simulator) to showcase the setup of an SNTP client and system
|
||||||
|
wall-clock time using the library. Refer to
|
||||||
|
The protocols implemented in this directory are intended to be demo quality
|
||||||
|
examples only. They are not intended for inclusion in production devices.
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
The protocols implemented in this directory are intended to be demo quality
|
|
||||||
examples only. They are not intended for inclusion in production devices.
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
[{000214A0-0000-0000-C000-000000000046}]
|
|
||||||
Prop3=19,2
|
|
||||||
[InternetShortcut]
|
|
||||||
URL=http://www.freertos.org/FreeRTOS-Plus/FreeRTOS_Plus_TCP/index.html
|
|
||||||
IDList=
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
FreeRTOS+UDP was removed in FreeRTOS V10.1.0 as it was replaced by FreeRTOS+TCP,
|
|
||||||
which was brought into the main download in FreeRTOS V10.0.0. FreeRTOS+TCP can
|
|
||||||
be configured as a UDP only stack, and FreeRTOS+UDP does not contain the patches
|
|
||||||
applied to FreeRTOS+TCP.
|
|
||||||
Submodule FreeRTOS/Demo/ThirdParty/Community-Supported-Demos deleted from e21b617e4c
Submodule FreeRTOS/Demo/ThirdParty/Partner-Supported-Demos deleted from 109ef4d0f8
@@ -1,49 +0,0 @@
|
|||||||
/*
|
|
||||||
* FreeRTOS V202104.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. If you wish to use our Amazon
|
|
||||||
* FreeRTOS name, please do so in a fair use way that does not cause confusion.
|
|
||||||
*
|
|
||||||
* 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.
|
|
||||||
*
|
|
||||||
* http://www.FreeRTOS.org
|
|
||||||
* http://aws.amazon.com/freertos
|
|
||||||
*
|
|
||||||
* 1 tab == 4 spaces!
|
|
||||||
*/
|
|
||||||
|
|
||||||
/* Scheduler includes. */
|
|
||||||
#include "FreeRTOS.h"
|
|
||||||
#include "task.h"
|
|
||||||
|
|
||||||
/* Demo includes. */
|
|
||||||
#include "IntQueueTimer.h"
|
|
||||||
#include "IntQueue.h"
|
|
||||||
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
void vInitialiseTimerForIntQueueTest( void )
|
|
||||||
{
|
|
||||||
/* Initialize a hardware timer. */
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
void IntQueueTestTimerHandler( void )
|
|
||||||
{
|
|
||||||
portYIELD_FROM_ISR( xSecondTimerHandler() );
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
@@ -1,42 +0,0 @@
|
|||||||
/*
|
|
||||||
* FreeRTOS V202104.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. If you wish to use our Amazon
|
|
||||||
* FreeRTOS name, please do so in a fair use way that does not cause confusion.
|
|
||||||
*
|
|
||||||
* 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.
|
|
||||||
*
|
|
||||||
* http://www.FreeRTOS.org
|
|
||||||
* http://aws.amazon.com/freertos
|
|
||||||
*
|
|
||||||
* 1 tab == 4 spaces!
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef INT_QUEUE_TIMER_H
|
|
||||||
#define INT_QUEUE_TIMER_H
|
|
||||||
|
|
||||||
/**
|
|
||||||
* The function called from queue interrupt tests to initialise timer.
|
|
||||||
*/
|
|
||||||
void vInitialiseTimerForIntQueueTest( void );
|
|
||||||
|
|
||||||
/**
|
|
||||||
* The function to be called from a timer handler.
|
|
||||||
*/
|
|
||||||
void IntQueueTestTimerHandler( void );
|
|
||||||
|
|
||||||
#endif /* INT_QUEUE_TIMER_H */
|
|
||||||
177
FreeRTOS/Demo/ThirdParty/Template/README.md
vendored
177
FreeRTOS/Demo/ThirdParty/Template/README.md
vendored
@@ -1,177 +0,0 @@
|
|||||||
# Create a Test Project
|
|
||||||
|
|
||||||
## Initial Setup
|
|
||||||
|
|
||||||
1. Create a new directory in the [FreeRTOS Partner Supported Demos Repository](https://github.com/FreeRTOS/FreeRTOS-Partner-Supported-Demos/tree/main)
|
|
||||||
or [FreeRTOS Community Supported Demos Repository](https://github.com/FreeRTOS/FreeRTOS-Community-Supported-Demos/tree/main).
|
|
||||||
The suggested name for the directory is `<hardware_name>_<compiler_name>`.
|
|
||||||
2. Create a project for your hardware and tool-chain in this directory.
|
|
||||||
3. Copy all the files in the [FreeRTOS/Demo/ThirdParty/Template](https://github.com/FreeRTOS/FreeRTOS/tree/main/FreeRTOS/Demo/ThirdParty/Template)
|
|
||||||
directory to your project directory:
|
|
||||||
* `IntQueueTimer.h`
|
|
||||||
* `IntQueueTimer.c`
|
|
||||||
* `TestRunner.h`
|
|
||||||
* `TestRunner.c`
|
|
||||||
* `RegTests.h`
|
|
||||||
* `RegTests.c`
|
|
||||||
|
|
||||||
## Project Configuration
|
|
||||||
|
|
||||||
1. Compile the following additional files in your project:
|
|
||||||
* All files in the [FreeRTOS/Demo/Common/Minimal](https://github.com/FreeRTOS/FreeRTOS/tree/main/FreeRTOS/Demo/Common/Minimal) directory except
|
|
||||||
`comtest_strings.c`, `crhook.c` , `comtest.c` ,`crflash.c`,`flash.c`, `flash_timer.c` and `sp_flop.c`.
|
|
||||||
2. Add the following paths to your include search path:
|
|
||||||
* `FreeRTOS/Demo/Common/include`.
|
|
||||||
3. Call the `void vStartTests( void )` function from your `main` function after
|
|
||||||
doing all the hardware initialization. Note that this function starts the
|
|
||||||
scheduler and therefore, never returns.
|
|
||||||
```c
|
|
||||||
#include "TestRunner.h"
|
|
||||||
|
|
||||||
void main( void )
|
|
||||||
{
|
|
||||||
/* Startup and Hardware initialization. */
|
|
||||||
|
|
||||||
/* Start tests. */
|
|
||||||
vStartTests();
|
|
||||||
|
|
||||||
/* Should never reach here. */
|
|
||||||
for( ; ; );
|
|
||||||
}
|
|
||||||
```
|
|
||||||
|
|
||||||
## Set up FreeRTOSConfig.h
|
|
||||||
|
|
||||||
1. Enable tick hook by adding the following line in your `FreeRTOSConfig.h`:
|
|
||||||
```c
|
|
||||||
#define configUSE_TICK_HOOK 1
|
|
||||||
```
|
|
||||||
2. Set the task notification array size to 3 by adding the following line in
|
|
||||||
your `FreeRTOSConfig.h`:
|
|
||||||
```c
|
|
||||||
#define configTASK_NOTIFICATION_ARRAY_ENTRIES 3
|
|
||||||
```
|
|
||||||
3. Enable printing by mapping `configPRINTF` to your print function. Note that
|
|
||||||
`configPRINTF` calls are wrapped in double parentheses to support C89. If you
|
|
||||||
have a thread-safe `printf` function, the following is what should be added
|
|
||||||
in your `FreeRTOSConfig.h`:
|
|
||||||
```c
|
|
||||||
#define configPRINTF( X ) printf X
|
|
||||||
```
|
|
||||||
4. Add the following defines in your `FreeRTOSConfig.h`:
|
|
||||||
```c
|
|
||||||
#define configSTART_TASK_NOTIFY_TESTS 0
|
|
||||||
#define configSTART_TASK_NOTIFY_ARRAY_TESTS 0
|
|
||||||
#define configSTART_BLOCKING_QUEUE_TESTS 0
|
|
||||||
#define configSTART_SEMAPHORE_TESTS 0
|
|
||||||
#define configSTART_POLLED_QUEUE_TESTS 0
|
|
||||||
#define configSTART_INTEGER_MATH_TESTS 0
|
|
||||||
#define configSTART_GENERIC_QUEUE_TESTS 0
|
|
||||||
#define configSTART_PEEK_QUEUE_TESTS 0
|
|
||||||
#define configSTART_MATH_TESTS 0
|
|
||||||
#define configSTART_RECURSIVE_MUTEX_TESTS 0
|
|
||||||
#define configSTART_COUNTING_SEMAPHORE_TESTS 0
|
|
||||||
#define configSTART_QUEUE_SET_TESTS 0
|
|
||||||
#define configSTART_QUEUE_OVERWRITE_TESTS 0
|
|
||||||
#define configSTART_EVENT_GROUP_TESTS 0
|
|
||||||
#define configSTART_INTERRUPT_SEMAPHORE_TESTS 0
|
|
||||||
#define configSTART_QUEUE_SET_POLLING_TESTS 0
|
|
||||||
#define configSTART_BLOCK_TIME_TESTS 0
|
|
||||||
#define configSTART_ABORT_DELAY_TESTS 0
|
|
||||||
#define configSTART_MESSAGE_BUFFER_TESTS 0
|
|
||||||
#define configSTART_STREAM_BUFFER_TESTS 0
|
|
||||||
#define configSTART_STREAM_BUFFER_INTERRUPT_TESTS 0
|
|
||||||
#define configSTART_TIMER_TESTS 0
|
|
||||||
#define configSTART_INTERRUPT_QUEUE_TESTS 0
|
|
||||||
#define configSTART_REGISTER_TESTS 0
|
|
||||||
#define configSTART_DELETE_SELF_TESTS 0
|
|
||||||
```
|
|
||||||
|
|
||||||
## Create and Run Register Tests
|
|
||||||
|
|
||||||
1. Fill the definitions of the following functions in the `RegTests.c` file
|
|
||||||
copied in the [Initial Setup](#Initial-Setup) step:
|
|
||||||
* `prvRegisterTest1Task`
|
|
||||||
* `prvRegisterTest2Task`
|
|
||||||
* `prvRegisterTest3Task`
|
|
||||||
* `prvRegisterTest4Task`
|
|
||||||
2. Define `configSTART_REGISTER_TESTS` to `1` in your `FreeRTOSConfig.h`:
|
|
||||||
```c
|
|
||||||
#define configSTART_REGISTER_TESTS 1
|
|
||||||
```
|
|
||||||
3. Build and run the register tests. The output should look like the following:
|
|
||||||
```
|
|
||||||
No errors
|
|
||||||
No errors
|
|
||||||
No errors
|
|
||||||
No errors
|
|
||||||
```
|
|
||||||
|
|
||||||
## Setup and Run Interrupt Nesting Tests
|
|
||||||
|
|
||||||
1. If your hardware **does not** support interrupt nesting, skip this section.
|
|
||||||
2. Fill the `void vInitialiseTimerForIntQueueTest( void )` function in the
|
|
||||||
`IntQueueTimer.c` file copied in the [Initial Setup](#Initial-Setup) step to
|
|
||||||
initialize and start a hardware timer. Make sure that the timer interrupt
|
|
||||||
runs at a logical priority less than or equal to `configMAX_SYSCALL_INTERRUPT_PRIORITY`.
|
|
||||||
The following is an example for ARM MPS2 which starts TIM0 timer:
|
|
||||||
```c
|
|
||||||
void vInitialiseTimerForIntQueueTest( void )
|
|
||||||
{
|
|
||||||
/* Clear interrupt. */
|
|
||||||
CMSDK_TIMER0->INTCLEAR = ( 1ul << 0 );
|
|
||||||
|
|
||||||
/* Reload value is slightly offset from the other timer. */
|
|
||||||
CMSDK_TIMER0->RELOAD = ( configCPU_CLOCK_HZ / tmrTIMER_0_FREQUENCY ) + 1UL;
|
|
||||||
CMSDK_TIMER0->CTRL = ( ( 1ul << 3 ) | ( 1ul << 0 ) );
|
|
||||||
|
|
||||||
NVIC_SetPriority( TIMER0_IRQn, configMAX_SYSCALL_INTERRUPT_PRIORITY );
|
|
||||||
NVIC_EnableIRQ( TIMER0_IRQn );
|
|
||||||
}
|
|
||||||
```
|
|
||||||
3. Either install `void IntQueueTestTimerHandler( void )` function as the timer
|
|
||||||
interrupt handler or call it from the timer interrupt handler of the above
|
|
||||||
timer. The following is an example for ARM MPS2 which calls
|
|
||||||
`IntQueueTestTimerHandler` from the TIM0 handler:
|
|
||||||
```c
|
|
||||||
void TIMER0_Handler( void )
|
|
||||||
{
|
|
||||||
/* Clear interrupt. */
|
|
||||||
CMSDK_TIMER0->INTCLEAR = ( 1ul << 0 );
|
|
||||||
|
|
||||||
IntQueueTestTimerHandler();
|
|
||||||
}
|
|
||||||
```
|
|
||||||
4. Define `configSTART_INTERRUPT_QUEUE_TESTS` to `1` in your `FreeRTOSConfig.h`:
|
|
||||||
```c
|
|
||||||
#define configSTART_INTERRUPT_QUEUE_TESTS 1
|
|
||||||
```
|
|
||||||
5. Build and run the tests. The output should look like the following:
|
|
||||||
```
|
|
||||||
No errors
|
|
||||||
No errors
|
|
||||||
No errors
|
|
||||||
No errors
|
|
||||||
```
|
|
||||||
|
|
||||||
## Running All Tests
|
|
||||||
|
|
||||||
1. Define all the `configSTART_<Test_Name>_TESTS` macros to `1` in your
|
|
||||||
`FreeRTOSConfig.h`.
|
|
||||||
2. Build and run the tests. The output should look like the following:
|
|
||||||
```
|
|
||||||
No errors
|
|
||||||
No errors
|
|
||||||
No errors
|
|
||||||
No errors
|
|
||||||
```
|
|
||||||
3. If you cannot fit all the tests in one binary because of Flash or RAM space,
|
|
||||||
you can run tests one by one or in groups by defining
|
|
||||||
`configSTART_<Test_Name>_TESTS` macros to `0` or `1` as needed.
|
|
||||||
|
|
||||||
## Add README
|
|
||||||
Add a `README.md` file in the project directory with the following information:
|
|
||||||
* Link to the hardware page.
|
|
||||||
* How to setup tool-chain.
|
|
||||||
* How to build and run the project.
|
|
||||||
* Any other relevant information.
|
|
||||||
167
FreeRTOS/Demo/ThirdParty/Template/RegTests.c
vendored
167
FreeRTOS/Demo/ThirdParty/Template/RegTests.c
vendored
@@ -1,167 +0,0 @@
|
|||||||
/*
|
|
||||||
* FreeRTOS V202104.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.
|
|
||||||
*
|
|
||||||
* http://www.FreeRTOS.org
|
|
||||||
* http://aws.amazon.com/freertos
|
|
||||||
*
|
|
||||||
* 1 tab == 4 spaces!
|
|
||||||
*/
|
|
||||||
|
|
||||||
/* Scheduler include files. */
|
|
||||||
#include "FreeRTOS.h"
|
|
||||||
#include "task.h"
|
|
||||||
|
|
||||||
/* Interface include files. */
|
|
||||||
#include "RegTests.h"
|
|
||||||
|
|
||||||
/* Tasks that implement register tests. */
|
|
||||||
static void prvRegisterTest1Task( void *pvParameters );
|
|
||||||
static void prvRegisterTest2Task( void *pvParameters );
|
|
||||||
static void prvRegisterTest3Task( void *pvParameters );
|
|
||||||
static void prvRegisterTest4Task( void *pvParameters );
|
|
||||||
|
|
||||||
/* Flag that will be latched to pdTRUE should any unexpected behaviour be
|
|
||||||
detected in any of the tasks. */
|
|
||||||
static volatile BaseType_t xErrorDetected = pdFALSE;
|
|
||||||
|
|
||||||
/* Counters that are incremented on each cycle of a test. This is used to
|
|
||||||
detect a stalled task - a test that is no longer running. */
|
|
||||||
static volatile uint32_t ulRegisterTest1Counter = 0;
|
|
||||||
static volatile uint32_t ulRegisterTest2Counter = 0;
|
|
||||||
static volatile uint32_t ulRegisterTest3Counter = 0;
|
|
||||||
static volatile uint32_t ulRegisterTest4Counter = 0;
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
static void prvRegisterTest1Task( void *pvParameters )
|
|
||||||
{
|
|
||||||
( void ) pvParameters;
|
|
||||||
|
|
||||||
for( ; ; )
|
|
||||||
{
|
|
||||||
/* 1. Fill the registers stored as part of task context with known values.
|
|
||||||
* 2. Force a context switch.
|
|
||||||
* 3. Verify that all the registers contain expected values.
|
|
||||||
* 4. If all the register contain expected values, increment ulRegisterTest1Counter.
|
|
||||||
*/
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
static void prvRegisterTest2Task( void *pvParameters )
|
|
||||||
{
|
|
||||||
( void ) pvParameters;
|
|
||||||
|
|
||||||
for( ; ; )
|
|
||||||
{
|
|
||||||
/* 1. Fill the registers stored as part of task context with known values.
|
|
||||||
* 2. Force a context switch.
|
|
||||||
* 3. Verify that all the registers contain expected values.
|
|
||||||
* 4. If all the register contain expected values, increment ulRegisterTest2Counter.
|
|
||||||
*/
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
static void prvRegisterTest3Task( void *pvParameters )
|
|
||||||
{
|
|
||||||
( void ) pvParameters;
|
|
||||||
|
|
||||||
for( ; ; )
|
|
||||||
{
|
|
||||||
/* 1. Fill the registers stored as part of task context with known values.
|
|
||||||
* 2. Force a context switch.
|
|
||||||
* 3. Verify that all the registers contain expected values.
|
|
||||||
* 4. If all the register contain expected values, increment ulRegisterTest3Counter.
|
|
||||||
*/
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
static void prvRegisterTest4Task( void *pvParameters )
|
|
||||||
{
|
|
||||||
( void ) pvParameters;
|
|
||||||
|
|
||||||
for( ; ; )
|
|
||||||
{
|
|
||||||
/* 1. Fill the registers stored as part of task context with known values.
|
|
||||||
* 2. Force a context switch.
|
|
||||||
* 3. Verify that all the registers contain expected values.
|
|
||||||
* 4. If all the register contain expected values, increment ulRegisterTest4Counter.
|
|
||||||
*/
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
void vStartRegisterTasks( UBaseType_t uxPriority )
|
|
||||||
{
|
|
||||||
BaseType_t ret;
|
|
||||||
|
|
||||||
ret = xTaskCreate( prvRegisterTest1Task, "RegTest1", configMINIMAL_STACK_SIZE, NULL, uxPriority, NULL );
|
|
||||||
configASSERT( ret == pdPASS );
|
|
||||||
|
|
||||||
ret = xTaskCreate( prvRegisterTest2Task, "RegTest2", configMINIMAL_STACK_SIZE, NULL, uxPriority, NULL );
|
|
||||||
configASSERT( ret == pdPASS );
|
|
||||||
|
|
||||||
ret = xTaskCreate( prvRegisterTest3Task, "RegTest3", configMINIMAL_STACK_SIZE, NULL, uxPriority, NULL );
|
|
||||||
configASSERT( ret == pdPASS );
|
|
||||||
|
|
||||||
ret = xTaskCreate( prvRegisterTest4Task, "RegTest4", configMINIMAL_STACK_SIZE, NULL, uxPriority, NULL );
|
|
||||||
configASSERT( ret == pdPASS );
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
|
|
||||||
BaseType_t xAreRegisterTasksStillRunning( void )
|
|
||||||
{
|
|
||||||
static uint32_t ulLastRegisterTest1Counter = 0, ulLastRegisterTest2Counter = 0;
|
|
||||||
static uint32_t ulLastRegisterTest3Counter = 0, ulLastRegisterTest4Counter = 0;
|
|
||||||
|
|
||||||
/* If the register test task is still running then we expect the loop
|
|
||||||
* counters to have incremented since this function was last called. */
|
|
||||||
if( ulLastRegisterTest1Counter == ulRegisterTest1Counter )
|
|
||||||
{
|
|
||||||
xErrorDetected = pdTRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
if( ulLastRegisterTest2Counter == ulRegisterTest2Counter )
|
|
||||||
{
|
|
||||||
xErrorDetected = pdTRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
if( ulLastRegisterTest3Counter == ulRegisterTest3Counter )
|
|
||||||
{
|
|
||||||
xErrorDetected = pdTRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
if( ulLastRegisterTest4Counter == ulRegisterTest4Counter )
|
|
||||||
{
|
|
||||||
xErrorDetected = pdTRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
ulLastRegisterTest1Counter = ulRegisterTest1Counter;
|
|
||||||
ulLastRegisterTest2Counter = ulRegisterTest2Counter;
|
|
||||||
ulLastRegisterTest3Counter = ulRegisterTest3Counter;
|
|
||||||
ulLastRegisterTest4Counter = ulRegisterTest4Counter;
|
|
||||||
|
|
||||||
/* Errors detected in the task itself will have latched xErrorDetected
|
|
||||||
* to true. */
|
|
||||||
return ( BaseType_t ) !xErrorDetected;
|
|
||||||
}
|
|
||||||
/*-----------------------------------------------------------*/
|
|
||||||
34
FreeRTOS/Demo/ThirdParty/Template/RegTests.h
vendored
34
FreeRTOS/Demo/ThirdParty/Template/RegTests.h
vendored
@@ -1,34 +0,0 @@
|
|||||||
/*
|
|
||||||
* FreeRTOS V202104.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.
|
|
||||||
*
|
|
||||||
* http://www.FreeRTOS.org
|
|
||||||
* http://aws.amazon.com/freertos
|
|
||||||
*
|
|
||||||
* 1 tab == 4 spaces!
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef REG_TEST_H
|
|
||||||
#define REG_TEST_H
|
|
||||||
|
|
||||||
void vStartRegisterTasks( UBaseType_t uxPriority );
|
|
||||||
BaseType_t xAreRegisterTasksStillRunning( void );
|
|
||||||
|
|
||||||
#endif /* REG_TEST_H */
|
|
||||||
589
FreeRTOS/Demo/ThirdParty/Template/TestRunner.c
vendored
589
FreeRTOS/Demo/ThirdParty/Template/TestRunner.c
vendored
File diff suppressed because it is too large
Load Diff
38
FreeRTOS/Demo/ThirdParty/Template/TestRunner.h
vendored
38
FreeRTOS/Demo/ThirdParty/Template/TestRunner.h
vendored
@@ -1,38 +0,0 @@
|
|||||||
/*
|
|
||||||
* FreeRTOS V202104.00
|
|
||||||
* Copyright (C) 2017 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.
|
|
||||||
*
|
|
||||||
* http://www.FreeRTOS.org
|
|
||||||
* http://aws.amazon.com/freertos
|
|
||||||
*
|
|
||||||
* 1 tab == 4 spaces!
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef TEST_RUNNER_H
|
|
||||||
#define TEST_RUNNER_H
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Start all the tests.
|
|
||||||
*
|
|
||||||
* Note that this function starts the scheduler and therefore, never returns.
|
|
||||||
*/
|
|
||||||
void vStartTests( void );
|
|
||||||
|
|
||||||
#endif /* TEST_RUNNER_H */
|
|
||||||
16
manifest.yml
16
manifest.yml
@@ -1,5 +1,5 @@
|
|||||||
name : "FreeRTOS"
|
name : "FreeRTOS"
|
||||||
version: "202012.00"
|
version: "202107.00"
|
||||||
description: "This is the standard distribution of FreeRTOS."
|
description: "This is the standard distribution of FreeRTOS."
|
||||||
|
|
||||||
dependencies:
|
dependencies:
|
||||||
@@ -108,18 +108,4 @@ dependencies:
|
|||||||
url: "https://github.com/FreeRTOS/coreSNTP"
|
url: "https://github.com/FreeRTOS/coreSNTP"
|
||||||
path: "FreeRTOS-Plus/Source/Application-Protocols/coreSNTP"
|
path: "FreeRTOS-Plus/Source/Application-Protocols/coreSNTP"
|
||||||
|
|
||||||
- name: "FreeRTOS-Community-Supported-Demos"
|
|
||||||
version: "e21b617"
|
|
||||||
repository:
|
|
||||||
type: "git"
|
|
||||||
url: "https://github.com/FreeRTOS/FreeRTOS-Community-Supported-Demos"
|
|
||||||
path: "FreeRTOS/Demo/ThirdParty/Community-Supported-Demos"
|
|
||||||
|
|
||||||
- name: "FreeRTOS-Partner-Supported-Demos"
|
|
||||||
version: "109ef4d"
|
|
||||||
repository:
|
|
||||||
type: "git"
|
|
||||||
url: "https://github.com/FreeRTOS/FreeRTOS-Partner-Supported-Demos"
|
|
||||||
path: "FreeRTOS/Demo/ThirdParty/Partner-Supported-Demos"
|
|
||||||
|
|
||||||
license: "MIT"
|
license: "MIT"
|
||||||
|
|||||||
Reference in New Issue
Block a user