question

ZhuangHongChong-2677 avatar image
0 Votes"
ZhuangHongChong-2677 asked romungi-MSFT edited

Text to Speech unable to function

2021-07-20 12:31:37.062639+0800 helloworld[6354:1734305] [connection] nw_endpoint_handler_set_adaptive_read_handler [C1.1 52.152.207.162:443 ready socket-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, ipv6, dns)] unregister notification for read_timeout failed

2021-07-20 12:31:37.062710+0800 helloworld[6354:1734305] [connection] nw_endpoint_handler_set_adaptive_write_handler [C1.1 52.152.207.162:443 ready socket-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, ipv6, dns)] unregister notification for write_timeout failed

azure-speech
· 8
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

@ZhuangHongChong-2677 It would be great if you could provide more details about the scenario or documentation you are following before this message is seen. This would help other members of the community to understand the scenario and respond appropriately.

0 Votes 0 ·

I am using the free subscription. Speech to text works fine for me but there is an error while running text to speech.

0 Votes 0 ·

Thanks for your reply. I have been following this and tried to run it in the Xcode. I am running the code for the sample app.
https://github.com/Azure-Samples/cognitive-services-speech-sdk/tree/master/quickstart/swift/ios/text-to-speech

0 Votes 0 ·

Ok thanks for sharing. I do not have much of an experience on ios so I hope others in the community could help.
Having looked up the issue online though, it seems like an Xcode issue as mentioned in this thread on apple developer forums.


0 Votes 0 ·

Owh ya thank you so much. I tried the solution given. Yeppp..the error message gone but there is still no sound been synthesised.

0 Votes 0 ·
Show more comments

1 Answer

romungi-MSFT avatar image
0 Votes"
romungi-MSFT answered romungi-MSFT commented

Could you try this for initializing the SPXSpeechSynthesizer()? As per the STT sample this is the only difference I could spot that could fail the sample.

 let synthesizer = try! SPXSpeechSynthesizer(speechConfiguration: speechConfig!)


· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Ahhh..It works!! I rerun the project a few times. Thank you so much. I was wondering how to set the synthesizer to a different voice and language? Like the one shown here.
https://azure.microsoft.com/en-us/services/cognitive-services/text-to-speech/#features

116227-screenshot-2021-07-20-at-53609-pm.png


0 Votes 0 ·

@ZhuangHongChong-2677 I think you need to set this in properties of the speech config. Please refer the SDK documentation for more information.
If the above response helped, please feel free to accept the same as answer. Thanks!!


0 Votes 0 ·