Write a complete MicroC program for synchronising the access of an integer variable ‘Var’ shared between two tasks using ‘disabling task scheduling technique’ as per the following...


Write a complete MicroC program for synchronising the access of an integer variable ‘Var’ shared between two tasks using ‘disabling task scheduling technique’ as per the following requirements                      (a) Create two tasks with names Task1 and Task2 with stack size 1024 and priorities 9 and 10 respectively   (b) Task1 increments the shared variable and prints its value with the message “From Task1 : Var = ” (Assume that the compiler in use has a MicroC library implementation for the printf() function tailored for the target processor port) and sleeps for 20 Timer Ticks   (c) Task2 decrements the shared variable and prints its value with the message “From Task2 : Var = ” (Assume that the compiler in use has a MicroC library implementation for the printf() function tailored for the target processor port) and sleeps for 20 Timer Ticks   (d) The tasks are created in the order Task2, Task1



May 18, 2022
SOLUTION.PDF

Get Answer To This Question

Submit New Assignment

Copy and Paste Your Assignment Here