#ifndef ADC_H
#define ADC_H

#define ADC_BUFFER_SIZE         5120
#define ADC_HALF_BUFFER_SIZE    2560

void initADC(void);
int readAN(unsigned char);
void startRecord(void);
void endRecord(void);
void continueRecord(void);

extern unsigned int adcCh;
extern unsigned int adcDataRecord;
extern unsigned int adcDataReady;
extern unsigned int adcDataReadyPtr;
extern unsigned int adcDataBufferSample;
extern unsigned int adcDropped;
extern unsigned int adcLoopBack;
extern unsigned int adcDataRecordReq;
extern int adcResult[8];
extern int adcIndex;

#endif
