cancel
Showing results for 
Search instead for 
Did you mean: 

STM32 GPIO state High After Earsing Microcontroller

keyur1
Associate II

Hello everyone,

I am using Stm32 controller for motor control and heating control. Universal motor is connected to TRIAC and TRIAC connected to MOC2023. LED of opto coupler is control by GPIO. Now problem is after erasing code from Flash memory , GPIO is high even though i have pull down resistor. At that moment , motor is still running  without code. What could be Approaches  that doesn't depended on Microcontroller ?

Thank you 

3 REPLIES 3
gbm
Lead III

You did not give any information that could allow anyone to help you. No MCU type, no pin identification

Check the pin's default function, Maybe it's a JTAG pin. Maybe it's an UCPD DB pin.

keyur1
Associate II

MCU is STM32G0B1RCT7 and pin is PB7

gbm
Lead III

With Flash erased, the MCU enters boot mode automatically and maybe it sets the pin function for boot operation. Check the bootloader appnote for detailed info. PB7 is used as I2C pin in boot mode.