This week's book giveaway is in the Kotlin forum.
We're giving away four copies of Kotlin for Android App Development and have Peter Sommerhoff on-line!
See this thread for details.
Win a copy of Kotlin for Android App Development this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Devaka Cooray
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Junilu Lacar
  • Paul Clapham
  • Knute Snortum
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • salvin francis
  • Carey Brown
Bartenders:
  • Tim Holloway
  • Frits Walraven
  • Ganesh Patekar

Search Button with speech recognition (ANDROID)  RSS feed

 
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I made these two functions for speech recognition. the first function is called by a button in mainActivity. onActivityResult I am trying to compare speechResult exists in my file and if it exists I want to call PlayVideo activity but this never happens... in other words I want the user press the button and speak, after that, I want to search the speechresult in my file of videos and display him that title that said. for example, if my file got the title "butterfly" and user said it, i want to display him this video.


 
Rancher
Posts: 3353
33
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How are you trying to debug the code to see what it is doing?
I use print statements that write values to the logcat so I can see the values in the variables to understand what the code is doing.
 
John Vario
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I was testing it in my smartphone... it recognises the speech but doesnt redirect them to video , for example i am saying butterfly , it is recognising the phrase, but it doesnt redirect me to the specific video... (the video title exists in file)
 
Norm Radder
Rancher
Posts: 3353
33
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

it doesnt redirect me to the specific video...


What code is supposed to do that?  Is the code working the way you want?  If not, why not?  
Debug the code to see what it is doing.
 
Everybody's invited. Except this tiny ad:
Programmatically Create PDF Using Free Spire.PDF with Java
https://coderanch.com/wiki/703735/Programmatically-Create-PDF-Free-Spire
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!