Texas Instruments

Table of Contents

Example Summary

Sample application to read and write data onto an SD Card (SPI interface).

Peripherals Exercised

Resources & Jumper Settings

Please refer to the development board’s specific Settings and Resources section in the Getting Started Guide. For convenience, a short summary is also shown below.

Development board Notes
CC3200 Requires an external SD Card boosterpack
EK-TM4C123GXL ^
DK-TM4C129X It uses the onboard SD Card slot.
EK-TM4C1294XL Requires an external SD Card boosterpack
EK-TM4C129EXL ^
MSP-EXP430F5529LP Requires an external SD Card boosterpack
MSP-EXP430FR5969 ^
MSP-EXP430FR6989 ^
MSP-EXP432P401R ^
MSP-EXP430FR5994 It uses the onboard SD Card slot.
TMDXDOCK28M36 It uses the onboard SD Card slot.
TMDXDOCKH52C1 It uses the onboard SD Card slot. Connectivity Bank 22-25: B-C position (SD card slot)

Fields left blank have no specific settings for this example. For fields containing ^, see the above entry for details

Example Usage

Application Design Details

This application uses one task:

The fatSDTask performs the following actions:

  1. Creates and initializes the SDSPI driver object.

  2. Open the input.txt file. If not found, create the file for reading and writing. Write the default message to the file.

  3. Open the output.txt file. Content will be overwritten if found.

  4. Copy the contents of input.txt to output.txt. Close both files afterwards.

  5. Open output.txt, read the file and print the contents to System_printf.

  6. The output.txt file and SDSPI driver are closed and the example is terminated.

References