Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: ST_I2S X_NUCLEO_COMMON
Dependents: HelloWorld_CCA01M1 HelloWorld_CCA01M1_mbedOS HelloWorld_CCA01M1_mbedOS Karaoke_CCA01M1_CCA02M1_mbedOS ... more
Fork of X_NUCLEO_CCA01M1 by
sound_terminal.h
00001 /** 00002 ****************************************************************************** 00003 * @file sound_terminal.h 00004 * @author Central Labs 00005 * @version V1.0.0 00006 * @date 18-August-2015 00007 * @brief This file contains all the functions prototypes for the Sound Terminal driver. 00008 ****************************************************************************** 00009 * @attention 00010 * 00011 * <h2><center>© COPYRIGHT(c) 2014 STMicroelectronics</center></h2> 00012 * 00013 * Redistribution and use in source and binary forms, with or without modification, 00014 * are permitted provided that the following conditions are met: 00015 * 1. Redistributions of source code must retain the above copyright notice, 00016 * this list of conditions and the following disclaimer. 00017 * 2. Redistributions in binary form must reproduce the above copyright notice, 00018 * this list of conditions and the following disclaimer in the documentation 00019 * and/or other materials provided with the distribution. 00020 * 3. Neither the name of STMicroelectronics nor the names of its contributors 00021 * may be used to endorse or promote products derived from this software 00022 * without specific prior written permission. 00023 * 00024 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 00025 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 00026 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 00027 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 00028 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 00029 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 00030 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 00031 * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 00032 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 00033 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 00034 * 00035 ****************************************************************************** 00036 */ 00037 00038 00039 /* Define to prevent recursive inclusion -------------------------------------*/ 00040 00041 #ifndef __SOUND_TERMINAL_H 00042 #define __SOUND_TERMINAL_H 00043 00044 #ifdef __cplusplus 00045 extern "C" { 00046 #endif 00047 00048 00049 /* Includes ------------------------------------------------------------------*/ 00050 00051 #include "component_def.h" 00052 #include <stdint.h> 00053 00054 00055 /** @addtogroup BSP 00056 * @{ 00057 */ 00058 00059 /** @addtogroup Components 00060 * @{ 00061 */ 00062 00063 /** @addtogroup SOUND_TERMINAL 00064 * @{ 00065 */ 00066 00067 /** @defgroup SOUND_TERMINAL_Exported_Types 00068 * @{ 00069 */ 00070 00071 /** 00072 * @brief SoundTerminal driver structure definition 00073 */ 00074 typedef struct 00075 { 00076 /* General */ 00077 status_t (*Init)(void *handle, void *init); 00078 status_t (*ReadID)(void *handle, uint8_t *id); 00079 int32_t (*DeInit)(void); 00080 00081 /* Specific */ 00082 int32_t (*Play)(uint16_t *pData, uint16_t size); 00083 int32_t (*Pause)(void); 00084 int32_t (*Resume)(void); 00085 int32_t (*Stop)(void); 00086 int32_t (*PowerOn)(void); 00087 int32_t (*PowerOff)(void); 00088 int32_t (*Reset)(void); 00089 int32_t (*SetEq)(uint8_t ram_block, uint8_t filter_number, uint32_t *filter_values); 00090 int32_t (*SetTone)(uint8_t tone_gain); 00091 int32_t (*SetMute)(uint8_t channel, uint8_t state); 00092 int32_t (*SetVolume)(uint8_t channel, uint8_t value); 00093 int32_t (*SetFrequency)(uint32_t audio_freq); 00094 int32_t (*SetDSPOption)(uint8_t option, uint8_t state); 00095 } SOUND_TERMINAL_vt_t; 00096 00097 #ifdef __cplusplus 00098 } 00099 #endif 00100 00101 #endif /* __SOUND_TERMINAL_H */ 00102 00103 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
Generated on Sat Jul 23 2022 08:56:13 by
