You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm filing this here mostly for documentation, and to serve as the reference point for any upstream issues we choose to file.
I have an app using adhearsion-ivr with speech input. When attempting speech recognition on an incoming call, the Prompt component was crashing because of a fault returned by UniMRCP in Asterisk. The prompt response looks like this:
/* Write synthesized speech / speech to be recognized. */intspeech_channel_write(speech_channel_t*schannel, void*data, apr_size_t*len)
{
intstatus=0;
if ((schannel!=NULL) &&*len!=0) {
// Code elided: write speech data to channel
} else {
ast_log(LOG_ERROR, "Speech channel structure pointer is NULL.\n");
return-1;
}
By adding debug logging to UniMRCP I was able to determine that the problem wasn't actually that schannel was null, but instead len was 0. This was the clue that made me realize that the channel was not answered, thus an empty voice frame was attempting to be written.
Workaround
I added this to the top of my AdhearsionIVR::CallController
before_call{answer}
This is because AdhearsionIVR does not auto-answer the channel. We won't fix this in AdhearsionIVR because it probably shouldn't auto-answer, in case someone wants to use early media.
The real fix will have to come upstream from UniMRCP since it is failing to recognize if the channel is not answered, but also not logging any useful error message to that effect.
The text was updated successfully, but these errors were encountered:
I'm filing this here mostly for documentation, and to serve as the reference point for any upstream issues we choose to file.
I have an app using adhearsion-ivr with speech input. When attempting speech recognition on an incoming call, the Prompt component was crashing because of a fault returned by UniMRCP in Asterisk. The prompt response looks like this:
On the Asterisk side, two errors and one warning were logged by UniMRCP:
The error message is generated by this code:
By adding debug logging to UniMRCP I was able to determine that the problem wasn't actually that
schannel
was null, but insteadlen
was 0. This was the clue that made me realize that the channel was not answered, thus an empty voice frame was attempting to be written.Workaround
I added this to the top of my
AdhearsionIVR::CallController
This is because AdhearsionIVR does not auto-answer the channel. We won't fix this in AdhearsionIVR because it probably shouldn't auto-answer, in case someone wants to use early media.
The real fix will have to come upstream from UniMRCP since it is failing to recognize if the channel is not answered, but also not logging any useful error message to that effect.
The text was updated successfully, but these errors were encountered: