2024-03-11 01:08 AM
Hi,
I'm currently gaining experience with the STM32G4, whose ROM bootloader supports various interfaces. AN2606 describes the configuration of the pins occupied by the interfaces.
Various pins are operated in push-pull mode, which can lead to undesirable effects in an external circuit.
My question is whether it is possible to deactivate unneeded interfaces in the bootloader, e.g. via option bytes, or whether this can only be achieved with a separate bootloader.
Thanks in advance for your feedback!
Solved! Go to Solution.
2024-03-11 06:21 AM - edited 2024-03-11 06:21 AM
> My question is whether it is possible to deactivate unneeded interfaces in the bootloader, e.g. via option bytes, or whether this can only be achieved with a separate bootloader.
No, it is not possible to change the behavior of the bootloader in any way. You cannot disable interfaces selectively.
However, most pins are in input mode and it is only a problem if they are being toggled externally, which could be misinterpreted as activity on that bus.
2024-03-11 01:15 AM
Sure, there is a special option bit for it called nSWBOOT0
2024-03-11 01:40 AM
Hi @AlexSmart
thanks, but the question not about the pins or option bytes to enter the bootloader but about the interfaces supported by the bootloader for communication (USART, SPI, IC2). For all of them the bootloader configures GPIOs (AN2606) which can conflict with the external circuit. I'm interested if some of these interfaces can be disabled for the bootloader.
kr
2024-03-11 06:21 AM - edited 2024-03-11 06:21 AM
> My question is whether it is possible to deactivate unneeded interfaces in the bootloader, e.g. via option bytes, or whether this can only be achieved with a separate bootloader.
No, it is not possible to change the behavior of the bootloader in any way. You cannot disable interfaces selectively.
However, most pins are in input mode and it is only a problem if they are being toggled externally, which could be misinterpreted as activity on that bus.