2022-05-17 04:47 AM
I'm running into an issue while designing a relatively simple custom board with an L031K6T7, where after programming it the current draw exceeds 200mA and eventually breaks to the current limit of the power supply at 800mA.
When I assemble the board the current draw is negligible, I have used STM32CubeMX to generate the project and use an ST-Link/V2 with a TagConnect-2030-IDC cable to program the MCU over SWD. Something is going wrong in the programming of the device and causes the current draw to be far greater than it should be. Everything I've programmed it with has been generated from CubeMX and programmed over CubeProgrammer, the power supply to the L0 is 3.34V but I've verified that it never goes above 3.4V during power-on, which is within the 3.6V limit of the L0.
Any advice or recommendations on where to look would be really appreciated, I've read a fair bit of documentation but I'm still new to this and still learning.
The following is a detailed description of everything I've done around this issue, if it helps:
The first board I tried to program with relatively simple code that just set the enable pins high on a couple Boost converters and initialised/calibrated the ADC, and the current consumption read from the PSU instantly shot to the 800mA limit I had set for the board, the L0 itself becoming so hot that it burned to the touch within seconds. Booting into flash was dead, however, tying the BOOT0 pin high allowed it to still communicate with CubeProgrammer and I could program blink into the system memory and it functioned seemingly fine despite the extreme current draw. Measuring the resistance across VDD and GND on the chip (after removing it from the board) showed a resistance of 50 Ohms, however I don't know how relevant this is.
The second board I assembled I was more careful with. I first programmed it with just blink on the LED with the ADC, all communication and DMA left unconfigured in CubeMX. This sucessfully programmed the device and the consumption was 0-10mA. With all the enable pins set high the consumption was 50mA but once I enabled and calibrated the ADC the current consumption jumped up to 260mA. Even while holding nReset low the power consumption was over 150mA. Despite this the L0 was still programmable so I worked on the firmware of the board and continued verifying it with this high current draw. After a couple weeks working on it like this the current draw remained the same until, seemingly randomly when programming it with a new revision of the firmware the current draw spiked to 800mA and became extremely hot. Again the resistance across VDD and GND had dropped from the hundreds of kOhms to only 5Ohms but this time it was still programmable into Flash with BOOT0 low. Reverting the firmware to Blink had no effect in reducing the current draw.
Rather than assembling a completely new board I simply replaced the L0 on this second board with a new one. Before programming it the current consumption was <10mA but as soon as I connected to the MCU in STM32CubeProgrammer, the current draw from the power supply jumped to 550mA, before even programming it with a simple blink.
I've attached screenshots of my CubeMX setup incase I've made an obvious mistake that's causing these issues.
The TagConnect 2030 header connects the STlink to the board's VDD and GND, which shouldn't be a problem and the remaining pins are connected to the L0's nReset, SWCLK, SWDIO and RCC_CK_IN, I've attached a picture of the footprint.
Solved! Go to Solution.
2022-06-01 05:50 AM
Hi @Piranha , unfortunately despite removing the R48 pull-up resistor the issue has persisted. To begin with I just programmed blink onto the board and it was fine but after programming the L0 several times, activating different parts of the chip/board, when I programmed it and initialised the ADC the current consumption jumped from ~60mA when driving a load to 800mA. I don't know if this was caused by the ADC activating or just from the programming of it but either way there is still something wrong with it.