#ifndef _AD5940_PORT_H_
#define _AD5940_PORT_H_

#include "sdkconfig.h"
#include <stdint.h>

// Pin Definitions for ESP32-S3-Zero
#define AD5940_MISO_PIN 1
#define AD5940_CS_PIN 2
#define AD5940_SCK_PIN 4
#define AD5940_MOSI_PIN 5
#define AD5940_GP0INT_PIN 6
#define AD5940_RST_PIN 7

// Function Prototypes
uint32_t AD5940_MCUResourceInit(void *pCfg);
void AD5940_CsClr(void);
void AD5940_CsSet(void);
void AD5940_RstSet(void);
void AD5940_RstClr(void);
void AD5940_Delay10us(uint32_t time);
void AD5940_ReadWriteNBytes(unsigned char *pSendBuffer,
                            unsigned char *pRecvBuff, unsigned long length);
uint32_t AD5940_GetMCUIntFlag(void);
uint32_t AD5940_ClrMCUIntFlag(void);

#endif // _AD5940_PORT_H_
