1. Engineering
  2. Computer Science
  3. for the questions below write the code using the masks...

Question: for the questions below write the code using the masks...

Question details

For the questions below, write the code using the masks that are pre-defined in the header file. (E.g: BIT0:0000 0001, BIT1:0000 0010, …, BIT7:1000 0000)

MSP430 ASSEMBLY code

For the questions below, write the code using the masks that are pre-defined in the header file. (E.g. BITO:0000 0001, BITI:0000 0010, ..., BIT7:1000 0000) Perform the operations below on the 8-bit variable (uint_8t data) Part a) Write code that performs the three operations below. Perform each operation independently of the others. Set bit 6 . -2 Clear bit 6 Invert bit 6 . Part b) Write code that performs the three operations below. Perform each operation independently of the others. Set bits 4 and5 Clear bits 4 and 5 Invert bits 4 and 5 Set bit 4 and clear bit 5 Part c) Write an if-condition line for each of the cases below. Perform each operation independently of the others. Check if bit 2 is 1 Check if bit 2 is 0. . Check if bits 3,4 are 1,1 Check if bit 3 is 0 and bit 4 is 1 . Check if bits 3, 4 are 0,0

Solution by an expert tutor
Blurred Solution
This question has been solved
Subscribe to see this solution