Giter VIP home page Giter VIP logo

softphone's Introduction

Softphone

A python 3 compatible softphone built on the pjproject fork by malarinv, branch:py37.

To use the streaming capability, use an Audio Callback class that suits your needs.

See AudioCallbacks.py for examples.

For installation instructions, click here.


TODO

  • Fix the slight audio lag/delay when using Audio Callbacks for relaying audio between systems.
  • Check if adjusting pj thread value helps on the lag like here. Helped a little bit..? Not sure, can be a coincidence.
  • Clean up the code.
  • Write documentation for all functions.
  • Add proper logging.
  • Add DTMF support.
  • Add call transfer support.
  • Fix and test incoming calls.
  • Do not force registration of both incoming and outgoing accounts. Make it optional.
  • Fix better error handling.
  • Fix error when phone hangs up before softphone does.
  • Fix error when phone is not answered and we reach voicemail. Softphone becomes unresponsive.
  • Create a Pypi package to install via pip install softphone.
  • Add support for multiple simultaneous calls.

Missing something?

You can look for functionality from other projects and create a PR to get it added to this project.

Examples:

softphone's People

Contributors

dependabot[bot] avatar nicolaipre avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

softphone's Issues

OSError: PortAudio library not found

Traceback (most recent call last):
File "/home/addy/Telephony-AI/softphone/example.py", line 11, in
from softphone.AudioCallbacks import EchoAudioCB, SystemAudioCB
File "/home/addy/Telephony-AI/softphone/softphone/AudioCallbacks.py", line 5, in
import sounddevice as sd
File "/home/addy/.local/lib/python3.10/site-packages/sounddevice.py", line 71, in
raise OSError('PortAudio library not found')
OSError: PortAudio library not found

its not working

I mean i run example.py and I have entered my details but if i make a call and enter phone number on which I want to call nothing happens

output:
`addy@Addy-PC:~/Telephony-AI/softphone$ /bin/python3 /home/addy/Telephony-AI/softphone/example.py
12:42:04.901 os_core_unix.c !pjlib 2.9-svn for POSIX initialized
12:42:04.902 sip_endpoint.c .Creating endpoint instance...
12:42:04.902 pjlib .select() I/O Queue created (0x55b521039000)
12:42:04.902 sip_endpoint.c .Module "mod-msg-print" registered
12:42:04.902 sip_transport.c .Transport manager created.
12:42:04.902 pjsua_core.c .PJSUA state changed: NULL --> CREATED
Softphone is now ready...

+-Menu-------------+
| m = make call |
| h = hangup call |
| a = answer call |
| q = quit |
+------------------+

m
Number with country code 00x (ex: 0014446665555)> 00918840xxxxxx

+-Menu-------------+
| m = make call |
| h = hangup call |
| a = answer call |
| q = quit |
+------------------+

`

same thing will happen when I enter a real number

Documentation on audio devices

Hi,

After spending ages on getting a softphone on Python3 working on a Raspian Bullseys 32-bit I accidentally found this outstanding work, build on deprecated PJSIP stuff, but it seems to work. I now have some basis end users questions, for starters: is there any documentation available on the softphone package? More specifically, I like to know how to use USB speaker/mic of other audio devices to actually perform a real conversation. Any help would be very welcome.

Cheers, Arjen

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.