|
|
@@ -21,7 +21,7 @@
|
|
|
#include "unity.h"
|
|
|
#include "driver/gpio.h"
|
|
|
#include "soc/soc_caps.h"
|
|
|
-#ifdef SOC_SDMMC_HOST_SUPPORTED
|
|
|
+#if SOC_SDMMC_HOST_SUPPORTED
|
|
|
#include "driver/sdmmc_host.h"
|
|
|
#endif
|
|
|
#include "driver/sdspi_host.h"
|
|
|
@@ -83,7 +83,7 @@ TEST_CASE("MMC_RSP_BITS", "[sd]")
|
|
|
TEST_ASSERT_EQUAL_HEX32(0x11, MMC_RSP_BITS(data, 59, 5));
|
|
|
}
|
|
|
|
|
|
-#ifdef SOC_SDMMC_HOST_SUPPORTED
|
|
|
+#if SOC_SDMMC_HOST_SUPPORTED
|
|
|
|
|
|
static void probe_sd(int slot, int width, int freq_khz, int ddr)
|
|
|
{
|
|
|
@@ -328,7 +328,7 @@ __attribute__((unused)) static void read_write_test(sdmmc_card_t* card)
|
|
|
do_single_write_read_test(card, card->csd.capacity/2, 128, 1);
|
|
|
}
|
|
|
|
|
|
-#ifdef SOC_SDMMC_HOST_SUPPORTED
|
|
|
+#if SOC_SDMMC_HOST_SUPPORTED
|
|
|
void test_sd_rw_blocks(int slot, int width)
|
|
|
{
|
|
|
sdmmc_host_t config = SDMMC_HOST_DEFAULT();
|
|
|
@@ -403,7 +403,7 @@ TEST_CASE("SDMMC read/write test (SD slot 1, in SPI mode)", "[sdspi][test_env=UT
|
|
|
}
|
|
|
#endif //DISABLED_FOR_TARGETS(ESP32S2)
|
|
|
|
|
|
-#ifdef SOC_SDMMC_HOST_SUPPORTED
|
|
|
+#if SOC_SDMMC_HOST_SUPPORTED
|
|
|
TEST_CASE("reads and writes with an unaligned buffer", "[sd][test_env=UT_T1_SDMODE]")
|
|
|
{
|
|
|
sd_test_board_power_on();
|
|
|
@@ -467,7 +467,7 @@ __attribute__((unused)) static void test_cd_input(int gpio_cd_num, const sdmmc_h
|
|
|
free(card);
|
|
|
}
|
|
|
|
|
|
-#ifdef SOC_SDMMC_HOST_SUPPORTED
|
|
|
+#if SOC_SDMMC_HOST_SUPPORTED
|
|
|
TEST_CASE("CD input works in SD mode", "[sd][test_env=UT_T1_SDMODE]")
|
|
|
{
|
|
|
sd_test_board_power_on();
|
|
|
@@ -541,7 +541,7 @@ __attribute__((unused)) static void test_wp_input(int gpio_wp_num, const sdmmc_h
|
|
|
free(card);
|
|
|
}
|
|
|
|
|
|
-#ifdef SOC_SDMMC_HOST_SUPPORTED
|
|
|
+#if SOC_SDMMC_HOST_SUPPORTED
|
|
|
TEST_CASE("WP input works in SD mode", "[sd][test_env=UT_T1_SDMODE]")
|
|
|
{
|
|
|
sd_test_board_power_on();
|