SlideShare a Scribd company logo
1 of 1
Download to read offline
Utilize the following code seqments for Problems A 5. Void Task_Flash(void) { If (
left(mathrm{g}_{text {flash_LED }}==1right) ) // Switch #1 Pressed Contro_RGB_LEDs (1,1,1);
Delay(g_w_delay): Contro_RGB_LEDs (0,0,0); Delay(B_w_delay); Ji fir Void Task_RGB(void) { If
(B_flash_LED ==0 ) { // Switch #1 Released Contro_RGB_LEDs (1,0,0); Delay(B_RGB_delay);
Contro_RGB_LEDS (0,1,0); Delay(g_RGB_delay): Contro_RGB_LEDs (0,0,1);
Delay(B_RGB_delay); } } Void Flasherf(void) i While (1) f Task_Flash(); Task RGB(); bi };5.
Consider the approach from the section titled Task Preemption and reference the diagram below.
Assume that the IRQ handler can tell the scheduler to change which task to run, and that tasks
can preempt each other. Assume that PORTD_IRQHandler starts executing as soon as the switch
changes from pressed to released, or from released to pressed. Assume there is no time taken to
switch between tasks or the handler, and that the tasks and handier have the following execution
times: a. Describe the sequence of events which leads to the maximum delay between pressing
the switch and seeing the LED flash sequence. Calculate the value of that delay, and indicate all
assumptions that you are making in regards to your solution. (5 Points)b. Describe the sequence
of events which leads to the maximum delay between pressing the switch and seeing the LED
RGB color sequence. Calculate the value of that delay. ( 5 Points)

More Related Content

More from picscamshoppe

Uzun vadeli yatrm kararlar ile ilgilenen finans alan olarak .pdf
Uzun vadeli yatrm kararlar ile ilgilenen finans alan olarak .pdfUzun vadeli yatrm kararlar ile ilgilenen finans alan olarak .pdf
Uzun vadeli yatrm kararlar ile ilgilenen finans alan olarak .pdfpicscamshoppe
 
Vaka 101 Zappos Yneticileri Ortadan Kaldryor evrimii ay.pdf
Vaka 101 Zappos Yneticileri Ortadan Kaldryor  evrimii ay.pdfVaka 101 Zappos Yneticileri Ortadan Kaldryor  evrimii ay.pdf
Vaka 101 Zappos Yneticileri Ortadan Kaldryor evrimii ay.pdfpicscamshoppe
 
Utilizacin de la inteligencia emocional en el lugar de trab.pdf
Utilizacin de la inteligencia emocional en el lugar de trab.pdfUtilizacin de la inteligencia emocional en el lugar de trab.pdf
Utilizacin de la inteligencia emocional en el lugar de trab.pdfpicscamshoppe
 
Utilizando el concepto de conocimiento metacognitivo los pr.pdf
Utilizando el concepto de conocimiento metacognitivo los pr.pdfUtilizando el concepto de conocimiento metacognitivo los pr.pdf
Utilizando el concepto de conocimiento metacognitivo los pr.pdfpicscamshoppe
 
Usted es miembro del grupo de relaciones con los empleados d.pdf
Usted es miembro del grupo de relaciones con los empleados d.pdfUsted es miembro del grupo de relaciones con los empleados d.pdf
Usted es miembro del grupo de relaciones con los empleados d.pdfpicscamshoppe
 
Usted es consultor comercial de People for the Ethical Treat.pdf
Usted es consultor comercial de People for the Ethical Treat.pdfUsted es consultor comercial de People for the Ethical Treat.pdf
Usted es consultor comercial de People for the Ethical Treat.pdfpicscamshoppe
 
usptrerl the following recerd was krpe ale 50PA a the .pdf
usptrerl the following recerd was krpe ale 50PA a the .pdfusptrerl the following recerd was krpe ale 50PA a the .pdf
usptrerl the following recerd was krpe ale 50PA a the .pdfpicscamshoppe
 
Using Ubuntu write a progam in C that do this A Wait for .pdf
Using Ubuntu write a progam in C that do this A Wait for .pdfUsing Ubuntu write a progam in C that do this A Wait for .pdf
Using Ubuntu write a progam in C that do this A Wait for .pdfpicscamshoppe
 
