(Solved):
5. (a) Find the logic operation for an 8-bit data to clear bits 2 and 4 of an 8-bit number, 7EH to ...
5. (a) Find the logic operation for an 8-bit data to clear bits 2 and 4 of an 8-bit number, 7EH to 0's without changing the other bits. (b) Find the logic operation for an 8-bit data to set bits 0 and 7 of an 8-bit number, 3AH to l's without changing the other bits. (c) Find the overflow bit after performing an arithmetic shift on B6H three times to the left. 14. In a biscuit factory, a control system has been designed based on an Arduino Uno microcontroller. This system transfers the biscuit packets at a regular time interval to the conveyer belt from the biscuit-making machine. It was found that the Timer modules in the Arduino microcontroller are perfect candidates to count the number of biscuit packets being transferred to the conveyer belt correctly and appropriately. Compute the number of biscuit packets being transferred using the Timers within the following time intervals (Timer0 or Timer1 may be used based on need). a) 100 ms b) 5000 ms Assume that the Arduino system clock has been set at 32 MHz and the available pre-scalers of the system are 1, 8, 64, 256, 512, and 1024. Comment on why and how the required counts are possible to implement using the Timer0 or Timer1. Write down the program codes for the Arduino board.