跳至主要內容
Knowledgebase
Home
Renesas Electronics Taiwan - Knowledgebase

Standby Operation

Latest Updated:05/01/2006

Question:

Standby Operation

Answer:

(1)Introduction
When designing products, power saving is not a concept reserved just for a few mobile devices: it is a major issue for almost all products.
With semiconductors too, in the case of digital circuits, PMOS circuits (which are relatively easy to make) and NMOS and bipolar circuits (which are suited to high speeds) are being replaced by CMOS circuits, which enable operation on a smaller current. The operating current of LSIs is also decreasing due to circuit miniaturization brought about by process innovations. Moreover, many devices that were previously made up of several ICs or transistors are now being realized with a single LSI. The power consumption of systems as a whole has therefore decreased dramatically (although systems have become that much more complex).
However, in spite of global trends to save energy, it is becoming more difficult to reduce the operating current in an LSI simply through miniaturization. It is time to consider new measures from the point of view of use. This leads us to the standby function.

mockup.gif [Coffee Break]
Let's look back to when the 8-bit single-chip microcontroller first appeared on the world's stage. In those days, when developing a new microcontroller, an evaluation system, known as a mockup, was created in combination with a standard IC to check the operation of the circuits. The 5 V power supply of this system, when first developed, required an operating current of about 35 A. This was eventually lowered to about 20 A through circuit design innovations and reexaminations of the ICs used. The operating current of the target microcontroller at that time was about 200 mA, so this represented energy saving of about 1/100?
It is impossible to make a direct comparison, but current 8-bit microcontrollers have much superior performance and functions, but with an operating current in most cases in the single figure range.
[Trivia]
I remember touching the casing (ceramic in those days) of the 8080A, a famous early microcontroller, and almost burning my fingers. I guess this was only natural because in those days, even though the external interface was 5 V, the ICs were forcibly operated on an internal voltage of 12 V in order to increase the speed.
Even since then, there have been several microcontrollers, such as the 8224, that included CPU peripheral devices that made the microcontroller too hot to touch.


(2)Power consumption mechanism
As most recent microcontrollers use CMOS circuits, this explanation will focus on those. The basis of the internal circuitry, the inverter, includes two transistors, a P-ch transistor and an N-ch transistor, configured one above the other, as shown in diagram (a) below. In diagram (b), the P-ch transistor on the top is ON and the N-ch transistor on the bottom is OFF, so the output is "H". In diagram (c), the P-ch transistor on the top is OFF and the N-ch transistor on the bottom is ON, so the output is "L". In these states, the transistor that is OFF enters a high-resistance state, so current barely flows. In other words, if the same state continues, the power consumption can be ignored.
Looking at it another way, current flows when the signal changes. As shown in diagram (d), if load capacitance is added (and, actually, a wiring capacitor is always added), extra current will flow in order to charge this capacitor.

inv_state.gif

Replacing the concept of current with that of water, the inverter could be considered to operate as a valve. Water is poured in from the top and the flow is controlled by the valve. The states of the valve can be likened to the states of the inverter. In the inverter's "H" state, the valve on the top is open and the valve on the bottom is closed; in the inverter's "L" state, the valve on the top is closed and the valve on the bottom is open. When the state changes from "H" to "L", the amount of water shown in the diagram on the far right flows. This amount can be compared to power consumption.
When load capacitance is added as is shown in diagram (d) above, the amount of water that builds up to the right of the valve increases, further increasing the amount of water that flows.

valve.gif

(3)Standby function
In most applications, it is not necessary for the microcontroller to always be operating; there are times when it is free (for example, when the microcontroller is waiting for an input or for time to pass based on a timer setting). Operating the microcontroller normally during this time is a waste of power. This is why recent microcontrollers have a standby function that stops the microcontroller operating when it is not required. This function, known by various other names including "sleep", can be divided into modes that determine which functions are to stop operating.
In most cases there are three modes, with the following functions. Most microcontrollers generally have (a) and (c) modes.
(a) HALT mode (only CPU instruction execution is stopped)
(b) IDLE mode (clock supply is also stopped)
(c) STOP mode (clock oscillation is stopped, which stops most functions)