Using Ubuntu write a program uin C that do this A Wait for.pdf
Using Ubuntu write a program uin C that do this A Wait for.pdfUsing Ubuntu write a program uin C that do this A Wait for.pdf
Using Ubuntu write a program uin C that do this A Wait for.pdfpicscamshoppe
 
Using the RamseyCassKoopmans Model what policy would best.pdf
Using the RamseyCassKoopmans Model what policy would best.pdfUsing the RamseyCassKoopmans Model what policy would best.pdf
Using the RamseyCassKoopmans Model what policy would best.pdfpicscamshoppe
 
Using the pypcaptile library already available in the VLE.pdf
Using the pypcaptile library already available in the VLE.pdfUsing the pypcaptile library already available in the VLE.pdf
Using the pypcaptile library already available in the VLE.pdfpicscamshoppe
 
Using the Mpgcsv dataset b Run a basic linear regression.pdf
Using the Mpgcsv dataset b  Run a basic linear regression.pdfUsing the Mpgcsv dataset b  Run a basic linear regression.pdf
Using the Mpgcsv dataset b Run a basic linear regression.pdfpicscamshoppe
 
Using the payoffs for the HawkDove game that we discussed i.pdf
Using the payoffs for the HawkDove game that we discussed i.pdfUsing the payoffs for the HawkDove game that we discussed i.pdf
Using the payoffs for the HawkDove game that we discussed i.pdfpicscamshoppe
 
Using the line for the Annual mean calculate the average .pdf
Using the line for the Annual mean calculate the average .pdfUsing the line for the Annual mean calculate the average .pdf
Using the line for the Annual mean calculate the average .pdfpicscamshoppe
 
Using the information below to answer the following two ques.pdf
Using the information below to answer the following two ques.pdfUsing the information below to answer the following two ques.pdf
Using the information below to answer the following two ques.pdfpicscamshoppe
 
Using the information below to answer the following three qu.pdf
Using the information below to answer the following three qu.pdfUsing the information below to answer the following three qu.pdf
Using the information below to answer the following three qu.pdfpicscamshoppe
 
Using the following UML please create this java code I spe.pdf
Using the following UML please create this java code  I spe.pdfUsing the following UML please create this java code  I spe.pdf
Using the following UML please create this java code I spe.pdfpicscamshoppe
 
Using the following UML please create this code ltAbstrac.pdf
Using the following UML please create this code  ltAbstrac.pdfUsing the following UML please create this code  ltAbstrac.pdf
Using the following UML please create this code ltAbstrac.pdfpicscamshoppe
 
Using the following code Install Packages pip install .pdf
Using the following code Install Packages   pip install .pdfUsing the following code Install Packages   pip install .pdf
Using the following code Install Packages pip install .pdfpicscamshoppe
 
Using the data in the table to the right calculate the retu.pdf
Using the data in the table to the right calculate the retu.pdfUsing the data in the table to the right calculate the retu.pdf
Using the data in the table to the right calculate the retu.pdfpicscamshoppe
 

More from picscamshoppe (20)

Uzun vadeli yatrm kararlar ile ilgilenen finans alan olarak .pdf
Uzun vadeli yatrm kararlar ile ilgilenen finans alan olarak .pdfUzun vadeli yatrm kararlar ile ilgilenen finans alan olarak .pdf
Uzun vadeli yatrm kararlar ile ilgilenen finans alan olarak .pdf
 
Vaka 101 Zappos Yneticileri Ortadan Kaldryor evrimii ay.pdf
Vaka 101 Zappos Yneticileri Ortadan Kaldryor  evrimii ay.pdfVaka 101 Zappos Yneticileri Ortadan Kaldryor  evrimii ay.pdf
Vaka 101 Zappos Yneticileri Ortadan Kaldryor evrimii ay.pdf
 
Utilizacin de la inteligencia emocional en el lugar de trab.pdf
Utilizacin de la inteligencia emocional en el lugar de trab.pdfUtilizacin de la inteligencia emocional en el lugar de trab.pdf
Utilizacin de la inteligencia emocional en el lugar de trab.pdf
 
