Home › Practice › RTL Design › 4-bit shift register
4-bit shift register
EasyRTLsequential
Build a 4-bit shift register that shifts right.
- On each rising edge,
qshifts right by one: the oldq[3]moves toq[2], and so on, and the oldq[0]is dropped. - The new bit
dinenters at the MSB,q[3]. rstis synchronous, active-high, and setsqto 0000.
Example: from q=0000, feeding din=1,1,0 gives 1000, 1100, 0110.
No install and no sign-up needed. You write your answer in the editor and Nishkam checks it.