01./* ETHERNET pins configuration */
02. /* AF Output Push Pull:
03. - ETH_MII_MDIO / ETH_RMII_MDIO: PA2
04. - ETH_MII_MDC / ETH_RMII_MDC: PC1
05. - ETH_MII_TXD2: PC2
06. - ETH_MII_TX_EN / ETH_RMII_TX_EN: PB11
07. - ETH_MII_TXD0 / ETH_RMII_TXD0: PB12
08. - ETH_MII_TXD1 / ETH_RMII_TXD1: PB13
09. - ETH_MII_PPS_OUT / ETH_RMII_PPS_OUT: PB5
10. - ETH_MII_TXD3: PB8 */
11.
12. /* Configure PA2 as alternate function push-pull */
13. GPIO_InitStructure.GPIO_Pin = GPIO_Pin_2;
14. GPIO_InitStructure.GPIO_Speed = GPIO_Speed_50MHz;
15. GPIO_InitStructure.GPIO_Mode = GPIO_Mode_AF_PP;
16. GPIO_Init(GPIOA, &GPIO_InitStructure);
17.
18. /* Configure PC1, PC2 and PC3 as alternate function push-pull */
19. GPIO_InitStructure.GPIO_Pin = GPIO_Pin_1 | GPIO_Pin_2;
20. GPIO_InitStructure.GPIO_Speed = GPIO_Speed_50MHz;
21. GPIO_InitStructure.GPIO_Mode = GPIO_Mode_AF_PP;
22. GPIO_Init(GPIOC, &GPIO_InitStructure);
23.
24. /* Configure PB5, PB8, PB11, PB12 and PB13 as alternate function push-pull */
25. GPIO_InitStructure.GPIO_Pin = GPIO_Pin_5 | GPIO_Pin_8 | GPIO_Pin_11 |
26. GPIO_Pin_12 | GPIO_Pin_13;
27. GPIO_InitStructure.GPIO_Speed = GPIO_Speed_50MHz;
28. GPIO_InitStructure.GPIO_Mode = GPIO_Mode_AF_PP;
29. GPIO_Init(GPIOB, &GPIO_InitStructure);
30.
31. /**************************************************************/
32. /* For Remapped Ethernet pins */
33. /*************************************************************/
34. /* Input (Reset Value):
35. - ETH_MII_CRS CRS: PA0
36. - ETH_MII_RX_CLK / ETH_RMII_REF_CLK: PA1
37. - ETH_MII_COL: PA3
38. - ETH_MII_RX_DV / ETH_RMII_CRS_DV: PD8
39. - ETH_MII_TX_CLK: PC3
40. - ETH_MII_RXD0 / ETH_RMII_RXD0: PD9
41. - ETH_MII_RXD1 / ETH_RMII_RXD1: PD10
42. - ETH_MII_RXD2: PD11
43. - ETH_MII_RXD3: PD12
44. - ETH_MII_RX_ER: PB10 */
45.
46. /* ETHERNET pins remapp in STM3210C-EVAL board: RX_DV and RxD[3:0] */
47. GPIO_PinRemapConfig(GPIO_Remap_ETH, ENABLE);