diff options
Diffstat (limited to 'boards/OLIMEX_LPC_P2148')
-rw-r--r-- | boards/OLIMEX_LPC_P2148/board.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/boards/OLIMEX_LPC_P2148/board.c b/boards/OLIMEX_LPC_P2148/board.c index d55fc61d4..b7e72f7c3 100644 --- a/boards/OLIMEX_LPC_P2148/board.c +++ b/boards/OLIMEX_LPC_P2148/board.c @@ -65,6 +65,21 @@ void __early_init(void) { lpc214x_clock_init();
}
+#if HAL_USE_MMC_SPI
+/* Board-related functions related to the MMC_SPI driver.*/
+bool_t mmc_lld_is_card_inserted(MMCDriver *mmcp) {
+
+ (void)mmcp;
+ return !palReadPad(IOPORT2, PB_CP1);
+}
+
+bool_t mmc_lld_is_write_protected(MMCDriver *mmcp) {
+
+ (void)mmcp;
+ return palReadPad(IOPORT2, PB_WP1);
+}
+#endif
+
/*
* Board-specific initialization code.
*/
|