Philips Semiconductors

User’s Manual - Preliminary -

 

 

 

 

 

 

WATCHDOG TIMER

P89LPC901/902/903

 

 

MOV

WFEED1,#0A5h

; do watchdog feed part 1

 

 

MOV

WFEED2,#05Ah

; do watchdog feed part 2

 

 

SETB

EA

; enable interrupt

 

In timer mode (WDTE = 0), WDCON is loaded to the control register every CCLK cycle (no feed sequence is required to load the control register), but a feed sequence is required to load from the WDL SFR to the 8-bit down counter before a time-out occurs.

WDCON

 

7

6

5

4

3

2

 

1

0

 

 

 

PRE2

PRE1

PRE0

-

-

WDRUN

WDTOF

WDCLK

 

Address: A7h

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Not bit addressable

 

 

 

 

 

 

 

 

 

 

 

Reset Source(s): See reset value below

 

 

 

 

 

 

 

 

 

Reset Value:

111xx1?1B

(Note: WDCON.7,6,5,2,0 - set to ’1’ any reset; WDCON.1 - cleared to ’0’ on Power-on

 

 

reset, set to ’1’ on watchdog reset, not affected by any other reset)

 

 

 

BIT

SYMBOL

FUNCTION

 

 

 

 

 

 

 

 

 

WDCON.7-5 PRE2-PRE0

Clock Prescaler Tap Select. Refer to Table for details.

 

 

 

WDCON.4-3

-

Reserved for future use. Should not be set to 1 by user program.

 

 

 

WDCON.2

WDRUN

Watchdog Run Control. The watchdog timer is started when WDRUN = 1 and stopped

 

 

when WDRUN = 0. This bit is forced to 1 (watchdog running) and cannot be cleared if both

 

 

WDTE and WDSE are set to 1.

 

 

 

 

 

 

 

WDCON.1

WDTOF

Watchdog Timer Time-Out Flag. This bit is set when the 8-bit down counter underflows.

 

 

In watchdog mode, a feed sequence will clear this bit. It can also be cleared by writing ’0’

 

 

to this bit in software.

 

 

 

 

 

 

 

 

WDCON.0

WDCLK

Watchdog input clock select. When set, the watchdog oscillator is selected. When cleared,

 

 

PCLK is selected. (If the CPU is powered down, the watchdog is disabled if WDCLK = 0,

see section "Power down operation"). (Note: If both WDTE and WDSE are set to 1, this bit is forced to 1.) Refer to section "Watchdog Clock Source" for details.

Figure 12-2: Watchdog Timer Control Register

The number of watchdog clocks before timing out is calculated by the following equations: tclks = (2(5+PRE) )(WDL+1)+1

where:

PRE is the value of prescaler (PRE2-PRE0) which can be the range 0-7, and;

WDL is the value of watchdog load register which can be the range of 0-255. The minimum number of tclks is:

tclks = (2(5+0))(0+1)+1 = 33 The maximum number of tclks is:

tclks = (2(5+7))(255+1)+1 = 1,048,577

The following table shows sample P89LPC901/902/903 timeout values.

2003 Dec 8

85

Page 85
Image 85
Philips P89LPC903, P89LPC901, P89LPC902 user manual Wdcon

P89LPC903, P89LPC902, P89LPC901 specifications

The Philips P89LPC901, P89LPC902, and P89LPC903 are a series of 8-bit microcontrollers designed for embedded system applications. These models, which belong to the LPC900 series, are notable for their affordability and versatility, making them an attractive choice for both hobbyists and professional developers.

One of the core features of the P89LPC901, P89LPC902, and P89LPC903 microcontrollers is their powerful 8-bit architecture. Operating at clock speeds up to 20 MHz, they deliver efficient performance suited for a range of tasks. Each model includes a comprehensive instruction set that supports various data manipulation and arithmetic functions, enabling extensive programming capabilities.

These microcontrollers come with built-in memory, with configurations that vary among the three models. The P89LPC901 typically features 4 KB of Flash memory and 256 bytes of RAM, while the P89LPC902 and P89LPC903 offer enhanced memory options. This Flash memory allows for reprogrammability, making it easier to update and modify applications as needed.

Another significant characteristic of the LPC900 series is their integrated peripherals. These models are equipped with a variety of I/O ports, allowing for easy interfacing with other devices and components. The P89LPC901 supports up to 32 I/O pins, while the P89LPC902 and P89LPC903 provide additional features such as analog-to-digital converters (ADCs), timers, and serial communication interfaces. This broad range of peripherals empowers developers to design complex applications without needing extra hardware.

Power consumption is also a key consideration for microcontroller applications. The P89LPC901, P89LPC902, and P89LPC903 are designed with low power consumption in mind, making them ideal for battery-operated devices and energy-efficient projects. They can operate in various power modes, allowing for greater flexibility in deployment.

In terms of technology, these microcontrollers utilize advanced CMOS technology, ensuring high reliability and durability. Their design offers a robust solution for numerous applications, including consumer electronics, industrial controls, and automation systems.

In summary, the Philips P89LPC901, P89LPC902, and P89LPC903 microcontrollers present an attractive combination of performance, integrated peripherals, low power consumption, and versatility. Their features cater to a wide array of applications, keeping them relevant in a rapidly evolving technology landscape. For hobbyists and professionals alike, these microcontrollers represent a reliable foundation for embedded system development.