diff options
Diffstat (limited to 'tools/gencfg/processors/boards')
3 files changed, 21 insertions, 3 deletions
diff --git a/tools/gencfg/processors/boards/stm32f4xx/datamodel/stm32f4board.xml b/tools/gencfg/processors/boards/stm32f4xx/datamodel/stm32f4board.xml index fc54e70b1..0a5959eec 100644 --- a/tools/gencfg/processors/boards/stm32f4xx/datamodel/stm32f4board.xml +++ b/tools/gencfg/processors/boards/stm32f4xx/datamodel/stm32f4board.xml @@ -7,7 +7,9 @@ BoardID="ST_STM32F4_DISCOVERY"
HSEBypass="true"
HSEFrequency="0"
- LSEFrequency="0">
+ LSEFrequency="0"
+ BoardPHYID="MII_KS8721_ID"
+ BoardPHYType="RMII">
<ports>
<GPIOA>
<pin0
diff --git a/tools/gencfg/processors/boards/stm32f4xx/templates/board.c.ftl b/tools/gencfg/processors/boards/stm32f4xx/templates/board.c.ftl index c6b4bdf4b..1e2a8ee95 100644 --- a/tools/gencfg/processors/boards/stm32f4xx/templates/board.c.ftl +++ b/tools/gencfg/processors/boards/stm32f4xx/templates/board.c.ftl @@ -79,7 +79,7 @@ bool_t sdc_lld_is_card_inserted(SDCDriver *sdcp) { return TRUE;
}
-/*
+/**
* @brief SDC card write protection detection.
* @todo Fill the implementation.
*/
@@ -101,7 +101,7 @@ bool_t mmc_lld_is_card_inserted(MMCDriver *mmcp) { return TRUE;
}
-/*
+/**
* @brief MMC_SPI card write protection detection.
* @todo Fill the implementation.
*/
diff --git a/tools/gencfg/processors/boards/stm32f4xx/templates/board.h.ftl b/tools/gencfg/processors/boards/stm32f4xx/templates/board.h.ftl index d2ef1802f..4a6529fd0 100644 --- a/tools/gencfg/processors/boards/stm32f4xx/templates/board.h.ftl +++ b/tools/gencfg/processors/boards/stm32f4xx/templates/board.h.ftl @@ -33,6 +33,22 @@ * Setup for ${doc1.board.@name[0]} board.
*/
+/*
+ * Board identifier.
+ */
+#define BOARD_${doc1.board.@BoardID[0]}
+#define BOARD_NAME "${doc1.board.@name[0]}"
+
+[#if doc1.board.@BoardPHYID[0]??]
+/*
+ * Ethernet PHY type.
+ */
+#define BOARD_PHY_ID ${doc1.board.@BoardPHYID[0]}
+[#if doc1.board.@BoardPHYType[0]?string == "RMII"]
+#define BOARD_PHY_RMII
+[/#if]
+[/#if]
+
#if !defined(_FROM_ASM_)
#ifdef __cplusplus
extern "C" {
|