STM8L101 STM8L151 low power consumption issue

Publisher:颐真阁Latest update time:2016-07-14 Source: eefocusKeywords:STM8L101 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere
There are two projects in hand. When the user is not operating, the system must enter low power mode. The two projects use STM8L101 and STM8L151 respectively. The system running clock of both projects is 8MHz (internal high-speed clock) and both are powered by lithium batteries.

For STM8L151, the chip manual says that when entering the active shutdown state, the power consumption of the microcontroller is 0.8uA. I found the automatic wake-up function in the program and woke up once every 30s; when the user has no operation for 30S, it enters the low power mode through Halt(). But I found that the power consumption is not low, about 125uA. Because the system is powered by a battery, such a high power consumption, a battery can't last for a few days. Later, I checked the technical manual and found that the unused pins need to be set. I set them all to push-pull output low, but there are two pins that must be paid attention to, the two pins connected to the external crystal oscillator, if the external crystal oscillator is not used, that is, they must be set to input mode.

Download the program and use the microampere range of the Volk meter to measure the current, which is 1.8uA, which is very close to the value given in the chip manual. Unplug the battery, and a 106 capacitor can also power the system for more than ten seconds. This project is now complete.

 

Now let's talk about another project. The chip used is STM8L101, a 20-pin package. There is no external crystal connection pin, so don't worry about the configuration of these two pins. I originally wanted to use the shutdown mode to enter low power consumption, but sometimes it cannot be woken up. So I switched to the active shutdown function, but when entering the active shutdown state, the power consumption is very high, sometimes reaching 120 to 30 uA, sometimes more than 70 uA, and sometimes more than 30 uA. But most of them stay at more than 70 uA. The pins that are not available have been set, and I don't know what went wrong.

After checking the schematics and debugging, I finally found the problem. The project uses the STM8 pin as the touch ring pin. When entering the active stop mode, the touch pin is in an uncertain state. This problem may cause the current to be too high during low power consumption. Two lines of code are added to the program. The first line initializes the touch ring pin to push-pull output low before entering low power consumption. The second line initializes the pin to the touch ring pin again after waking up.

I downloaded the program and used the microampere range of the Flock meter to measure the current, which was 0.8uA, which is very close to the value given in the chip manual.

This project also ends here.

But there is still a problem here, that is, when waking up and initializing to the touch pin, the touch ring or touch button cannot be over-touched, otherwise it will become insensitive.

Keywords:STM8L101 Reference address:STM8L101 STM8L151 low power consumption issue

Previous article:GPIO output---control the buzzer
Next article:ARM Download Error

Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号