Utilizando el concepto de conocimiento metacognitivo los pr.pdf
Utilizando el concepto de conocimiento metacognitivo los pr.pdfUtilizando el concepto de conocimiento metacognitivo los pr.pdf
Utilizando el concepto de conocimiento metacognitivo los pr.pdf
 
Usted es miembro del grupo de relaciones con los empleados d.pdf
Usted es miembro del grupo de relaciones con los empleados d.pdfUsted es miembro del grupo de relaciones con los empleados d.pdf
Usted es miembro del grupo de relaciones con los empleados d.pdf
 
Usted es consultor comercial de People for the Ethical Treat.pdf
Usted es consultor comercial de People for the Ethical Treat.pdfUsted es consultor comercial de People for the Ethical Treat.pdf
Usted es consultor comercial de People for the Ethical Treat.pdf
 
usptrerl the following recerd was krpe ale 50PA a the .pdf
usptrerl the following recerd was krpe ale 50PA a the .pdfusptrerl the following recerd was krpe ale 50PA a the .pdf
usptrerl the following recerd was krpe ale 50PA a the .pdf
 
Using Ubuntu write a progam in C that do this A Wait for .pdf
Using Ubuntu write a progam in C that do this A Wait for .pdfUsing Ubuntu write a progam in C that do this A Wait for .pdf
Using Ubuntu write a progam in C that do this A Wait for .pdf
 
Using Ubuntu write a program uin C that do this A Wait for.pdf
Using Ubuntu write a program uin C that do this A Wait for.pdfUsing Ubuntu write a program uin C that do this A Wait for.pdf
Using Ubuntu write a program uin C that do this A Wait for.pdf
 
Using the RamseyCassKoopmans Model what policy would best.pdf
Using the RamseyCassKoopmans Model what policy would best.pdfUsing the RamseyCassKoopmans Model what policy would best.pdf
Using the RamseyCassKoopmans Model what policy would best.pdf
 
Using the pypcaptile library already available in the VLE.pdf
Using the pypcaptile library already available in the VLE.pdfUsing the pypcaptile library already available in the VLE.pdf
Using the pypcaptile library already available in the VLE.pdf
 
Using the Mpgcsv dataset b Run a basic linear regression.pdf
Using the Mpgcsv dataset b  Run a basic linear regression.pdfUsing the Mpgcsv dataset b  Run a basic linear regression.pdf
Using the Mpgcsv dataset b Run a basic linear regression.pdf
 
Using the payoffs for the HawkDove game that we discussed i.pdf
Using the payoffs for the HawkDove game that we discussed i.pdfUsing the payoffs for the HawkDove game that we discussed i.pdf
Using the payoffs for the HawkDove game that we discussed i.pdf
 
Using the line for the Annual mean calculate the average .pdf
Using the line for the Annual mean calculate the average .pdfUsing the line for the Annual mean calculate the average .pdf
Using the line for the Annual mean calculate the average .pdf
 
Using the information below to answer the following two ques.pdf
Using the information below to answer the following two ques.pdfUsing the information below to answer the following two ques.pdf
Using the information below to answer the following two ques.pdf
 
Using the information below to answer the following three qu.pdf
Using the information below to answer the following three qu.pdfUsing the information below to answer the following three qu.pdf
Using the information below to answer the following three qu.pdf
 
Using the following UML please create this java code I spe.pdf
Using the following UML please create this java code  I spe.pdfUsing the following UML please create this java code  I spe.pdf
Using the following UML please create this java code I spe.pdf
 
Using the following UML please create this code ltAbstrac.pdf
Using the following UML please create this code  ltAbstrac.pdfUsing the following UML please create this code  ltAbstrac.pdf
Using the following UML please create this code ltAbstrac.pdf
 
Using the following code Install Packages pip install .pdf
Using the following code Install Packages   pip install .pdfUsing the following code Install Packages   pip install .pdf
Using the following code Install Packages pip install .pdf
 
Using the data in the table to the right calculate the retu.pdf
Using the data in the table to the right calculate the retu.pdfUsing the data in the table to the right calculate the retu.pdf
Using the data in the table to the right calculate the retu.pdf
 

