cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F030C8 GPIO Max Source Current is limited to <5mA

NFern.1
Associate III

Device Used : STM32F030C8, 48pin LQFP48

I am driving MOC3043 Opto-Isolated Triac Driver so I need atleast 5 mA current sourced from the GPIO output

GPIO used with the MOC3043 is PA15 max current observed is 4.86mA

Only a single GPIO is configured at a time with all other peripherals/pins in reset state.

GPIO is configured as Push-Pull Output with the pull-up/pull-down resistors disabled.

GPIO used to drive a 3mm LED takes around 4mA. Adding multiple LEDs in parallel keeps the total current drawn at ~4.86A

Total current supplied to the STM32F030C8 from the 3.3V DC supply is around 10mA

I tried other GPIO pins like PA12, PB12 but see the same results

I tried several STM32F030C8 ICs from the lot and I see the same results

I even reconfigured the circuit as Open-Drain but still see the current limited to <5mA

I disconnected the STM32F030C8 and directly connected the 3.3V DC supply to circuit driving the MOC3043 input (through a 200E resistor) and the MOC3043 was triggered drawing around 8.3mA

I tried with a STM32F103C8 against the same circuit and it works fine sourcing ~ 8 mA from each GPIO

The F030C8 datasheet states that the max current per GPIO is 25mA and chip max source current is 120mA

Why does my IC limit the single GPIO current to less than 5 mA?

Attached is a pic of the IC. From the pic can we determine if the IC is a fake (not original ST)?

1 ACCEPTED SOLUTION

Accepted Solutions

Try a higher GPIO_OSPEEDR seeing for this pin.

JW

View solution in original post

4 REPLIES 4

Try a higher GPIO_OSPEEDR seeing for this pin.

JW

TDK
Guru

What is the circuit you're using to determine the max current sourced?

If you feel a post has answered your question, please click "Accept as Solution".

I set the Speed to "High" for the GPIO/Outputs requiring >5mA. 

I did not try "Medium".

GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_HIGH;

The GPIOs now source sufficient current to drive the MOC3403

Problem solved. Thanks a lot for the quick response, this really helped.

If you don't mind please point to the F030 User Documentation/Manual that mentions this setting.

I couldn't find it while going through the Data Sheets / HAL Driver User Manual.

NFern.1
Associate III

Thanks for your response. The problem is solved - see my reply to waclawek.jan

I used a Multimeter in mA range to measure the GPIO and IC currents.

Most of the F030 pins are terminated on connectors - very similiar to a BluePill.

For GPIO : GPIO->mA_Meter->270E->MOC3043/Pin1 (LED Anode)

using a lower resistance like 200E, 180E.. does not increase the current reading >5mA

For IC : 3.3V DC Source->mA_Meter->Board 3.3V Pin. 

( I disabled the LDO Reg on the Board and powered the board using the 3.3V Debug Pin with external 3.3V DC Source. )