summaryrefslogtreecommitdiffstatshomepage
path: root/stm/lib
diff options
context:
space:
mode:
Diffstat (limited to 'stm/lib')
-rw-r--r--stm/lib/stm324x7i_eval.c2
-rw-r--r--stm/lib/stm324x7i_eval.h2
-rw-r--r--stm/lib/stm324x7i_eval_sdio_sd.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/stm/lib/stm324x7i_eval.c b/stm/lib/stm324x7i_eval.c
index fa9fff31fe..c1be681f1d 100644
--- a/stm/lib/stm324x7i_eval.c
+++ b/stm/lib/stm324x7i_eval.c
@@ -122,7 +122,7 @@ void SD_LowLevel_Init(void)
GPIO_Init(GPIOC, &GPIO_InitStructure);
/*!< Configure SD_SPI_DETECT_PIN pin: SD Card detect pin */
-#if defined(PYBOARD)
+#if defined(PYBOARD3)
// dpgeorge: PYBv2-v3: switch is normally open, connected to VDD when card inserted
GPIO_InitStructure.GPIO_Pin = SD_DETECT_PIN;
GPIO_InitStructure.GPIO_Speed = GPIO_Speed_2MHz; // needs to be 2MHz due to restrictions on PC13
diff --git a/stm/lib/stm324x7i_eval.h b/stm/lib/stm324x7i_eval.h
index a7df96acb0..9adeecb16e 100644
--- a/stm/lib/stm324x7i_eval.h
+++ b/stm/lib/stm324x7i_eval.h
@@ -41,7 +41,7 @@
/**
* @brief SD FLASH SDIO Interface
*/
-#if defined(PYBOARD)
+#if defined(PYBOARD3)
#define SD_DETECT_PIN GPIO_Pin_13 /* PC.13 */
#define SD_DETECT_GPIO_PORT GPIOC /* GPIOC */
#define SD_DETECT_GPIO_CLK RCC_AHB1Periph_GPIOC
diff --git a/stm/lib/stm324x7i_eval_sdio_sd.c b/stm/lib/stm324x7i_eval_sdio_sd.c
index f0e2ffc3e2..2d6f4b8c94 100644
--- a/stm/lib/stm324x7i_eval_sdio_sd.c
+++ b/stm/lib/stm324x7i_eval_sdio_sd.c
@@ -518,7 +518,7 @@ uint8_t SD_Detect(void)
__IO uint8_t status = SD_PRESENT;
/*!< Check GPIO to detect SD */
-#if defined(PYBOARD)
+#if defined(PYBOARD3)
if (GPIO_ReadInputDataBit(SD_DETECT_GPIO_PORT, SD_DETECT_PIN) != Bit_SET)
#elif defined(PYBOARD4)
if (GPIO_ReadInputDataBit(SD_DETECT_GPIO_PORT, SD_DETECT_PIN) == Bit_SET)