UM10850
All information provided in this document is subject to legal disclaimers.
© NXP B.V. 2016. All rights reserved.
User manual
Rev. 2.4 — 13 September 2016
230 of 464
16.1 How to read this chapter
The RTC is identical on all LPC5410x parts.
16.2 Features
•
The RTC and its independent oscillator operate directly from the device power pins,
not using the on-chip regulator. The RTC oscillator has the following clock outputs:
–
32 kHz clock, selectable for system clock and CLKOUT pin.
–
1 Hz clock for RTC timing.
–
1 kHz clock for high-resolution RTC timing.
•
32-bit, 1 Hz RTC counter and associated match register for alarm generation.
•
Separate 16-bit high-resolution/wake-up timer clocked at 1 kHz for 1 ms resolution
with a more that one minute maximum time-out period.
•
RTC alarm and high-resolution/wake-up timer time-out each generate independent
interrupt requests. Either time-out can wake up the part from any of the low power
modes, including Deep power-down.
16.3 Basic configuration
Configure the RTC as follows:
•
Use the AHBCLKCTRL0 register (
) to enable the clock to the RTC register
interface and peripheral clock.
•
For RTC software reset use the RTC CTRL register. See
. The RTC is reset
only by initial power-up of the device or when an RTC software reset is applied, it is
not initialized by other system resets.
•
The RTC provides an interrupt to NVIC slot #29 for the RTC_WAKE and
RTC_ALARM functions.
•
To enable the RTC interrupts for waking up from Deep-sleep and Power-down modes,
enable the interrupts in the STARTER0 register (
) and the NVIC.
•
To enable the RTC interrupts for waking up from Deep power-down, enable the
appropriate RTC clock and wake-up in the RTC CTRL register (
•
If enabled, the RTC and its oscillator continue running in all reduced power modes as
long as power is supplied to the device. So, the 32 kHz output is always available to
be enabled for syscon clock generation (see
). Once enabled, the 32 kHz
clock can be selected for the system clock or be observed through the CLKOUT pin.
The 1 Hz output is enabled in the RTC CTRL register (RTC_EN bit). Once the 1 Hz
output is enabled, the 1 kHz output for the high-resolution wake-up timer
can be
enabled
in the RTC CTRL register (RTC1KHZ_EN bit).
•
If the 32 kHz output of the RTC is used by another part of the system, enable it via the
EN bit in the RTCOSCCTRL register. See
UM10850
Chapter 16: LPC5410x Real-Time Clock (RTC)
Rev. 2.4 — 13 September 2016
User manual