# US 2008/0307241 A1 · Microcontroller circuit and power saving method thereof

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2008/0307241 A1
- Document ID: US20080307241A1
- Status: Published application
- Kind: A1
- Application number: 11/808,279
- Filed: 2007-06-08
- Published: 2008-12-11
- Earliest claimed: 2007-06-08
- Inventors: Eric Lin; Wen-Chi Hsu
- Web page: https://patentgrep.com/patent/US20080307241A1

## CPC

- G06F 1/06: Clock generators producing several clock signals {(G06F1/08 - G06F1/14 take precedence)}
- G06F 1/08: Clock generators with changeable or programmable clock frequency
- G06F 1/3203: Power management, i.e. event-based initiation of a power-saving mode
- G06F 1/3237: by disabling clock generation or distribution
- G06F 1/324: by lowering clock frequency
- Y02D 10/00: Energy efficient computing, e.g. low power processors, power management or thermal management
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- Y02D: CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE

## Abstract

A microcontroller circuit provides proper clocks to a central processing unit of a microcontroller and peripherals according to a power saving mode and operating conditions of the peripherals. The microcontroller circuit comprises a prescaler, a second multiplexer, a central processing unit, a first switch, a second switch, a first peripheral, and an execution unit. The execution unit is installed in the central processing unit and used for controlling the first switch and the second switch. The switches control the transmission of clocks according to the power saving mode operated by the microcontroller circuit, so that the central processing unit and each peripheral can work with a proper clock to reduce power use.

## Claims

### Claim 1

A microcontroller, comprising:
a prescaler, for receiving a first clock, and outputting a plurality of second clocks after dividing the frequency of said first clock;
a second multiplexer, for receiving a third clock, said first clock, and said second clocks, and outputting a fourth clock;
a central processing unit, for receiving said fourth clock;
a first switch, installed between said central processing unit and said second multiplexer;
a second switch; and
a first peripheral, for receiving said third clock through said second switch;
thereby said central processing unit controls said first switch and said second switch based on a power saving mode operated by said microcontroller.

### Claim 2 (depends on 1)

The microcontroller of claim 1, further comprising a first multiplexer for receiving an external clock to output said first clock.

### Claim 3 (depends on 2)

The microcontroller of claim 2, wherein said external clock includes a clock provided by an RC oscillator and a clock provided by a crystal oscillator.

### Claim 4 (depends on 1)

The microcontroller of claim 1, wherein said second clock is a clock equal to said first clock divided by 2, 4, 8, 16, 32 or 64.

### Claim 5 (depends on 1)

The microcontroller of claim 1, further comprising a register, such that a plurality of select control bits of said register is used for determining whether or not to output said fourth clock by said second multiplexer.

### Claim 6 (depends on 5)

The microcontroller of claim 5, wherein said select control bit is set by said execution unit based on said power saving mode for determining whether or not to output said fourth clock.

### Claim 7 (depends on 1)

The microcontroller of claim 1, wherein said third clock is a clock provided by a real time clock (RTC).

### Claim 8 (depends on 1)

The microcontroller of claim 1, further comprising a first frequency divider installed between said first peripheral and said second switch.

### Claim 9 (depends on 1)

The microcontroller of claim 1, wherein said central processing unit further comprising an execution unit for controlling said first switch and said second switch based on said power saving mode.

### Claim 10 (depends on 9)

The microcontroller of claim 9, wherein said first peripheral has a switch control bit set for said execution unit to control said second switch based on said power saving mode and said switch control unit.

### Claim 11 (depends on 1)

The microcontroller of claim 1, wherein said power saving modes include a normal mode, a slow mode, an idle mode, and a sleep mode.

### Claim 12 (depends on 11)

The microcontroller of claim 11, further comprising a low power register for switching said power saving modes by setting said low power register.

### Claim 13 (depends on 1)

The microcontroller of claim 1, further comprising a second peripheral for receiving said fourth clock through an output of said second multiplexer connected to a third switch.

### Claim 14 (depends on 13)

The microcontroller of claim 13, wherein said second peripheral includes a digital-to-analog converter or a pulse width modulator.

### Claim 15 (depends on 13)

The microcontroller of claim 13, wherein said second peripheral has a switch control bit provided for said execution unit to control said third switch based on said power saving mode and said switch control unit.

### Claim 16 (depends on 1)

The microcontroller of claim 1, further comprising a third peripheral for receiving said third clock through a fourth switch.

### Claim 17 (depends on 16)

The microcontroller of claim 16, further comprising a second frequency divider installed between said third peripheral and said fourth switch.

### Claim 18 (depends on 16)

The microcontroller of claim 16, wherein said third peripheral includes a watchdog timer, a real time clock interrupter or a buzzer.

### Claim 19

A power saving method for a microcontroller, comprising the steps of:
providing a first clock and a third clock;
dividing the frequency of said first clock, and then outputting a plurality of second clocks;
selecting a power saving mode;
controlling a first switch to enable or disable said first clock, one of said second clocks or said third clock to be inputted to a central processing unit of said microcontroller; and
controlling a second switch to enable or disable said third clock to be inputted to a first peripheral.

### Claim 20 (depends on 19)

The power saving method for a microcontroller of claim 19, wherein said first switch is controlled by an execution unit based on said power saving mode.

### Claim 21 (depends on 19)

The power saving method for a microcontroller of claim 19, wherein said second switch is controlled by an execution unit based on said power saving mode and a switch control bit of said first peripheral.

### Claim 22 (depends on 19)

The power saving method for a microcontroller of claim 19, wherein said first clock is a clock provided by an RC oscillator or a crystal oscillator.

### Claim 23 (depends on 19)

