Z
zidong
Guest
Design a circuit that has the following function:
If C=00: shift A one step to the left (shift in 0 on LSB)
If C=01: shift A one step to the right (shift in 0 on MSB)
If C =10: rotate A one step left
If C=11: rotate A one step right
Input: A (std_logic_vector(7 downto 0))
C (std_logic_vector(1 downto 0)
Output: Z (std_logic_vector(7 downto 0)) the result of the shifting
or rotation of
A
thanks in advance.
If C=00: shift A one step to the left (shift in 0 on LSB)
If C=01: shift A one step to the right (shift in 0 on MSB)
If C =10: rotate A one step left
If C=11: rotate A one step right
Input: A (std_logic_vector(7 downto 0))
C (std_logic_vector(1 downto 0)
Output: Z (std_logic_vector(7 downto 0)) the result of the shifting
or rotation of
A
thanks in advance.