The official Mbed 2 C/C++ SDK provides the software platform and libraries to build your applications.

Dependents:   hello SerialTestv11 SerialTestv12 Sierpinski ... more

mbed 2

This is the mbed 2 library. If you'd like to learn about Mbed OS please see the mbed-os docs.

Committer:
Kojto
Date:
Wed Jul 19 16:46:19 2017 +0100
Revision:
147:a97add6d7e64
Parent:
145:64910690c574
Release 147 of the mbed library.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
Kojto 122:f9eeca106725 1 /**
Kojto 122:f9eeca106725 2 ******************************************************************************
Kojto 122:f9eeca106725 3 * @file stm32f4xx_hal_sai_ex.h
Kojto 122:f9eeca106725 4 * @author MCD Application Team
AnnaBridge 145:64910690c574 5 * @version V1.7.1
AnnaBridge 145:64910690c574 6 * @date 14-April-2017
Kojto 122:f9eeca106725 7 * @brief Header file of SAI Extension HAL module.
Kojto 122:f9eeca106725 8 ******************************************************************************
Kojto 122:f9eeca106725 9 * @attention
Kojto 122:f9eeca106725 10 *
AnnaBridge 145:64910690c574 11 * <h2><center>&copy; COPYRIGHT(c) 2017 STMicroelectronics</center></h2>
Kojto 122:f9eeca106725 12 *
Kojto 122:f9eeca106725 13 * Redistribution and use in source and binary forms, with or without modification,
Kojto 122:f9eeca106725 14 * are permitted provided that the following conditions are met:
Kojto 122:f9eeca106725 15 * 1. Redistributions of source code must retain the above copyright notice,
Kojto 122:f9eeca106725 16 * this list of conditions and the following disclaimer.
Kojto 122:f9eeca106725 17 * 2. Redistributions in binary form must reproduce the above copyright notice,
Kojto 122:f9eeca106725 18 * this list of conditions and the following disclaimer in the documentation
Kojto 122:f9eeca106725 19 * and/or other materials provided with the distribution.
Kojto 122:f9eeca106725 20 * 3. Neither the name of STMicroelectronics nor the names of its contributors
Kojto 122:f9eeca106725 21 * may be used to endorse or promote products derived from this software
Kojto 122:f9eeca106725 22 * without specific prior written permission.
Kojto 122:f9eeca106725 23 *
Kojto 122:f9eeca106725 24 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
Kojto 122:f9eeca106725 25 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
Kojto 122:f9eeca106725 26 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
Kojto 122:f9eeca106725 27 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
Kojto 122:f9eeca106725 28 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
Kojto 122:f9eeca106725 29 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
Kojto 122:f9eeca106725 30 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
Kojto 122:f9eeca106725 31 * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
Kojto 122:f9eeca106725 32 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
Kojto 122:f9eeca106725 33 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Kojto 122:f9eeca106725 34 *
Kojto 122:f9eeca106725 35 ******************************************************************************
Kojto 122:f9eeca106725 36 */
Kojto 122:f9eeca106725 37
Kojto 122:f9eeca106725 38 /* Define to prevent recursive inclusion -------------------------------------*/
Kojto 122:f9eeca106725 39 #ifndef __STM32F4xx_HAL_SAI_EX_H
Kojto 122:f9eeca106725 40 #define __STM32F4xx_HAL_SAI_EX_H
Kojto 122:f9eeca106725 41
Kojto 122:f9eeca106725 42 #ifdef __cplusplus
Kojto 122:f9eeca106725 43 extern "C" {
Kojto 122:f9eeca106725 44 #endif
Kojto 122:f9eeca106725 45
Kojto 122:f9eeca106725 46 /* Includes ------------------------------------------------------------------*/
Kojto 122:f9eeca106725 47 #include "stm32f4xx_hal_def.h"
Kojto 122:f9eeca106725 48
Kojto 122:f9eeca106725 49 /** @addtogroup STM32F4xx_HAL_Driver
Kojto 122:f9eeca106725 50 * @{
Kojto 122:f9eeca106725 51 */
Kojto 122:f9eeca106725 52
Kojto 122:f9eeca106725 53 /** @addtogroup SAIEx
Kojto 122:f9eeca106725 54 * @{
Kojto 122:f9eeca106725 55 */
Kojto 122:f9eeca106725 56
Kojto 122:f9eeca106725 57 #if defined(STM32F427xx) || defined(STM32F437xx) || defined(STM32F429xx) || defined(STM32F439xx) || \
AnnaBridge 145:64910690c574 58 defined(STM32F446xx) || defined(STM32F469xx) || defined(STM32F479xx) || defined(STM32F413xx) || \
AnnaBridge 145:64910690c574 59 defined(STM32F423xx)
Kojto 122:f9eeca106725 60
Kojto 122:f9eeca106725 61 /* Exported types ------------------------------------------------------------*/
Kojto 122:f9eeca106725 62 /* Exported constants --------------------------------------------------------*/
AnnaBridge 145:64910690c574 63 /** @defgroup SAI_Clock_Source SAI Clock Source
AnnaBridge 145:64910690c574 64 * @{
AnnaBridge 145:64910690c574 65 */
AnnaBridge 145:64910690c574 66 #if defined(STM32F413xx) || defined(STM32F423xx)
AnnaBridge 145:64910690c574 67 #define SAI_CLKSOURCE_PLLI2S 0x00000000U
AnnaBridge 145:64910690c574 68 #define SAI_CLKSOURCE_EXT 0x00100000U
AnnaBridge 145:64910690c574 69 #define SAI_CLKSOURCE_PLLR 0x00200000U
AnnaBridge 145:64910690c574 70 #define SAI_CLKSOURCE_HS 0x00300000U
AnnaBridge 145:64910690c574 71 #else
AnnaBridge 145:64910690c574 72 #define SAI_CLKSOURCE_PLLSAI 0x00000000U
AnnaBridge 145:64910690c574 73 #define SAI_CLKSOURCE_PLLI2S 0x00100000U
AnnaBridge 145:64910690c574 74 #define SAI_CLKSOURCE_EXT 0x00200000U
AnnaBridge 145:64910690c574 75 #define SAI_CLKSOURCE_NA 0x00400000U /*!< No applicable for STM32F446xx */
AnnaBridge 145:64910690c574 76 #endif
AnnaBridge 145:64910690c574 77
AnnaBridge 145:64910690c574 78
AnnaBridge 145:64910690c574 79 /**
AnnaBridge 145:64910690c574 80 * @}
AnnaBridge 145:64910690c574 81 */
AnnaBridge 145:64910690c574 82
Kojto 122:f9eeca106725 83 /* Exported functions --------------------------------------------------------*/
Kojto 122:f9eeca106725 84 /** @addtogroup SAIEx_Exported_Functions
Kojto 122:f9eeca106725 85 * @{
Kojto 122:f9eeca106725 86 */
Kojto 122:f9eeca106725 87
Kojto 122:f9eeca106725 88 /** @addtogroup SAIEx_Exported_Functions_Group1
Kojto 122:f9eeca106725 89 * @{
Kojto 122:f9eeca106725 90 */
Kojto 122:f9eeca106725 91
Kojto 122:f9eeca106725 92 /* Extended features functions ************************************************/
Kojto 122:f9eeca106725 93 void SAI_BlockSynchroConfig(SAI_HandleTypeDef *hsai);
Kojto 122:f9eeca106725 94 uint32_t SAI_GetInputClock(SAI_HandleTypeDef *hsai);
Kojto 122:f9eeca106725 95 /**
Kojto 122:f9eeca106725 96 * @}
Kojto 122:f9eeca106725 97 */
Kojto 122:f9eeca106725 98
Kojto 122:f9eeca106725 99 /**
Kojto 122:f9eeca106725 100 * @}
Kojto 122:f9eeca106725 101 */
Kojto 122:f9eeca106725 102 /* Private types -------------------------------------------------------------*/
Kojto 122:f9eeca106725 103 /* Private variables ---------------------------------------------------------*/
Kojto 122:f9eeca106725 104 /* Private constants ---------------------------------------------------------*/
Kojto 122:f9eeca106725 105 /* Private macros ------------------------------------------------------------*/
AnnaBridge 145:64910690c574 106 #if defined(STM32F413xx) || defined(STM32F423xx)
AnnaBridge 145:64910690c574 107 #define IS_SAI_CLK_SOURCE(SOURCE) (((SOURCE) == SAI_CLKSOURCE_PLLI2S) ||\
AnnaBridge 145:64910690c574 108 ((SOURCE) == SAI_CLKSOURCE_EXT)||\
AnnaBridge 145:64910690c574 109 ((SOURCE) == SAI_CLKSOURCE_PLLR)||\
AnnaBridge 145:64910690c574 110 ((SOURCE) == SAI_CLKSOURCE_HS))
AnnaBridge 145:64910690c574 111 #else
AnnaBridge 145:64910690c574 112 #define IS_SAI_CLK_SOURCE(SOURCE) (((SOURCE) == SAI_CLKSOURCE_PLLSAI) ||\
AnnaBridge 145:64910690c574 113 ((SOURCE) == SAI_CLKSOURCE_EXT)||\
AnnaBridge 145:64910690c574 114 ((SOURCE) == SAI_CLKSOURCE_PLLI2S)||\
AnnaBridge 145:64910690c574 115 ((SOURCE) == SAI_CLKSOURCE_NA))
AnnaBridge 145:64910690c574 116 #endif
Kojto 122:f9eeca106725 117 /* Private functions ---------------------------------------------------------*/
Kojto 122:f9eeca106725 118
AnnaBridge 145:64910690c574 119 #endif /* STM32F427xx || STM32F437xx || STM32F429xx || STM32F439xx || STM32F446xx || STM32F469xx || STM32F479xx || STM32F413xx || STM32F423xx */
Kojto 122:f9eeca106725 120 /**
Kojto 122:f9eeca106725 121 * @}
Kojto 122:f9eeca106725 122 */
Kojto 122:f9eeca106725 123
Kojto 122:f9eeca106725 124 /**
Kojto 122:f9eeca106725 125 * @}
Kojto 122:f9eeca106725 126 */
Kojto 122:f9eeca106725 127
Kojto 122:f9eeca106725 128 #ifdef __cplusplus
Kojto 122:f9eeca106725 129 }
Kojto 122:f9eeca106725 130 #endif
Kojto 122:f9eeca106725 131
Kojto 122:f9eeca106725 132 #endif /* __STM32F4xx_HAL_SAI_EX_H */
Kojto 122:f9eeca106725 133
Kojto 122:f9eeca106725 134 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/