Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Program needs to be in C language. Assignment You are to design, code, and implement a program that reads two input switches and blinks an

Program needs to be in C language.

image text in transcribed

Assignment You are to design, code, and implement a program that reads two input switches and blinks an LED (your choice) according to the following truth table: S10 OFF OFF ON ON S11 OFF ON OFF ON LED on time LED off time 500 mS 1000 mS 1000 mS 500 mS 1000 mS 500 mS 1000 mS 500 mS For the time base, you are to set up a timer that interrupts the processor every 10 mS. In order to verify that your interrupt is working correctly, designate a port pin as an output, and toggle it every time the timer ISR is run. Connect the pin to the oscilloscope so that you can verify it is exactly 10 mS on, and 10 mS off. To save CPU cycles, switch inputs should be set up to only be read on a change of value. This can be done by using the interrupt-on-change feature of RB4-RB7. You are free to select any valid port pins to drive the LED, and output the square wave produced by the timer ISR

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

Oracle RMAN For Absolute Beginners

Authors: Darl Kuhn

1st Edition

1484207637, 9781484207635

More Books

Students also viewed these Databases questions

Question

What is the maximum for SALE_PRICE?

Answered: 1 week ago