def speechRecognizer_didRecognizeCommand_(self,sender,userInput):
		print ("speechRecognizer_didRecognizeCommand_", userInput)

		if (userInput == "Quit the test."):
			os.system("say quiting the test...")
			sys.exit()

		mabResponses.respondInput(self.myBuddy,userInput,False)
	def collectInput(self,isSilent):
		if (self.inputType=="VocalInput"):
			r = sr.Recognizer()

			r.energy_threshold = 3000

			r.pause_threshold = 1.5

			with sr.Microphone() as source:
				audio = r.listen(source)

			try:
				userInput = r.recognize(audio)
			except KeyError:
				userInput = "N01nt3rn31"
			except LookupError:
				userInput = "##--(system)error: did not understand response.--##"

		else:
			userInput = ""
			userInput=str(input())

		mabUtilities.logInput(userInput)

		userInput=userInput.capitalize()
			
		return mabResponses.respondInput(self,userInput,isSilent)
def collectInput(isSilent):

	r = sr.Recognizer()

	r.energy_threshold = 3000

	r.pause_threshold = 1.5

	with sr.Microphone() as source:
		audio = r.listen(source)

	try:
		userInput = r.recognize(audio)
	except KeyError:
		userInput = "No internet"
	except LookupError:
		userInput = "##--(system)error: did not understand response.--##"


	#userInput = ""
	
	#userInput=str(input())

	mabUtilities.logInput(userInput)

	userInput=userInput.capitalize()
		
	return mabResponses.respondInput(userInput,isSilent)