TexttoSpeech has a 4th parameter callback
function()
which I presume should call my function when it has completed
I coded
app.TextToSpeech(phrase,,,quiet);
but I got error Unexpected token ","
So I specified pitch and rate 1.0
app.TextToSpeech(phrase,1.0,1.0,quiet);
And it seems to work