Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

a) what would be a strategy to handle this scenario, i.e. what would happen when a higher-priority interrupt (HPI) occurs while a lower-priority interrupt (LPI)

a) what would be a strategy to handle this scenario, i.e. what would happen when a higher-priority interrupt (HPI) occurs while a lower-priority interrupt (LPI) is being processed?

b) What could be some factors that you think affect the interrupt priorities?

2.Imagine you have the following tasks that must occur in your embedded system: a. Read a temperature sensor every 5 ms b. Write a character out a serial port every 12 ms c. Toggle an I/O pin every 100 ms.

Let us say the processor in this example has only a single timer to use, i.e. you have more tasks that need to occur at a specific interval than there are timers to use for each task. What strategies can you think of implementing, to accomplish all the jobs a-c listed above? Write a simple C code snippet that would be used in the timer ISR to handle the three intervals for the jobs listed. Hint: You may create your own variable names for each task's flags and timerCounts.

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_2

Step: 3

blur-text-image_3

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

Programming The Perl DBI Database Programming With Perl

Authors: Tim Bunce, Alligator Descartes

1st Edition

1565926994, 978-1565926998

More Books

Students also viewed these Databases questions

Question

Which technologies are still fantasies?

Answered: 1 week ago

Question

L A -r- P[N]

Answered: 1 week ago