Code example for AudioRecord

Methods: readstartRecording

0
	 * Call after prepare(). 
	 *  
	 */ 
	public void start() { 
		if (state == State.READY) {
			audioRecorder.startRecording();
			audioRecorder.read(buffer, 0, buffer.length);	//[TODO: is this necessary]read the existing data in audio hardware, but don't do anything
			state = State.RECORDING;
		} else { 
			Log.e(PcmAudioRecorder.class.getName(), "start() called on illegal state");
			state = State.ERROR;
		} 
	} 
	 
	/** 
	 *  
	 *  
	 *  Stops the recording, and sets the state to STOPPED. 
	 * In case of further usage, a reset is needed. 
	 * Also finalizes the wave file in case of uncompressed recording. 
	 *