Whereas previously only the performance during operation was a concern, now the power consumption during standby has become an issue in many devices. The increase in mobile applications in particular has caused manufacturers to focus heavily on the performance of devices when they are not operating. This issue continues to increase in importance.

[Coffee Break 2]
If the power consumption is causing concern, instead of simply stopping clock supply to unused blocks, many microcontrollers recently offer solutions such as cutting the power supply itself during times of non-use. Microcontrollers are also appearing with a variety of on-chip functions, such as A/D converters, to which the required power is supplied only when they are used.
[Trivia]
Because of the large range of power-saving functions featured in recent microcontrollers, more space is required to print the power supply current specifications in the DC characteristics specification table. In older microcontrollers, the power supply current parameter would only take up a couple of lines; whereas now, a full page is not uncommon. This has made it harder to judge which specifications apply at which time.


(4) HALT mode
This function has been around since the earliest microcontrollers, and is really just an instruction used to stop instruction execution. In older microcontrollers, it was simply used to get the microcontroller to wait for interrupt input, and was unrelated to reducing the operating current. However, since the introduction of CMOS circuits, because stopping CPU instruction execution reduces the operating current, HALT has become one of the standby modes used to save power.
In this mode, only the CPU stops; all other circuits continue operating. Consequently, the current drops to a fraction of the usual operating current. Nevertheless, the on-chip peripheral functions are operable, and CPU operation can resume as soon as standby is released (immediate wakeup), which advantageous when a high-speed response is required.

[Coffee Break 3]
The standby functions in a microcontroller differ depending on the application of that microcontroller. For example, there are some microcontrollers for meter applications that feature a subclock-operation HALT mode in which the power supply current can be reduced to the micro-ampere range.


(5) IDLE mode
Unlike HALT mode, where only the CPU is stopped, in IDLE mode the clock supply to other blocks is also stopped. This means that the operating current in IDLE mode can be reduced to less than 1/10 of that in HALT mode.
Oscillation of the clock itself continues, so the operating current is still larger than in STOP mode. However, because the clock is still oscillating, if a standby release signal is input externally, operation can resume immediately.

(6) STOP mode
In STOP mode, because oscillation of the system's operating clock is stopped, the operating current is reduced to the several ten micro-ampere range.
The disadvantage of STOP mode is that clock oscillation has to be resumed when standby is released, and normal operation is not possible until clock oscillation is stable (in the same way as the human body does not operate well when getting up in the morning, due to low blood pressure). Consequently, STOP mode cannot be used in cases where there are limits on the time between standby release and operation completion.

(7) Summary
The features of each standby mode are summarized in the table below. Note that this table applies to general cases only.

  Stopped Part On-Chip Peripherals Operating Current Wakeup
HALT mode CPU only Operable Medium Fast
IDLE mode Clock supply Some operable Low Fast
STOP mode Clock oscillation Most operations stopped Very low Slow

 

[Coffee Break 4]
The STOP mode power supply current specification described in the electrical specifications indicates the state where all clocks, including the subclock for the watch timer, are completely stopped. However, in many systems, the STOP instruction is executed with the watch timer still operating. Although this state is sometimes called STOP mode, it is differentiated from actual STOP mode in the specifications. In this case, the power supply current specification that applies is the one for subclock-operation HALT mode. Because the subclock is operating, the power supply current is about double that in actual STOP mode.


