Get help with installing, upgrading and running a PBX such as Asterisk.
50 % 50 %
User avatar
By @UKVoIPForums
Posts Likes Avatar Topics
#5825
With Asterisk and FreePBX moving closer to the removal of chan_sip I decided to make the switch myself. Below is a copy of my Voipfone PJSIP settings that I configured a few days ago with FreePBX 13.0.197.22 and so far so good. :nerd:

First thing you will need to do is enable the "SIP Channel Driver" to use both chan_sip and chan_pjsip. You can do that by navigating to the Settings > Advanced Settings configuration page and scrolling down until you see the "SIP Channel Driver" setting. Make sure that "both" is selected in the dropdown box. If it isn't, make the change and click "Submit" to save it and then "Apply Changes" to implement it.

Now that's out of the way, let's create a Voipfone PJSIP Trunk...
  1. Navigate to Connectivity > Trunks > + Add Trunk > Add SIP (chan_pjsip) Trunk page.
    You should be at the following screen:
    Image
  2. Under the "General" tab section make the following changes:
    • Trunk Name = Voipfone-(ACCOUNT_NUMBER)
    • Outbound CallerID = (PHONE_NUMBER)
    It should look something like this:
    Image
  3. Click on the "pjsip Settings" tab and in the "General" tab section make the following changes:
    • Username = (ACCOUNT_NUMBER)
    • Secret = (ACCOUNT_PASSWORD)
    • Authentication = Outbound
    • Registration = Send
    • Language Code = English - United Kingdom
    • SIP Server = sip.voipfone.net
    • SIP Server Port = 5060
    • Context = from-pstn
    • Transport = 0.0.0.0-udp
    Again, it should look like this:
    Image
  4. While still in the "pjsip Settings" tab click on the "Advanced" tab and make the following changes:
    • Forbidden Retry Interval = 20
    • Fatal Retry Interval = 20
    • General Retry Interval = 20
    • Expiration = 60
    • Qualify Frequency = 20
    • Contact User = (ACCOUNT_NUMBER)
    • From Domain = (YOUR_IP)
    • From User = (ACCOUNT_NUMBER)
    • Client URI = sip:(ACCOUNT_NUMBER)@sip.voipfone.net:5060
    • Server URI = sip:sip.voipfone.net:5060
    • AOR Contact = sip:(ACCOUNT_NUMBER)@sip.voipfone.net:5060
    • Match (Permit) = sip.voipfone.net
    You can leave the rest at their defaults.
    Image
  5. Finally click on the "Submit" button to save your changes and then "Apply Changes" to implement them.

Additional information on how to convert extensions from chan_sip to chan_pjsip can be read here: WelshPaul @ FREEPBX - New tool to assist converting from SIP to PJSIP


NOTE: Replace the following (in the above configuration) with your real Voipfone credentials:
  1. (ACCOUNT_NUMBER) = Your Voipfone account number (the 8-digit number starting with 3) followed by star and your 3-digit extension number.
  2. (ACCOUNT_PASSWORD) = Your Voipfone extension account password. Passwords for all your extensions can be found in your Control Panel.
  3. (YOUR_IP) = Your IP Address (Find it here: Settings > Asterisk SIP Settings > NAT Settings > External Address)
ostridge liked this
1
0
User avatar
By WelshPaul
Posts Signature Likes Avatar Topics
#5980
Hi @nasarz, PJSIP trunk configuration for a UK Sipgate Basic account can be found here: WelshPaul @ Sipgate Basic PJSIP Trunk Configuration (FreePBX)
0
User avatar
By TonyRogers
Posts Likes Avatar
#6051
Re. Voipfone and PJSIP.

Hi there. Thanks for your detailed howto. I'm a VOIP noob, although we've been running PBX in a flash for several years on a RasPi.

Currently setting up a new FreePBX instance for use with Voipfone, and am struggling with Trunk authentication using PJSIP. SIP works fine, but I was trying to move forwards!

It's *probably* the username bit with the '*extension' appended to it. We do not have any extensions at Voipfone, so am unclear whether this is a show stopper, or we should be using the extensions on our FreePBX instance (these are currently single digits, and am unclear whether this is an issue or not).

Any clues/hints would be welcome.
0
User avatar
By WelshPaul
Posts Signature Likes Avatar Topics
#6052
Hi Tony,

If you do not have any Voipfone extensions then just enter your Voipfone account number (the 8-digit number starting with 3) and ignore the star and your 3-digit extension number.

Still unable to get the trunk to register? Try leaving the "Match (Permit)" field empty! If you still cannot get the trunk to register at this point and you haven't altered any other settings (they should be default) then its something else causing the issue.

To view registration status, navigate to:
Reports > Asterisk Info > Registries

Here is the status of my PJSIP trunks that are configured as above:
Image

Regarding your FreePBX extensions that are configured to use a single digit, use three or four digit extensions.
0
User avatar
By TonyRogers
Posts Likes Avatar
#6057
Cheers. That gives me a bit to go on. Voipfone support emailed me yesterday to say they didn't support PJSIP. *update* they've just had a go, following your instructions with a FreePBX install and say it works! They now want to exchange screen shots!
ostridge liked this
0
User avatar
By WelshPaul
Posts Signature Likes Avatar Topics
#6058
Of course it works! 😆

The reason why I told you to leave the "Match (Permit)" field empty is because entering an incorrect IP address here can prevent a successful registration. Did you try this? If your server still won't register then you need to look at your servers configuration, firewall and NAT settings...
  1. Have you looked at the server logs and if so what do they report?
  2. Is this setup on a Raspberry PI (RasPBX)?
  3. What is SIP Channel Driver configured to use on your server? (Settings > Advanced Settings)
  4. What port is your server using for PJSIP?
If your not using chan_sip then set SIP Channel Driver to use chan_pjsip and set the PJSIP Port to Listen On to use 5060. You must restart Asterisk for port binding changes to take effect:
Code: Select all
fwconsole restart
0
User avatar
By TonyRogers
Posts Likes Avatar
#6062
I'm registered OK now!

Don't shout, but I'm running in a docker container. Seems to work OK.

Just trying to get audio working now. Outbound audio doesn't seem to work, but incoming does. Probably a firewall thing.

SIP channel driver is 'both'.

PJSIP is on 5060.

Many thanks.
0
User avatar
By WelshPaul
Posts Signature Likes Avatar Topics
#6063
While not related, Voipfone use the following codecs:
  • alaw
  • g726
  • ilbc
  • gsm
  • speex
You should configure the trunk as follows:
Image

What are your RTP Port Ranges and have you whitelisted them in your firewall?
Settings > Asterisk Sip Settings > RTP Port Ranges

To test, dial *43 and run an Echo test. If that works, dial 152 and run a Voipfone Echo test.

*43 will test audio between an endpoint (VoIP Phone / Softphone) and your FreePBX server (Endpoint > FreePBX). 152 will test audio between an endpoint and the Voipfone server (Endpoint > FreePBX > Voipfone).
0

Context [from-pstn-e164-uk] proposal https://www.voip…

Thanks for this post. I now have my sipgate uk register…

Mobile Phone Refresh Rates

What you need to know: If you’ve had your tru…

Configuring 3CX with Soho66

Hi I have been trying to configure 3cx with my soho66 …

Sign up for VIP membership