Verilog, Uart, Protocol, Electroni, Fpga.
DATA0 to DATA6 practically does the samething. So we can refactor this to be much shorter and needed lesser ‘states’ by introducing a new register to keep track of the data bit being read reg [3:0] bit_count; And the code change to reflect this (after adding STOP as well) always@(posedge s_tick)