Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

In this lab, you will exercise 2 things: programming interrupts and configuring/using the timers. It's assumed you are already well versed in I/O This assignment

image text in transcribed
In this lab, you will exercise 2 things: programming interrupts and configuring/using the timers. It's assumed you are already well versed in I/O This assignment will be worth 10 points 2 point Configuring timer(s) correctly l point- Configuring interrupts correctly 3 point-Implementing ISRs correctly 1 point- All other required configurations 3 points-Correct program behavior Create a new project in Keil, named "Lab5". In this project, you should: 1 - Disable the Watchdog timer! 2- Configure the LEDs (P1.0 and P2.0, P2.1, P2.2) as outputs. 3 Initialize LEDs states (all turned off). 4 -Configure 2 Timers A (16 bits) accordingly 5 - Implement switch and timer ISRs We want one Red LED to blink (on/off every second, and the second LED (RGB) to blink (change to next color) every 0.5 seconds. The two LEDs should be out of phase by precisely 0.1 seconds (see diagram below). Use TimerA0 in UP mode (and corresponding interrupts) to trigger the RED LED and TimerA1 in UP/DOWN mode (and corresponding interrupts) to trigger the RGB LED RED on RED off RED on RB switch GB switch RGB switch RGB switch 0 0.1 0.6 1 1.1 1.6 2

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Power Bi And Azure Integrating Cloud Analytics For Scalable Solutions

Authors: Kiet Huynh

1st Edition

B0CMHKB85L, 979-8868959943

More Books

Students also viewed these Databases questions