Consider the following C function:
1 char r( char input ) { // a char has 8 bits
2 // length stores the number of bits of ‘input ’
3 unsigned int length =8;
4 unsigned int i=0;
5 char result =0;
6 char temp =0;
7 for (i =0; i< length ; ++i) {
8 if (( input & 1) == 1) {
9 temp = temp | 1;
10 }
11 result = temp;
12 input = input >> 1;
13 temp = temp << 1;
14 }
15 return result ;
16 }
Implement the function as an entity in VHDL (including entitydeclaration and architecture). You can use
only concurrent statements.
Expert Answer
An
PayPal Gateway not configured
PayPal Gateway not configured