The power saving method for a microcontroller of claim 19, wherein said third clock is provided by a real time clock (RTC).

### Claim 24 (depends on 19)

The power saving method for a microcontroller of claim 19, wherein said first clock, one of said second clocks or said third clock is determined by a second multiplexer to be outputted to said central processing unit based on a select control bit of said register.

### Claim 25 (depends on 19)

The power saving method for a microcontroller of claim 19, wherein said third clock has its frequency divided by a first frequency divider and then said third clock is transmitted to said first peripheral.

### Claim 26 (depends on 19)

The power saving method for a microcontroller of claim 19, wherein said power saving modes include a normal mode, a slow mode, an idle mode, and a sleep mode.

### Claim 27 (depends on 26)

The power saving method for a microcontroller of claim 26, wherein said power saving modes are switched by setting a low power register.

### Claim 28 (depends on 27)

The power saving method for a microcontroller of claim 27, wherein said normal mode and said slow mode are switched by setting a first firmware control bit of said low power register.

### Claim 29 (depends on 27)

The power saving method for a microcontroller of claim 27, wherein said normal mode and said sleep mode, said normal mode and said idle mode, said slow mode and sleep mode, and said slow mode and said idle mode are switched by setting a second firmware control bit of said low power register and a halt command.

### Claim 30 (depends on 26)

The power saving method for a microcontroller of claim 26, wherein said sleep mode and said idle mode start a wakeup mechanism by a wakeup signal to return to said normal mode or said slow mode.

### Claim 31 (depends on 19)

The power saving method for a microcontroller of claim 19, further comprising a step of transmitting said first clock, one of said second clocks or one of said third clock to a second peripheral through a third switch.

### Claim 32 (depends on 31)

The power saving method for a microcontroller of claim 31, wherein said third switch is controlled by an execution unit based on said power saving mode and a switch control bit of said second peripheral.

### Claim 33 (depends on 19)

The power saving method for a microcontroller of claim 19, further comprising a step of transmitting said third clock to a third peripheral through a fourth switch.

### Claim 34 (depends on 33)

The power saving method for a microcontroller of claim 33, wherein said third clock has its frequency divided by a second frequency divider, and said third clock is transmitted to said third peripheral.

### Claim 35 (depends on 33)

The power saving method for a microcontroller of claim 33, wherein said fourth switch is controlled by an execution unit based on said power saving mode.

### Claim 36

A power saving method for a microcontroller, comprising the steps of:
providing a first clock and a third clock;
providing a prescaler to divide the frequency of said first clock, and
outputting a plurality of second clocks;
switching said microcontroller to a power saving mode;
providing a second multiplexer, for receiving said first clock, said second clock and said third clock, and outputting a fourth clock based on a select control bit of a register, and said select control bit of said register being set according to said power saving mode;
controlling a first switch to enable or disable said fourth clock to be inputted to a central processing unit of said microcontroller; and
controlling a second switch to enable or disable said third clock to be inputted a first peripheral.

### Claim 37 (depends on 36)

The power saving method for a microcontroller of claim 36, wherein said first switch is controlled by an execution unit based on said power saving mode.

### Claim 38 (depends on 36)

The power saving method for a microcontroller of claim 36, wherein said second switch is controlled by an execution unit based on said power saving mode and a switch control bit of said first peripheral.

### Claim 39 (depends on 36)

The power saving method for a microcontroller of claim 36, wherein said select control bit of said register is set by an execution unit based on said power saving mode.

### Claim 40 (depends on 36)

The power saving method for a microcontroller of claim 36, wherein said first clock is a clock provided by an RC oscillator or a crystal oscillator.

### Claim 41 (depends on 36)

The power saving method for a microcontroller of claim 36, wherein said third clock is provided by a real time clock (RTC).

### Claim 42 (depends on 36)

The power saving method for a microcontroller of claim 36, wherein said third clock has its frequency divided by a first frequency divider, and then said third clock is transmitted to said first peripheral.

### Claim 43 (depends on 36)

The power saving method for a microcontroller of claim 36, wherein said power saving mode includes a normal mode, a slow mode, an idle mode, and a sleep mode.

### Claim 44 (depends on 43)

The power saving method for a microcontroller of claim 43, wherein said power saving mode is switched by a low power register.

### Claim 45 (depends on 44)

The power saving method for a microcontroller of claim 44, wherein said normal mode and said slow mode are switched by setting a first firmware control bit of said low power register.

### Claim 46 (depends on 44)

The power saving method for a microcontroller of claim 44, wherein said normal mode and said sleep mode, said normal mode and said idle mode, said slow mode and sleep mode, and said slow mode and said idle mode are switched by setting a second firmware control bit of said low power register and a halt command.

### Claim 47 (depends on 43)

The power saving method for a microcontroller of claim 43, wherein said sleep mode and said idle mode start a wakeup mechanism via a wakeup signal to return to said normal mode or said slow mode.

### Claim 48 (depends on 36)

The power saving method for a microcontroller of claim 36, further comprising a step of transmitting said fourth clock to a second peripheral through a third switch.

### Claim 49 (depends on 48)

The power saving method for a microcontroller of claim 48, wherein said third switch is controlled by said execution unit based on said power saving mode and a switch control bit of said second peripheral.

### Claim 50 (depends on 36)

The power saving method for a microcontroller of claim 36, further comprising a step of transmitting said third clock to a third peripheral through a fourth switch.

### Claim 51 (depends on 50)

The power saving method for a microcontroller of claim 50, wherein said third clock has its frequency divided by a second frequency divider and transmitted to said third peripheral.

### Claim 52 (depends on 50)

The power saving method for a microcontroller of claim 50, wherein said fourth switch is controlled by an execution unit based on said power saving mode.
