comilation and testing
update all testing done, state machine working fine