Getting exception when deploy Speech SDK on Azure webapp SPXERR_MIC_NOT_AVAILABLE
sam
206
Reputation points
Describe the bug
When I am trying to deplpy my Speech SDK (from Microphone To Speech)on Azure webapp getting SPXERR_MIC_NOT_AVAILABLE though it is working locally and over local iis deployed also.
To Reproduce
Steps to reproduce the behavior:
Write below method on .net core api and deploy on Azure
public async Task<IActionResult> MicrophoneToSpeechAsync(string languageIso6391Code)
{
var subscription = _config.GetValue<string>("SubscriptionId");
var location = _config.GetValue<string>("Region");
var config = SpeechConfig.FromSubscription(subscription, location);
config.SpeechRecognitionLanguage = string.IsNullOrWhiteSpace(languageIso6391Code) ? "en-us" :
languageIso6391Code;
// Creates a speech recognizer.
using (var recognizer = new SpeechRecognizer(config))
{
Console.WriteLine("Say something...");
var result = await recognizer.RecognizeOnceAsync();
List<SpeechCommonService.DetectedLanguage> language = null;
// Checks result.
if (result.Reason == ResultReason.RecognizedSpeech)
{
Console.WriteLine($"We recognized: {result.Text}");
}
}
}
Extected behaviour
It should understand the spoken words over microphone and convert it to text.
Azure AI Speech
Azure AI Speech
An Azure service that integrates speech processing into apps and services.
2,061 questions
Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
8,933 questions
Sign in to answer