Recently uploaded

Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentInMediaRes1
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...JhezDiaz1
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersSabitha Banu
 
Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17Celine George
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxiammrhaywood
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Jisc
 
Judging the Relevance and worth of ideas part 2.pptx
Judging the Relevance  and worth of ideas part 2.pptxJudging the Relevance  and worth of ideas part 2.pptx
Judging the Relevance and worth of ideas part 2.pptxSherlyMaeNeri
 
What is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERPWhat is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERPCeline George
 
ACC 2024 Chronicles. Cardiology. Exam.pdf
ACC 2024 Chronicles. Cardiology. Exam.pdfACC 2024 Chronicles. Cardiology. Exam.pdf
ACC 2024 Chronicles. Cardiology. Exam.pdfSpandanaRallapalli
 
Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Mark Reed
 
How to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPHow to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPCeline George
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Educationpboyjonauth
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxOH TEIK BIN
 
Grade 9 Q4-MELC1-Active and Passive Voice.pptx
Grade 9 Q4-MELC1-Active and Passive Voice.pptxGrade 9 Q4-MELC1-Active and Passive Voice.pptx
Grade 9 Q4-MELC1-Active and Passive Voice.pptxChelloAnnAsuncion2
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for BeginnersSabitha Banu
 
Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Celine George
 

Recently uploaded (20)

TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdfTataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media Component
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginners
 
Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
Rapple "Scholarly Communications and the Sustainable Development Goals"
Rapple "Scholarly Communications and the Sustainable Development Goals"Rapple "Scholarly Communications and the Sustainable Development Goals"
Rapple "Scholarly Communications and the Sustainable Development Goals"
 
Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...
 
Judging the Relevance and worth of ideas part 2.pptx
Judging the Relevance  and worth of ideas part 2.pptxJudging the Relevance  and worth of ideas part 2.pptx
Judging the Relevance and worth of ideas part 2.pptx
 
What is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERPWhat is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERP
 
ACC 2024 Chronicles. Cardiology. Exam.pdf
ACC 2024 Chronicles. Cardiology. Exam.pdfACC 2024 Chronicles. Cardiology. Exam.pdf
ACC 2024 Chronicles. Cardiology. Exam.pdf
 
Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)
 
How to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPHow to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERP
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Education
 
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptx
 
Grade 9 Q4-MELC1-Active and Passive Voice.pptx
Grade 9 Q4-MELC1-Active and Passive Voice.pptxGrade 9 Q4-MELC1-Active and Passive Voice.pptx
Grade 9 Q4-MELC1-Active and Passive Voice.pptx
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for Beginners
 
Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17
 

Utilize the following code seqments for Problems A 5 Void T.pdf

  • 1. Utilize the following code seqments for Problems A 5. Void Task_Flash(void) { If ( left(mathrm{g}_{text {flash_LED }}==1right) ) // Switch #1 Pressed Contro_RGB_LEDs (1,1,1); Delay(g_w_delay): Contro_RGB_LEDs (0,0,0); Delay(B_w_delay); Ji fir Void Task_RGB(void) { If (B_flash_LED ==0 ) { // Switch #1 Released Contro_RGB_LEDs (1,0,0); Delay(B_RGB_delay); Contro_RGB_LEDS (0,1,0); Delay(g_RGB_delay): Contro_RGB_LEDs (0,0,1); Delay(B_RGB_delay); } } Void Flasherf(void) i While (1) f Task_Flash(); Task RGB(); bi };5. Consider the approach from the section titled Task Preemption and reference the diagram below. Assume that the IRQ handler can tell the scheduler to change which task to run, and that tasks can preempt each other. Assume that PORTD_IRQHandler starts executing as soon as the switch changes from pressed to released, or from released to pressed. Assume there is no time taken to switch between tasks or the handler, and that the tasks and handier have the following execution times: a. Describe the sequence of events which leads to the maximum delay between pressing the switch and seeing the LED flash sequence. Calculate the value of that delay, and indicate all assumptions that you are making in regards to your solution. (5 Points)b. Describe the sequence of events which leads to the maximum delay between pressing the switch and seeing the LED RGB color sequence. Calculate the value of that delay. ( 5 Points)