#ifndef bexus_sd_h
#define bexus_sd_h
#ifdef __cplusplus
 extern "C" {
#endif


/**----------------Includes-----------------------------*/
//#include "FreeRTOS.h"
#include "fatfs.h"
#include "sdio.h"
#include "string.h"
#include "bexus_variables.h"
#include "bexus_sysclock.h"
#include <string.h>
/**-----------------------------------------------------*/


/**----------------variables---------------------------*/
extern SD_HandleTypeDef hsd1;
extern HAL_SD_CardInfoTypeDef SDCardInfo1;
extern FRESULT status_SD;
extern FATFS SDFatFs;
extern FIL File_SD;
extern char * buff_write_SD;
extern char * buff_read_SD;
extern char buff_filename_SD[];
extern uint32_t  byteswritten_SD, bytesread_SD;
extern uint32_t File_Index;
extern uint32_t errorCount;
extern uint32_t Dateigrosse;
extern uint8_t sd_errortype;
/**-----------------------------------------------------*/


/**------------------functions--------------------------*/
void SD_FileName(void);
void Error_SD(int Error_Type_SD);
void SD_Init(void);
void SD_Write(void);
/**-----------------------------------------------------*/
#ifdef __cplusplus
}
#endif
#endif
