Finite State Machines in Hardware (Theory and Design (with VHDL and SystemVerilog))