A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/stm32duino/STM32SD below:

stm32duino/STM32SD: Enables reading and writing on SD card using SD card slot of the STM32 Board.

STM32 SD library for Arduino

With an STM32 board with SD card slot availability, this library enables reading and writing on SD card using SD card slot of a STM32 board (NUCLEO, DISCOVERY, ...). This library is for SD card slots connected to the SDIO-/SDMMC-hardware of the processor. For slots connected to SPI-hardware use the standard Arduino SD library.

This library follow Arduino API.

For more information about it, please visit: http://www.arduino.cc/en/Reference/SD

This library is based on FatFs, a generic FAT file system module for small embedded systems. http://elm-chan.org/fsw/ff

The FatFs has been ported as Arduino library here. The STM32SD library depends on it.

The FatFs has several user defined options, which is specified from within the ffconf.h file.

This library provides a default user defined options file named ffconf_default.h.

User can provide his own defined options by adding his configuration in a file named ffconf_custom.h at sketch level or in variant folder.

Some default definitions can be overridden using:

SDIO/SDMMC pins definition

Important

Since STM32 core v2.6.0, the PinMap_SD[] array defined in the PeripheralPins*.c has been split per signals:

PinMap_SD_CK[]
PinMap_SD_DATA0[]
PinMap_SD_DATA1[]
PinMap_SD_DATA2[]
PinMap_SD_DATA3[]
PinMap_SD_DATA4[]
PinMap_SD_DATA5[]
PinMap_SD_DATA6[]
PinMap_SD_DATA7[]
/* Only for SDMMC */
PinMap_SD_CKIN[]
PinMap_SD_CDIR[]
PinMap_SD_D0DIR[]
PinMap_SD_D123DIR[]

This allows to define the SDIO/SDMMC pins to use instead of using all the pins defined in the old array. By default, if no pins are explicitly defined, the first one from each array is used.

  Sd2Card card;
  card.setDx(PE12, PE13, PE14, PE15);
  card.setCMD(PB_14); // using PinName
  card.setCK(PB15);
  card.init();

or

  SD.setDx(PE12, PE13, PE14, PE15);
  SD.setCMD(PB14);
  SD.setCK(PB_15); // using PinName
  SD.begin();

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4