📄 i2s_control.h
字号:
/* Copyright ?1999,2000,2001 Intel Corp. */
/*++
Module Name: aclinkcontrol.h
Abstract:
Intel XSC1 StrongARM platform header file definitions for the I2S Control routines.
Notes:
$Date: 4/29/03 2:30p $
--*/
#ifndef __I2S_CONTROL_H__
#define __I2S_CONTROL_H__
#ifdef __cplusplus
extern "C"{
#endif
//define codec device ID of I2C interface
#if RT_ALC5620 //support ALC5620,ALC5624
//ALC5620 I2C's device ID is 0x30(A1 pull low,the Device ID=0x30,A1 pull high the device ID=0x32)
#define DEV_AUDIO (0x30>>1)
#elif RT_ALC5621 //support ALC5621,ALC5622,ALC5623
#define DEV_AUDIO (0x34>>1)
#endif
#define SR_48000 48000
#define SR_44100 44100
#define SR_22050 22050
#define SR_16000 16000
#define SR_11025 11025
#define SR_8000 8000
#define I2C_MUTEX_NAME TEXT("I2C_CONTROL")
static HANDLE hI2cControlMutex = NULL;
BOOL ReleaseI2CLock(void);
BOOL GetI2CLock(void);
BOOL UnConfigureI2CControl(void);
BOOL ConfigureI2CControl(void);
BOOL UnConfigureI2SControl(void);
BOOL ConfigureI2SControl(void);
BOOL WriteI2SCodec(UINT8 Offset, UINT16 Data, UINT8 DevId);
BOOL ReadI2SCodec(UINT8 Offset, UINT16 *pData, UINT8 DevId);
BOOL WriteI2SCodecRaw(UINT8 Offset, UINT16 Data, UINT8 DevId);
BOOL ReadI2SCodecRaw(UINT8 Offset, UINT16 *pData, UINT8 DevId);
BOOL AllocateI2SResources(void);
BOOL InitializeI2S(BOOL);
BOOL InitializeI2C(BOOL);
BOOL DeInitializeI2S(BOOL);
BOOL SetI2sSampleRate(UINT16 SampleRate);
BOOL GetI2sSampleRate(UINT16* SampleRate);
BOOL DeAllocateI2SResources(void);
#ifdef __cplusplus
}
#endif
#endif //__ACLINKCONTORL_H__
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -