Question: For this assignment you are to use FreeRTOS to study multitasking. Return a zip file containing The code. Please comment your code and include your

 For this assignment you are to use FreeRTOS to study multitasking.

For this assignment you are to use FreeRTOS to study multitasking. Return a zip file containing The code. Please comment your code and include your name in the source files. The results of execution Create the tasks shown in the figure below; give these tasks the same priority. What would you do if you want the final values to be 5 1. 20 for Nand 300 for Res. N 100; Res = 50; Task1) Task2() Task30 N=N+3"Res ; Res-Res +50 Prinf("The value of N is %d", N) Print("The value of Res is %d", Res); N = N + 2*N+70 ; Prinf("The value of N is d", N); Print( "The value of Res is %d", Res); Res-5"Res ; Print("The value of N is %d", N); Print( "The value of Res is %d", Res); 2. Assign the priorities 50 (lowest), 100, 150 (highest) to Taskl, Task2, and Task3 respectively. Using semaphores, run these tasks in the following orders a. Task2, Task1, Task3; b. Taskl, Task2, Task3 3. Create three one-shot software timers. The timeout values are 2s, 3s, and 5s, respectively. Their callback functions are the three task functions in Question #1 without the two printf instructions. Create another auto-reload software timer with a period of 1s. Its callback function prints out the values of N and Res. For this assignment you are to use FreeRTOS to study multitasking. Return a zip file containing The code. Please comment your code and include your name in the source files. The results of execution Create the tasks shown in the figure below; give these tasks the same priority. What would you do if you want the final values to be 5 1. 20 for Nand 300 for Res. N 100; Res = 50; Task1) Task2() Task30 N=N+3"Res ; Res-Res +50 Prinf("The value of N is %d", N) Print("The value of Res is %d", Res); N = N + 2*N+70 ; Prinf("The value of N is d", N); Print( "The value of Res is %d", Res); Res-5"Res ; Print("The value of N is %d", N); Print( "The value of Res is %d", Res); 2. Assign the priorities 50 (lowest), 100, 150 (highest) to Taskl, Task2, and Task3 respectively. Using semaphores, run these tasks in the following orders a. Task2, Task1, Task3; b. Taskl, Task2, Task3 3. Create three one-shot software timers. The timeout values are 2s, 3s, and 5s, respectively. Their callback functions are the three task functions in Question #1 without the two printf instructions. Create another auto-reload software timer with a period of 1s. Its callback function prints out the values of N and Res

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!