audiosocket: added support for DTMF frames

Updated the AudioSocket protocol to allow sending DTMF frames.
AST_FRAME_DTMF frames are now forwarded to the server, in addition to
AST_FRAME_AUDIO frames. A new payload type AST_AUDIOSOCKET_KIND_DTMF
with value 0x03 was added to the protocol. The payload is a 1-byte
ascii representing the DTMF digit (0-9,*,#...).

UserNote: The AudioSocket protocol now forwards DTMF frames with
payload type 0x03. The payload is a 1-byte ascii representing the DTMF
digit (0-9,*,#...).
This commit is contained in:
Florent CHAUVEAU
2025-02-28 08:47:18 +01:00
committed by github-actions[bot]
parent 6ef4a2d008
commit a5bc39fa32
4 changed files with 61 additions and 13 deletions

View File

@@ -44,6 +44,9 @@ enum ast_audiosocket_msg_kind {
/*! \brief Message contains the connection's UUID, direction: Received only. */
AST_AUDIOSOCKET_KIND_UUID = 0x01,
/*! \brief Message contains a DTMF digit, direction: Received only. */
AST_AUDIOSOCKET_KIND_DTMF = 0x03,
/*! \brief Messages contains audio data, direction: Sent and received. */
AST_AUDIOSOCKET_KIND_AUDIO = 0x10,