# Basic RTT Project 1.4

## Purpose

This example demonstrates the Real-Time Timer (RTT) provided on AT91 microcontrollers. It enables the user to set an alarm and watch it being triggered when the timer reaches the corresponding value.

## Hardware Requirements

This package can be used with any of the AT91 Evaluation Kits except the AT91SAM7L-EK and AT91SAM7L-STK.

## Description

When launched, this program displays a timer count and a menu on the DBGU, enabling the user to choose between several options:

- Reset the timer
- Set an alarm time
- Clear an alarm notification if one is being displayed

The user can set an alarm time by selecting option 2 ('s'), entering the alarm time and pressing the enter key. Once the alarm is set, a message will be displayed when the corresponding time is reached.

## Usage

1. Build and download the program inside the evaluation board. Please refer to the SAM-BA User Guide, the GNU-Based Software Development application note or to the IAR EWARM User Guide, depending on your chosen solution.
2. On the computer, open the DBGU port with a terminal application (e.g. HyperTerminal on Microsoft Windows).

- Settings: 115200 bauds, 8 bits, 1 stop bit, no parity, no flow control.

3. Start the application.
4. The application menu should appear as shown below:

   > `-- Basic RTT Project 1.4 --
   > Time: 0
   > Menu:
   > r - Reset timer
   > s - Set alarm
   > Choice?
   > `

   The user can then choose any of the available options to perform the described action.

###### Atmel Corporation ©2008