<@U084APK40NS> I'm attempting to send DTMF via `pu...
# ask-ai
r
@millions-hair-24956 I'm attempting to send DTMF via
publishDtmf
(using the
@livekit/rtc-node
package). I'm not seeing any
RoomEvent.DtmfReceived
events nor hearing dial tones on my call, so I'm not sure whether it's succeeded. 1. Is the
RoomEvent.DtmfReceived
event only emitted for other participants' DTMF tones? 2. If so, is it possible to listen for my own participant's DTMF tones? 3. Should I be hearing dial tones on the call if DTMF succeeds? I suppose the general thing I'm actually trying to confirm is - how do I confirm that DTMF sending succeeded?
g
It seems likely that the
RoomEvent.DtmfReceived
event is emitted for DTMF tones received from other participants, not the local participant's own tones. According to the LiveKit documentation, the
sipDTMFReceived
event is triggered when SIP DTMF tones are received from another participant. This suggests that you may not receive this event for DTMF tones you send yourself. To confirm if your DTMF tones are being sent successfully, you might want to check if the tones are being received by the intended recipient or system. If you are not hearing dial tones, it could be due to the configuration of your SIP setup or the receiving system not providing feedback. You can also verify the DTMF transmission by monitoring the call status or logs on the receiving end to ensure the tones are being processed correctly. Would you like more detailed information on how to troubleshoot or verify DTMF transmission in your setup? Sources: - https://docs.livekit.io/client-sdk-js/enums/ParticipantEvent.html 👍 0 button 👎 0 button 💡 Hint: Mention @runllm in the thread for followups.
r
@millions-hair-24956 Thanks. 1. What configuration of my SIP setup would prevent being able to hear dial tones? 2. I'm calling from an iPhone to a Twilio number that's connected to Livekit via SIP. Should I expect to hear feedback on an iPhone?
g
It seems likely that certain configurations in your SIP setup could prevent you from hearing dial tones. According to LiveKit documentation, the
playDialtone
option in the
CreateSipParticipantOptions
can be set to
true
to enable dial tone playback while the call is dialing. If this option is not enabled, you might not hear any dial tones during the call setup. Regarding feedback on an iPhone, it seems likely that you should expect to hear feedback if the SIP setup is configured correctly and the
playDialtone
option is enabled. However, if the SIP trunk or the receiving system (e.g., Twilio) does not support or is not configured to provide audio feedback, you might not hear the dial tones. Would you like more detailed information on configuring your SIP setup to ensure dial tone feedback? Sources: - LiveKit documentation 👍 0 button 👎 0 button 💡 Hint: Mention @runllm in the thread for followups.
r
yes please @millions-hair-24956
g
To ensure you hear dial tones during a call setup, you need to configure your SIP setup correctly. Here's a step-by-step breakdown: 1. Enable Dial Tone Playback: When creating a SIP participant for an outbound call, ensure that the
playDialtone
option is set to
true
. This option is part of the
CreateSipParticipantOptions
and allows the SIP participant to play a dial tone in the room until the call is picked up. This is crucial for hearing feedback during the call setup.
Copy code
{
  "sip_trunk_id": "<your-trunk-id>",
  "sip_call_to": "<phone-number-to-dial>",
  "room_name": "my-sip-room",
  "participant_identity": "sip-test",
  "participant_name": "Test Caller",
  "play_dialtone": true
}
2. Check SIP Trunk Configuration: Ensure that your SIP trunk is correctly configured to handle audio feedback. This includes verifying that the trunk supports the necessary audio codecs and that there are no restrictions on audio playback. 3. Verify Twilio and LiveKit Integration: Since you're using Twilio, ensure that the integration between Twilio and LiveKit is set up correctly. This includes checking that the SIP trunk is properly registered and that there are no issues with the network or firewall settings that might block audio traffic. 4. Test with Different Devices: If possible, test the setup with different devices to rule out any device-specific issues. This can help determine if the issue is with the iPhone or the SIP setup. By following these steps, you should be able to configure your SIP setup to provide dial tone feedback during call setup. If issues persist, consider checking the logs on both the LiveKit and Twilio sides for any errors or warnings that might indicate a configuration problem. Sources: - LiveKit documentation 👍 0 button 👎 0 button 💡 Hint: Mention @runllm in the thread for followups.
r
@millions-hair-24956 does LiveKit send DTMF tones in-band or out-of-band?
g
I'm not able to find any data sources to answer your question. You might want to specify whether you are using a specific SDK or configuration in your setup. If this doesn't help, please reach out to the Livekit support team for further assistance. 👍 0 button 👎 0 button 💡 Hint: Mention @runllm in the thread for followups.