Google API - Text To Speech and Speech to Text

15
USING GOOGLE APIS Y. Hari

description

The application of google api for Text To Speech and Speech to Text

Transcript of Google API - Text To Speech and Speech to Text

USING GOOGLE APIS Y. Hari

WHAT IS GOOGLE APIS?

“Google APIs is a set of APIs developed by Google which allow communication with Google Services and their

integration to other services”

IN THIS SESSION WE WILL LEARN TO USE

TEXT-TO-SPEECH AND SPEECH-TO-TEXT

API from Google!

TEXT TO SPEECH API

Please note this feature is available from Android 1.6/ Éclair (Above)

You can use the emulator to emulate

Lastly this feature can PRONOUCIATE your word based on what the Google Speech API in your mobile phone.

SPEECH TO TEXT API

Please note this feature is available from Android 3.0 Above

Use your mobile phone for testing and don’t use emulator. It wont work cause its require internet connection.

Lastly this feature can predict your word based on what the Google perceive it.

TUTORIAL

We want to make a simple Text-To-Speech to say what we write

and

Speech-To-Text to write what we say.

HOW TO

Create 3 activity:

Main Menu (mainActivity)

ToSpeak Activity

To Lister Activity

Use the intent to join several activity together!

MAIN

Don’t Forget this!

Parameter for Text To

Speech

To call Recognizer

Intent

Be careful you need to

write EXACLY THE

SAME METHOD!

TRY IT ON YOUR PHONE

To change the language change this code:

intent.putExtra(RecognizerIntent.EXTRA_LANGUA

GE_MODEL, "en-US");

Change this locale to your speaking language!

IDEA

You can make this simple idea to make some awesome apps like:

Write an SMS using voice command

Games control using a voice command

Command application using a voice

Talking calculator

etc

HOME WORK?

This week is homework free day!

Just learn by yourself about this code okay?

QUESTION?