SD Card Interface
R2026bSpecify the SD card interface used for MAT-file logging on supported hardware
Since R2026b
Model Configuration Pane: Hardware Implementation / Hardware board settings / Target hardware resources / SPI properties
Description
Use this parameter to control how the application accesses the SD card for MAT-file logging. This parameter allows you to choose between using the on-board SD card hardware or an external SD card module connected through serial peripheral interface (SPI).
The on-board SD card interface uses the fixed secure digital input/output (SDIO) connection on Teensy 4.1 hardware whereas an external SD card module uses the SPI peripheral.
Dependencies
To enable this parameter, set Hardware board to
Teensy 4.1 (Arduino Compatible).When you set SD Card Interface to
On-board SD Card Interface, the SD Card SPI CS Pin parameter is read-only. The chip-select pin uses a fixed internal value and cannot be modified.When you set SD Card Interface to
External SD Card Module, you can specify the chip select pin used by the external SD card module in the SD Card SPI CS Pin parameter. Refer to the pin mapping table for the corresponding block to determine the correct chip select pin for your target hardware.
Settings
On-board SD Card Interface | External SD Card ModuleConfigure the SD Card Interface parameter based on the SD card hardware available on your Teensy board. Teensy 4.1 supports both on‑board and external SD card interfaces while Teensy 4.0 supports external SD card modules only. When using an external SD card module, make sure that the SD Card SPI CS pin matches the wiring of your target hardware.
Programmatic Use
| No programmatic use is available. |
Version History
Introduced in R2026b