working on pulse_in demo