SdFat
Public Member Functions | List of all members
SdLibSpiDriver Class Reference

SdLibSpiDriver - use standard SPI library. More...

#include <SdSpiArduinoDriver.h>

Public Member Functions

void activate ()
 
void begin (SdSpiConfig spiConfig)
 
void deactivate ()
 
uint8_t receive ()
 
uint8_t receive (uint8_t *buf, size_t n)
 
void select ()
 
void send (uint8_t data)
 
void send (const uint8_t *buf, size_t n)
 
void setHighSpeed (SdSpiConfig spiConfig)
 
void unselect ()
 

Detailed Description

SdLibSpiDriver - use standard SPI library.

Member Function Documentation

◆ activate()

void SdLibSpiDriver::activate ( )
inline

Activate SPI hardware.

◆ begin()

void SdLibSpiDriver::begin ( SdSpiConfig  spiConfig)
inline

Initialize the SPI bus.

Parameters
[in]spiConfigSD card configuration.

◆ deactivate()

void SdLibSpiDriver::deactivate ( )
inline

Deactivate SPI hardware.

◆ receive() [1/2]

uint8_t SdLibSpiDriver::receive ( )
inline

Receive a byte.

Returns
The byte.

◆ receive() [2/2]

uint8_t SdLibSpiDriver::receive ( uint8_t *  buf,
size_t  n 
)
inline

Receive multiple bytes.

Parameters
[out]bufBuffer to receive the data.
[in]nNumber of bytes to receive.
Returns
Zero for no error or nonzero error code.

◆ select()

void SdLibSpiDriver::select ( )
inline

Set CS low.

◆ send() [1/2]

void SdLibSpiDriver::send ( uint8_t  data)
inline

Send a byte.

Parameters
[in]dataByte to send

◆ send() [2/2]

void SdLibSpiDriver::send ( const uint8_t *  buf,
size_t  n 
)
inline

Send multiple bytes.

Parameters
[in]bufBuffer for data to be sent.
[in]nNumber of bytes to send.

◆ setHighSpeed()

void SdLibSpiDriver::setHighSpeed ( SdSpiConfig  spiConfig)
inline

Save high speed SPISettings after SD initialization.

Parameters
[in]spiConfigSPI options.

◆ unselect()

void SdLibSpiDriver::unselect ( )
inline

Set CS high.


The documentation for this class was generated from the following file: