gdereese / dtmf

Package for working with DTMF - a system for signaling over the voice band of a telephony system using multi-frequency tones.
MIT License
5 stars 2 forks source link

No sound #2

Closed Y2kdancr closed 5 months ago

Y2kdancr commented 5 months ago

I am using a RPI Zero with python3. When attempting to "Generating DTMF audio from a dial string" everything seems to work well as I get no errors. Yet I am not getting the audio of the generated tones. No doubt I am not doing something right. I am as new as you can get with python.

gdereese commented 5 months ago

The generate() function returns the audio sample data that, when played back, results in the DTMF tone sequence you requested. You will need to write additional code to do something with that audio data, such as play it back via an audio device on the machine, save it to an audio file for later playback, etc.

Y2kdancr commented 5 months ago

Thank you for your response. I appreciate your effort to write and post the code. Unfortunately, I don't have the expertise to use the data in a viable method.

Several years ago I embarked on an adventure to create a cellular payphone. The project involved the below:

  1. an old payphone.
  2. Arduino 2560 Mega.
  3. LTE1690 IC to generated Touchtone.
  4. LMC6484IN to generate dialtone.
  5. MT8870 to decode touch tone.
  6. SIM900 to make cell calls
  7. 4 relay module.

The Arduino was used to interface between the various modules. Collecting coin values before a call was allowed. Collecting and sending dialed digits to the sim900. Refunding or keeping money if the call was not or was successful, etc.. Happily the project was a success and has worked well... Unfortunately when 2G was shutdown in the US the SIM900 no longer works for making calls.

I've have ordered a SIM7600A-H that works with 4G. There are references to it being used on the PI. I was hoping by using the Pi I could eliminate the use of the IC's and DTMF decoder.

I guess I will just stick with what I have and try to get the SIM7600 working on the Arduino. Thanks again!

gdereese commented 5 months ago

This library also has the ability to decode DTMF from an audio buffer; you just have to write the code to receive the audio buffer from your audio input device and pass it to the detect() function.

At any rate, sounds like an interesting project. I wish you the best of luck!