(8) Other techniques for saving power
As mentioned in the description of the power consumption mechanism, the CMOS operating current flows according to a change in state. Therefore, two areas that can be looked at in terms of power saving are lowering the operating clock and the subclock operation. The operating speed of a microcontroller depends on the power supply voltage, so if the frequency of the operating clock is low, the operating current can be lowered further by using a low power supply voltage.
The graph below shows the relationship between the power supply voltage and operating current in each operating mode of the microcontroller. The top line is when the microcontroller is operating at high speed and the next line is when the microcontroller is operating at low speed (1/4 the speed of high-speed mode). The lowest two lines are when the microcontroller is operating on the subclock (oscillation of the system clock is stopped at this time). The remaining two lines indicate operation in HALT mode. You can see how the operating current changes according to the operating clock frequency and the power supply voltage.

vdd_idd.gif

(9) Remarks
(a) How to calculate power consumption
To conclude this section on power consumption, we will look at how to estimate the power consumption (operating current) when using the standby function.
Basically, the power consumption is calculated using the average time of the current value in each mode in which the microcontroller is operating. In most cases, there is no need to calculate the power consumption so strictly, because the operating current tends to differ depending on the microcontroller (device). In the following example, if the operating current during high-speed operation is I1 and the length of time in high-speed mode is t1, the operating current during standby operation is I2 and the length of time in standby mode is t2, and the operating current during low-speed operation is I3 and the length of time in low-speed mode is t3, the average current consumed is:
Average current = (I1 * t1 + I2 * t2 + I3 * t3) / (t1 + t2 + t3)

idd_average.gif

(b) Cautions/notes

  • Current at standby release
    When using the standby function, especially STOP mode, it is important to be aware of the time it takes to stabilize oscillation when clock oscillation resumes after standby is released. This period is short, but because a large current flows in order to start clock oscillation, it must be considered that a current of about the same level as normal operation is flowing.
    (Low blood pressure makes people struggle to get going in the morning. Similarly, microcontrollers also struggle to get started once stopped.)
  • Standby release triggers
    Interrupts are used to return the system to the normal operating state from standby (standby release). There are various types of interrupts, including internal interrupts such as timer-based interrupts, interrupts triggered by external interrupt request signals, and interrupts triggered by the end of serial communication with an external device. The interrupt to be used to release standby differs depending on which standby function is being used. Internal interrupts cannot be used to release STOP mode, so an external interrupt request signal must be used. However, care is required because there are some external interrupt request signals that cannot be used unless the clock is operating.
  • Watchdog timer
    The watchdog timer is the most difficult function to successfully combine with standby mode. There are two main situations in which problems occur. One is when the watchdog timer is operating even when the CPU has entered standby mode. In this case, standby mode must be released leaving enough time for the watchdog timer to be cleared.
    The other situation is when the count clock of the watchdog timer is stopped in standby mode. In this case, there is not such a big problem with the standby release timing, but the system relies on the functions of the watchdog timer to prevent deadlocks.
    It is therefore necessary to precheck carefully what will happen to the watchdog timer in standby mode.
  • Problems when the system operates on a combination of operating clocks
    We have described the three main standby modes, but it must also be noted that many new microcontrollers have clocks that operate on on-chip oscillators (depending on the device, there may be multiple oscillators, the oscillation of which may or may not be able to be stopped). In these microcontrollers, the standby mode to be used and the method of entering that mode differ depending on the clock on which the microcontroller is operating. For example, oscillation of the main clock can be stopped by executing the STOP instruction while the system is operating on the main clock, but if the system is operating on another clock, the STOP instruction cannot be used. In this case, standby must be controlled by a register setting.
    Also, when the clock is switched, standby must be controlled in conjunction with clock oscillation. If oscillation of the main clock is specified to resume while the system is operating on the subclock, if the operating clock is switched immediately from the subclock to the main clock, a hangup may occur because the system will try to operate on a clock that is not oscillating normally. (If clock oscillation is stopped due to execution of the STOP instruction, the oscillation stabilization time required when standby is released by interrupt can be secured by hardware, but if oscillation has been set to resume via the program, be sure to secure the required oscillation stabilization time using software.)

Keeping these points in mind, we wish you luck in achieving your power-saving targets.

Suitable Products