⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 davincihd_aic32.h

📁 用于dm6467 开发平台的uboot源码
💻 H
字号:
/*
 *  Copyright 2007 by Spectrum Digital Incorporated.
 *  All rights reserved. Property of Spectrum Digital Incorporated.
 */

/*
 *  AIC32 header file
 *
 */

#ifndef AIC32_
#define AIC32_

#ifdef __cplusplus
extern "C" {
#endif

#include "davincihd.h"
#include "davincihd_i2c.h"
#include "davincihd_mcasp.h"

/* ------------------------------------------------------------------------ *
 *  AIC32 ID                                                                *
 * ------------------------------------------------------------------------ */
#define AIC32_0                 0

/* ------------------------------------------------------------------------ *
 *  AIC32 I2C address                                                       *
 * ------------------------------------------------------------------------ */
#define AIC32_I2C_ADDR          0x18

/* ------------------------------------------------------------------------ *
 *  AIC32 Registers                                                         *
 * ------------------------------------------------------------------------ */
#define AIC32_NUMREGS           103
#define AIC32_PAGESELECT        0
#define AIC32_RESET             1

#define READONLY                0xaa00
#define RESERVED                0xffff

/* ------------------------------------------------------------------------ *
 *  AIC32 Data Structures                                                   *
 * ------------------------------------------------------------------------ */
typedef Int16 AIC32_Handle;

typedef struct {
    Uint16 regs[AIC32_NUMREGS];
} AIC32_Config;

/* ------------------------------------------------------------------------ *
 *  Prototypes                                                              *
 * ------------------------------------------------------------------------ */
/* Open/Close codec */
AIC32_Handle DAVINCIHD_AIC32_openCodec ( Uint32 id, AIC32_Config *config );
Int16        DAVINCIHD_AIC32_closeCodec( AIC32_Handle aic32 );

/* Get/Set registers */
Int16 DAVINCIHD_AIC32_rget     ( AIC32_Handle aic32, Uint16 regnum, Uint16* regval );
Int16 DAVINCIHD_AIC32_rset     ( AIC32_Handle aic32, Uint16 regnum, Uint16 regval );
Int16 DAVINCIHD_AIC32_rset_mask( AIC32_Handle aic32, Uint16 regnum, Uint16 regval, Uint8 mask );
Int16 DAVINCIHD_AIC32_config   ( AIC32_Handle aic32, AIC32_Config* config );

/* Read/Write 16-bit or 32-bit data */
Int16 DAVINCIHD_AIC32_read16   ( AIC32_Handle aic32, Int16* data16 );
Int16 DAVINCIHD_AIC32_read32   ( AIC32_Handle aic32, Int32* data32 );
Int16 DAVINCIHD_AIC32_write16  ( AIC32_Handle aic32, Int16 data16 );
Int16 DAVINCIHD_AIC32_write32  ( AIC32_Handle aic32, Int32 data32 );

/* Special functions */
void DAVINCIHD_AIC32_mute      ( AIC32_Handle aic32, Uint16 mode );

#ifdef __cplusplus
}
#endif

#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -