A. 53 B. 19 C. 74 D. 115 66. enum BL States BL LedOff, BL Led0n BL State; 67. nt
ID: 3913313 • Letter: A
Question
A. 53
B. 19
C. 74
D. 115
66. enum BL States BL LedOff, BL Led0n BL State; 67. nt TickFct _BlinkLed (int state) I 68 VARIABLES MUST BE DECLARED STATIC/ 69-/te.g., static int x 03/ 70. Def ine user variables for this state nachine here 71. svitch state) // 2. This code vas aut onat i cally generated using the Riverside Irvine State machine Builder tool 3. Version 2.5 10/18/2012 10:2:14 PST 6·#include "rimsh" case: state = BL-Led0ff; 9. /This code ill be shared betven state nachines.* 10. typedef struct task I case BL Ledoff: int state; state BL LedOn: 12. unsizned lon per i od: 13. unsizned lon elapsedT i ne; 14 int (TickFct) (int); break; case BL Ledon 80 17. task tasks[21: state BL LedOff: 84 re 19. const unsigned char tasksNum = 2; 20. const unsigned long periodBlinkLed = 1500; 21. const unsigned long periodThreeLeds = 500; default: state1 Transitions 23. const unsi gned long tasksPeriodGCD 500; 89. svitch(state) // case BL_Ledoff 25. int TickFct BlinkLed (int state); 26. int TickFct ThreeLeds (int state): BO-0; break; case BLLedon: 28. unsigned char process ineRdyTasks = 0; 29. void TierISR 30 unsi gned chari 31 if (processinRdyTasks) 32 94 default: // break; print f ("Period too short to complete taskstn"); 34. 35. 36 98. // State actions 99. BL State st ate; 100 return state; process i n2RdyTasks=1; for (i = 0; iExplanation / Answer
The correct ansewer is A.53
This is where task state is set as -1. And based on this value "TicketFct_ThreeLeds()" function sets the state as starting state = TL_TO
Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.