#include <stdio.h>
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
#include <stdint.h>
void printbin8(uint8_t valu) {
printf("The value of %u in binary is: 0b", valu); // Use %u for uint8_t
// Loop through each bit from Most to left which ends at 255
for (int i = 7; i >= 0; i--) {
printf("%d", (valu >> i) & 1); // Shift and mask to get the bit
}
printf("\n"); // adding a new line after eveyy number
}
void app_main() {
uint8_t count = 0; // Initializing count to 0
while (1) {
printbin8(count); // Print binary representation of count
count++; // Increment count
vTaskDelay(100 / portTICK_PERIOD_MS); // Delay for 500 milliseconds
}
}