question

nathanmani avatar image
nathanmani asked

Breaking existing connection/Restart audio streaming at middle of AVS Req

Hi, We have ported AVS on our device using libcURL APIs. Currently, once the wake-up word is detected, we are connecting to AVS and every time sending 10 msec live audio stream data to AVS till continuous silence is detected. Now, our requirement is we need to break the existing connection with AVS or restart only audio streaming on existing connection at middle of the request to handle multiple questions with multiple wake-up word detection without gap/silence. Example: “wakeup word” what is the time “wakeup word” how are you In above example, we would like to receive the response for second question i.e “how are you” For that do we need to break the existing connection quickly or restart the audio streaming on existing connection? Please suggest us how to do? Thanks & Regards, M.Nathan Message was edited by: nathanmani
alexa voice service
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

swasey@amazon avatar image
swasey@amazon answered
How you do that would entirely depend on libcurl. You'll want to look up how to abort a request in progress with libcurl so that you don't get any responses. This stackoverflow might be helpful: http://stackoverflow.com/questions/8415976/example-how-to-cancel-a-libcurl-request So: "wake word" - starts request "what is the..." - streams audio to service "wake word" - aborts previous request, starts new request "how are you?" - streams audio to service, get response, speak response
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

nathanmani avatar image
nathanmani answered
Thank you so much .. we will try
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.