diff options
| author | Jeff Epler <jepler@gmail.com> | 2020-07-23 18:08:45 -0500 |
|---|---|---|
| committer | Jeff Epler <jepler@gmail.com> | 2020-07-30 07:18:02 -0500 |
| commit | 60dd5a8d7db5700ea886dc54988e2ed9502ac8c4 (patch) | |
| tree | 8f715a613c324294045aadd1db797b4ba2e0553f | |
| parent | ccd3013396e1e36f2cce5956c301e50ff1b4324d (diff) | |
stm: sdioio: remove unused code related to "SD Card detect pin"
.. this probably came from the examples that I studied at the beginning
of implementation.
The card detection feature is unused. As a "detect pin" is not
sent from the shared-bindings, there is no way to get the correct pin
anyway. Instead, if code needs to detect the insertion state it can
directly use the pin as GPIO in Python code.
| -rw-r--r-- | ports/stm/common-hal/sdioio/SDCard.c | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/ports/stm/common-hal/sdioio/SDCard.c b/ports/stm/common-hal/sdioio/SDCard.c index a1e87ec4e..32b1e01be 100644 --- a/ports/stm/common-hal/sdioio/SDCard.c +++ b/ports/stm/common-hal/sdioio/SDCard.c @@ -148,16 +148,6 @@ void common_hal_sdioio_sdcard_construct(sdioio_sdcard_obj_t *self, GPIO_InitStruct.Pin = pin_mask(clock->number); HAL_GPIO_Init(pin_port(clock->port), &GPIO_InitStruct); -// XXX hard coded pin -#define SD_DETECT_PIN GPIO_PIN_12 -#define SD_DETECT_GPIO_PORT GPIOB - - /*!< Configure SD_SPI_DETECT_PIN pin: SD Card detect pin */ - GPIO_InitStruct.Pin = SD_DETECT_PIN; - GPIO_InitStruct.Mode = GPIO_MODE_INPUT; - GPIO_InitStruct.Pull = GPIO_PULLUP; - HAL_GPIO_Init(SD_DETECT_GPIO_PORT, &GPIO_InitStruct); - __HAL_RCC_SDIO_CLK_ENABLE(); self->handle.Init.ClockDiv = SDIO_TRANSFER_CLK_DIV; |
