Update comments in Atmel Studio CreateProjectDirectoryStructure.bat files to remove references to replace references to Eclipse with references to Atmel Studio.

Update the tickless idle implementations that use up counters for tick interrupt generate to ensure they remain in low power mode for the desired time instead of one tick less than the desired time.
This commit is contained in:
Richard Barry 2013-05-09 09:56:04 +00:00
parent e08966c7e8
commit fb9662009a
7 changed files with 33 additions and 56 deletions

View File

@ -1,11 +1,6 @@
REM This file should be executed from the command line prior to the first
REM build. It will be necessary to refresh the Eclipse project once the
REM .bat file has been executed (normally just press F5 to refresh).
REM Copies all the required files from their location within the standard
REM FreeRTOS directory structure to under the Eclipse project directory.
REM This permits the Eclipse project to be used in 'managed' mode and without
REM having to setup any linked resources.
REM build. Copies all the required files from their location within the standard
REM FreeRTOS directory structure to under the Atmel Studio project directory.
REM Standard paths
SET FREERTOS_SOURCE=..\..\Source
@ -21,9 +16,9 @@ IF EXIST src\asf\thirdparty\FreeRTOS Goto END
MD src\asf\thirdparty\FreeRTOS\portable
MD src\asf\thirdparty\FreeRTOS\portable\GCC
MD src\asf\thirdparty\FreeRTOS\portable\GCC\ARM_CM3
MD src\asf\thirdparty\FreeRTOS\portable\MemMang
MD src\asf\thirdparty\FreeRTOS\portable\MemMang
MD src\Common-Demo-Source\include
REM Copy the core kernel files into the project directory
copy %FREERTOS_SOURCE%\tasks.c src\asf\thirdparty\FreeRTOS
copy %FREERTOS_SOURCE%\queue.c src\asf\thirdparty\FreeRTOS
@ -32,10 +27,10 @@ IF EXIST src\asf\thirdparty\FreeRTOS Goto END
REM Copy the common header files into the project directory
copy %FREERTOS_SOURCE%\include\*.* src\asf\thirdparty\FreeRTOS\include
REM Copy the portable layer files into the project directory
copy %FREERTOS_SOURCE%\portable\GCC\ARM_CM3\*.* src\asf\thirdparty\FreeRTOS\portable\GCC\ARM_CM3
REM Copy the memory allocation files into the project directory
copy %FREERTOS_SOURCE%\portable\MemMang\heap_4.c src\asf\thirdparty\FreeRTOS\portable\MemMang
@ -51,8 +46,8 @@ IF EXIST src\asf\thirdparty\FreeRTOS Goto END
copy %COMMON_SOURCE%\recmutex.c src\Common-Demo-Source
copy %COMMON_SOURCE%\countsem.c src\Common-Demo-Source
copy %COMMON_SOURCE%\integer.c src\Common-Demo-Source
REM Copy the common demo file headers.
copy %COMMON_INCLUDE%\*.h src\Common-Demo-Source\include
: END

View File

@ -1,11 +1,6 @@
REM This file should be executed from the command line prior to the first
REM build. It will be necessary to refresh the Eclipse project once the
REM .bat file has been executed (normally just press F5 to refresh).
REM Copies all the required files from their location within the standard
REM FreeRTOS directory structure to under the Eclipse project directory.
REM This permits the Eclipse project to be used in 'managed' mode and without
REM having to setup any linked resources.
REM build. Copies all the required files from their location within the standard
REM FreeRTOS directory structure to under the Atmel Studio project directory.
REM Standard paths
SET FREERTOS_SOURCE=..\..\Source
@ -21,9 +16,9 @@ IF EXIST src\asf\thirdparty\FreeRTOS Goto END
MD src\asf\thirdparty\FreeRTOS\portable
MD src\asf\thirdparty\FreeRTOS\portable\GCC
MD src\asf\thirdparty\FreeRTOS\portable\GCC\ARM_CM3
MD src\asf\thirdparty\FreeRTOS\portable\MemMang
MD src\asf\thirdparty\FreeRTOS\portable\MemMang
MD src\Common-Demo-Source\include
REM Copy the core kernel files into the project directory
copy %FREERTOS_SOURCE%\tasks.c src\asf\thirdparty\FreeRTOS
copy %FREERTOS_SOURCE%\queue.c src\asf\thirdparty\FreeRTOS
@ -32,10 +27,10 @@ IF EXIST src\asf\thirdparty\FreeRTOS Goto END
REM Copy the common header files into the project directory
copy %FREERTOS_SOURCE%\include\*.* src\asf\thirdparty\FreeRTOS\include
REM Copy the portable layer files into the project directory
copy %FREERTOS_SOURCE%\portable\GCC\ARM_CM3\*.* src\asf\thirdparty\FreeRTOS\portable\GCC\ARM_CM3
REM Copy the memory allocation files into the project directory
copy %FREERTOS_SOURCE%\portable\MemMang\heap_4.c src\asf\thirdparty\FreeRTOS\portable\MemMang
@ -51,8 +46,8 @@ IF EXIST src\asf\thirdparty\FreeRTOS Goto END
copy %COMMON_SOURCE%\recmutex.c src\Common-Demo-Source
copy %COMMON_SOURCE%\countsem.c src\Common-Demo-Source
copy %COMMON_SOURCE%\integer.c src\Common-Demo-Source
REM Copy the common demo file headers.
copy %COMMON_INCLUDE%\*.h src\Common-Demo-Source\include
: END

View File

