Question: LAB # 6 : WRITING AND TESTING TIMERS AND INTERRUPTS OBJECTIVE Introduce students to writing timer - based routines and handling interrupts in AVR assembly

LAB #6: WRITING AND TESTING TIMERS
AND INTERRUPTS
OBJECTIVE
Introduce students to writing timer-based routines and handling interrupts in AVR assembly language
and using GPIO to visualize the results on the Curiosity Nano board.
MATERIALS
Microchip AVR64DU32 Curiosity Nano evaluation kit
ASSIGNMENT
Write two programs to toggle the LED0 on the Curiosity Nano board repeatedly. The first program
should use a time delay generated by a timer, while the second program should utilize an Interrupt
Service Routine (ISR). The LED should be turned on for a few seconds and then off for a few seconds,
alternating continuously.
PRE-LAB
1) Write simple instructions to turn on LED0.
2) Write macros to load 16-bit and 8-bit values and store them in the data memory. Use the macros in
the programs.
3) Compute the value of the counter register (TCA0_SINGLE_CNT) needed to generate a delay of 12
seconds (excluding the overhead due to instructions). What is the clock frequency of the internal
OSCHF?

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!