Added ability to record samples from microphone