2018-04-04 10:31 PM
Hello there,
Is there any set state of the GPIO's when the MCU (STM32L4 in my example) is unprogrammed? Or more likelly, when the MCU is in the system bootloader (I believe thats where the program counter is before I flash the MCU with anything). It seems to me that the GPIO are set as outputs HIGH or have pull-ups set.
I would appreciate all help.
#gpio2018-04-05 05:21 AM
This is only a prototype for now, nothing produced yet. I will try ST and erratas. Thank you.
2018-04-05 05:35 AM
I should have think of that... Thank you guys.
2018-04-05 06:49 AM
It used to be the case that microcontrollers could draw a lot of current at start up but before any start up program had run and had configured the ports. That is because the CMOS input would be floating between 0 and 1 so that both mosfets were turned on. Two solutions were either use a high current power supply or add pull up resistors to all pins that could be floating at power up.
Different microcontrollers makers handle this differently now for example starting up with pull-ups turned on then the initialisation can change that. I be interested top hear if you get better adivice?Also your second question is not relivant to this thread it is best to start a new question (thread).2018-04-05 07:14 AM
Yep it's there , PB8 is used for CanRx in the bootloader, hence the pullup effect