[En-Nut-Discussion] STM32F2 status
Henrik Maier
hmnews at proconx.com
Mon Jan 28 13:43:48 CET 2013
On 28/01/2013 9:42 PM, Uwe Bonnes wrote:
> line 877 up to 948 of stm32_emac.c contain a big block of pin mapping
> operations. Is this block missing for you or are there errors?
Hello Uwe,
Sorry. That is there indeed. I got confused as I have the BGA part which
is using port G for some signals, a configuration which is not yet
supported (but should be easy to add).
The challenge is now, how to configure the various combinations of
alternate PIN configurations. Quite a few of the Ethernet signals can be
mapped to different pins on an individual basis. Can you recommend a
best practise here to follow?
Something like:
#ifdef EMAC_MAP_ETH_TXD0_PG13
GPIO_PinAFConfig((GPIO_TypeDef*) NUTGPIO_PORTG, 13, GPIO_AF_ETH);
#else
GPIO_PinAFConfig((GPIO_TypeDef*) NUTGPIO_PORTB, 12, GPIO_AF_ETH);
#endif
This issue also applies to other drivers like the UART and CAN were each
individual signal can be mapped to at least two different pins.
Also wondering if the EMAC driver should use GPIO_CFG_SPEED_HIGH rather
GPIO_CFG_SPEED_FAST as it should be 100 MHZ pin speed I think. At least
this is what ST's driver is using.
Thank you for your assistance.
Cheers,
Henrik
More information about the En-Nut-Discussion
mailing list