#ifndef _ISD2260_H_
#define _ISD2260_H_

#include "Simulated_SPI_Master.h"

/******************************************************************************
命令列表
******************************************************************************/
#define   ISD_STOP_LP_CODE      0x2E
#define   ISD_PLAY_VP_LP_CODE   0xA4
#define   ISD_STOP_CODE         0x2A
#define   ISD_PLAY_VP_CODE      0xA6
#define   ISD_EXE_VM_CODE       0xB0
#define   ISD_READ_STATUS_CODE  0x40
#define   ISD_READ_INT_CODE     0x46
#define   ISD_READ_ID_CODE      0x48
#define   ISD_DIG_READ_CODE     0xA2
#define   ISD_DIG_WRITE_CODE    0xA0
#define   ISD_CHIP_ERASE_CODE   0x26
#define   ISD_CHECK_SUM_CODE    0xF2
#define   ISD_PWR_UP_CODE       0x10
#define   ISD_PWR_DN_CODE       0x12
#define   ISD_WR_CFG_REG_CODE   0xB8
#define   ISD_RD_CFG_REG_CODE   0xBA
#define   ISD_RESET_CODE        0x14

/******************************************************************************
声音播放通道列表
******************************************************************************/
#define   ISD_CHANNEL_0         0x00
#define   ISD_CHANNEL_1         0x01
#define   ISD_CHANNEL_2         0x02
#define   ISD_CHANNEL_ALL       0x03

/******************************************************************************
函数声明
******************************************************************************/
void ISD_Init(void);
void ISD_Power_Up(void);
void ISD_Power_Down(void);
void ISD_Play_Vp(uint16_t Index);
void ISD_Stop(void);
void ISD_Play_Vp_Loop(uint16_t Index, uint16_t LoopCnt);
//void ISD_Stop_Loop(void);
void ISD_Set_Volume(uint8_t Volume);
void ISD_Select_Channel(uint8_t ChNum);

#endif