@ -134,7 +134,7 @@ static volatile uint32_t ulTickFlag = pdFALSE;
following variable offsets the AST counter alarm value by the number of AST
counts that would typically be missed while the counter was stopped to compensate
for the lost time. _RB_ Value needs calculating correctly. */
static uint32_t ulStoppedTimerCompensation = 10 / ( configCPU_CLOCK_HZ / configSYSTICK_CLOCK_HZ );
static uint32_t ulStoppedTimerCompensation = 2 / ( configCPU_CLOCK_HZ / configSYSTICK_CLOCK_HZ );
/*-----------------------------------------------------------*/
@ -274,10 +274,8 @@ enum sleepmgr_mode xSleepMode;
}
/* Calculate the reload value required to wait xExpectedIdleTime tick
periods. -1 is used because this code will execute part way through one of
the tick periods, and the fraction of a tick period is accounted for
later. */
ulAlarmValue = ( ulAlarmValueForOneTick * ( xExpectedIdleTime - 1UL ) );
periods. */
ulAlarmValue = ulAlarmValueForOneTick * xExpectedIdleTime;
if( ulAlarmValue > ulStoppedTimerCompensation )
{
/* Compensate for the fact that the AST is going to be stopped

View File

@ -1,11 +1,6 @@
REM This file should be executed from the command line prior to the first
REM build. It will be necessary to refresh the Eclipse project once the
REM .bat file has been executed (normally just press F5 to refresh).
REM Copies all the required files from their location within the standard
REM FreeRTOS directory structure to under the Eclipse project directory.
REM This permits the Eclipse project to be used in 'managed' mode and without
REM having to setup any linked resources.
REM build. Copies all the required files from their location within the standard
REM FreeRTOS directory structure to under the Atmel Studio project directory.
REM Standard paths
SET FREERTOS_SOURCE=..\..\Source
@ -21,9 +16,9 @@ IF EXIST src\asf\thirdparty\FreeRTOS Goto END
MD src\asf\thirdparty\FreeRTOS\portable
MD src\asf\thirdparty\FreeRTOS\portable\GCC
MD src\asf\thirdparty\FreeRTOS\portable\GCC\ARM_CM3
MD src\asf\thirdparty\FreeRTOS\portable\MemMang
MD src\asf\thirdparty\FreeRTOS\portable\MemMang
MD src\Common-Demo-Source\include
REM Copy the core kernel files into the project directory
copy %FREERTOS_SOURCE%\tasks.c src\asf\thirdparty\FreeRTOS
copy %FREERTOS_SOURCE%\queue.c src\asf\thirdparty\FreeRTOS
@ -32,10 +27,10 @@ IF EXIST src\asf\thirdparty\FreeRTOS Goto END
REM Copy the common header files into the project directory
copy %FREERTOS_SOURCE%\include\*.* src\asf\thirdparty\FreeRTOS\include
REM Copy the portable layer files into the project directory
copy %FREERTOS_SOURCE%\portable\GCC\ARM_CM3\*.* src\asf\thirdparty\FreeRTOS\portable\GCC\ARM_CM3
REM Copy the memory allocation files into the project directory
copy %FREERTOS_SOURCE%\portable\MemMang\heap_4.c src\asf\thirdparty\FreeRTOS\portable\MemMang
@ -52,8 +47,8 @@ IF EXIST src\asf\thirdparty\FreeRTOS Goto END
copy %COMMON_SOURCE%\countsem.c src\Common-Demo-Source
copy %COMMON_SOURCE%\integer.c src\Common-Demo-Source
copy %COMMON_SOURCE%\QueueSet.c src\Common-Demo-Source
REM Copy the common demo file headers.
copy %COMMON_INCLUDE%\*.h src\Common-Demo-Source\include
: END

View File

@ -580,10 +580,8 @@ static void prvSetupTimerInterrupt( void )
}
/* Calculate the reload value required to wait xExpectedIdleTime tick
periods. -1 is used because this code will execute part way through
one of the tick periods, and the fraction of a tick period is accounted
for later. */
ulMatchValue = ( ulMatchValueForOneTick * ( xExpectedIdleTime - 1UL ) );
periods. */
ulMatchValue = ulMatchValueForOneTick * xExpectedIdleTime;
if( ulMatchValue > ulStoppedTimerCompensation )
{
/* Compensate for the fact that the CMT is going to be stopped

View File

@ -424,10 +424,8 @@ static void prvSetupTimerInterrupt( void )
}
/* Calculate the reload value required to wait xExpectedIdleTime tick
periods. -1 is used because this code will execute part way through
one of the tick periods, and the fraction of a tick period is accounted
for later. */
ulMatchValue = ( ulMatchValueForOneTick * ( xExpectedIdleTime - 1UL ) );
periods. */
ulMatchValue = ulMatchValueForOneTick * xExpectedIdleTime;
if( ulMatchValue > ulStoppedTimerCompensation )
{
/* Compensate for the fact that the CMT is going to be stopped

View File

@ -554,10 +554,8 @@ static void prvSetupTimerInterrupt( void )
}
/* Calculate the reload value required to wait xExpectedIdleTime tick
periods. -1 is used because this code will execute part way through
one of the tick periods, and the fraction of a tick period is accounted
for later. */
ulMatchValue = ( ulMatchValueForOneTick * ( xExpectedIdleTime - 1UL ) );
periods. */
ulMatchValue = ulMatchValueForOneTick * xExpectedIdleTime;
if( ulMatchValue > ulStoppedTimerCompensation )
{
/* Compensate for the fact that the CMT is going to be stopped