libDaisy
Hardware Library for Daisy
Loading...
Searching...
No Matches
daisy::SpiHandle::Config Struct Reference

#include <spi.h>

Public Types

enum class  Peripheral {
  SPI_1 , SPI_2 , SPI_3 , SPI_4 ,
  SPI_5 , SPI_6
}
 
enum class  Mode { MASTER , SLAVE }
 
enum class  Direction { TWO_LINES , TWO_LINES_TX_ONLY , TWO_LINES_RX_ONLY , ONE_LINE }
 
enum class  ClockPolarity { LOW , HIGH }
 
enum class  ClockPhase { ONE_EDGE , TWO_EDGE }
 
enum class  NSS { SOFT , HARD_INPUT , HARD_OUTPUT }
 
enum class  BaudPrescaler {
  PS_2 , PS_4 , PS_8 , PS_16 ,
  PS_32 , PS_64 , PS_128 , PS_256
}
 

Public Member Functions

 Config ()
 

Public Attributes

struct { 
 
   Pin   sclk 
 
   Pin   miso 
 
   Pin   mosi 
 
   Pin   nss 
 
pin_config 
 
Peripheral periph
 
Mode mode
 
Direction direction
 
unsigned long datasize
 
ClockPolarity clock_polarity
 
ClockPhase clock_phase
 
NSS nss
 
BaudPrescaler baud_prescaler
 

Member Enumeration Documentation

◆ BaudPrescaler

Enumerator
PS_2 
PS_4 
PS_8 
PS_16 
PS_32 
PS_64 
PS_128 
PS_256 

◆ ClockPhase

Enumerator
ONE_EDGE 
TWO_EDGE 

◆ ClockPolarity

Enumerator
LOW 
HIGH 

◆ Direction

Enumerator
TWO_LINES 
TWO_LINES_TX_ONLY 
TWO_LINES_RX_ONLY 
ONE_LINE 

◆ Mode

Enumerator
MASTER 
SLAVE 

◆ NSS

Enumerator
SOFT 
HARD_INPUT 
HARD_OUTPUT 

◆ Peripheral

Enumerator
SPI_1 
SPI_2 
SPI_3 
SPI_4 
SPI_5 
SPI_6 

Constructor & Destructor Documentation

◆ Config()

daisy::SpiHandle::Config::Config ( )
inline

Member Data Documentation

◆ baud_prescaler

BaudPrescaler daisy::SpiHandle::Config::baud_prescaler

◆ clock_phase

ClockPhase daisy::SpiHandle::Config::clock_phase

◆ clock_polarity

ClockPolarity daisy::SpiHandle::Config::clock_polarity

◆ datasize

unsigned long daisy::SpiHandle::Config::datasize

◆ direction

Direction daisy::SpiHandle::Config::direction

◆ miso

Pin daisy::SpiHandle::Config::miso

&

◆ mode

Mode daisy::SpiHandle::Config::mode

◆ mosi

Pin daisy::SpiHandle::Config::mosi

&

◆ nss [1/2]

Pin daisy::SpiHandle::Config::nss

&

◆ nss [2/2]

NSS daisy::SpiHandle::Config::nss

◆ periph

Peripheral daisy::SpiHandle::Config::periph

◆ [struct]

struct { ... } daisy::SpiHandle::Config::pin_config

◆ sclk

Pin daisy::SpiHandle::Config::sclk

&


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