ADC state machine upgraded (reset added), ready for testing.