#ifndef SD_CARD_RAW_CBK_H
#define	SD_CARD_RAW_CBK_H

#ifdef	__cplusplus
extern "C" {
#endif

/**
 * This callback file shows the prototypes for the functions
 * that the user has to implement by themselves.
 * The callouts allow the user to use this library on any
 * microcontroller, microprocessor or platform.
 */

/**
 * Set the chip select value
 * @param value - 0 or 1
 */
void SD_Card_Chip_Select(uint8_t value);

/**
 * Send a byte through SPI and read a reply
 * @param data - byte to send
 * @returns uint8_t value
 */
uint8_t SD_Card_Write_SPI(uint8_t data);

/**
 * Report a problem with the SD card
 * @param line - source code line where the problem happened
 */
void SD_Card_Error(uint32_t line);

/**
 * Set a slow SPI clock in order to initialize the card
 */
void SD_Card_Set_Slow_Clock(void);

/**
 * Set the normal SPI clock speed
 */
void SD_Card_Set_Fast_Clock(void);

#ifdef	__cplusplus
}
#endif

#endif	/* SD_CARD_RAW_CBK_H */

