Step 1: Connecting to Ma Bell
FXO - to the phone company.
FXS - to user.
Most telephones have an fxo interface built in. If you are going to set up a computer based pbx system, then you will need to get a special interface to do so. Most modems are not equipped to do this. Either you have to get a special internal card or some kind of usb
Step 2: Directory Assistance.
NOTE: In the following document it is suggested to use the 1-800-FREE411 service. However, before doing that you may wish to read this message (including the reply comments) to avoid getting hit with unwanted text messages on your cell phone. This is particularly true if you permit calls into your FreePBX system from outside lines that could then be redirected to one of the free directory assistance services.
This makes use of the free 1-800-FREE411™ and/or 1-800-411-SAVE services, so that all Directory Assistance calls are free (I note that Google has now started up a service at 1-800-GOOG-411 but it is only for U.S. business listings). Here are three easy ways to set this up in FreePBX - just pick the one you prefer (I'd recommend the third method for the greatest flexibility, but it's up to you). Note that all of these methods assume you already have a route and trunk that will complete toll-free calls in the USA - if you don't (or if your provider charges you for them), just set up an ENUM trunk (if you haven't already done so), and then create an Outbound Route that catches calls matching the toll-free number patterns (e.g. 1800NXXXXXX, 1888NXXXXXX, 1877NXXXXXX, 1866NXXXXXX, etc.) and specify the ENUM trunk as the top choice (or only choice) for completing those calls. Then make that "toll free" route higher in priority than the route that handles your regular USA traffic.
Method #1 (the newer way):
This will only let you use ONE of the above services. If you want to be able to fall through to the other service when your primary choice is unreachable, then use Method #2 below, or if you want to be able to pick which service you use on each call, then use Method #3. This method simply creates the equivalent of one or more speed-dials to the service of your choice
Create a Misc Destination.
- Give it a description, such as "Directory Assistance".
- Put the number of the service you wish to use (such as 18003733411) in the dial: text field.
- Don't forget to click "Submit Changes".
Create a Misc Application.
- Give it a description, such as "Directory Assistance".
Put the number you want to use in the Feature Code: text field. Typical choices are:
- _1NXX5551212 (Note the initial underscore)
- _NXX5551212 (Note the initial underscore)
- Make the Destination the Misc Destination that you created in the first step.
- Don't forget to click "Submit Changes".
- If you wish to match all of the above-mentioned patterns, you can create as many additional Misc Applications as you need, however you should also consider using Method #2.
Method #2 (the old way, but possibly better than the first method):
Not only will this allow you to possibly fall through to another service if your first choice is unreachable, but it's also a bit easier if you're matching many patterns. Also you can place it in the correct priority order among your routes, which is not possible with Method #1 (see the notes below). The only downside is that the method used here is a bit less obvious in its workings.
Create the Trunk(s)
Create a new CUSTOM Trunk. Previously we had said that the ONLY thing you need to fill in for this trunk is the Custom Dial String, which will be in the form:
Where the number-to-call will be 18003733411 or 18004117283, so the Custom Dial String would simply look like one of these (better yet, you could create two custom trunks so you have have access to both, in case one is down):
Bear in mind that you must have an outbound route that will pass 1-800 number calls, otherwise this won't work.
We now also suggest that you may want to add the following, if you wish to avoid sending Caller ID information from an external source to any of these services (see the note at the top of this page for a reason you might want to do that, and note this does NOT inhibit the sending of Caller ID from an internal extension):
Outbound Caller ID: hidden
Note that the word "hidden" above is a "magic string" that is used to hide the CallerID sent out over Digital lines ONLY (E1/T1/J1/BRI/SIP/IAX). You could also use any landline or VoIP DID number that you own, as long as it doesn't have text messaging service associated with it, isn't a FAX line, etc. The main idea here is to avoid the possibility of passing a cell phone number to these services. You need only do this with services you don't trust to not send you unwanted text messages. Note again that this does NOT override the CallerID on calls from internal extensions!!!
Create The Route
1) Name the route whatever you like, for example, "411" or "DirectoryAssistance"
2) In the Dial Patterns put the following lines:
If there are any other local variations that normally work for calling Directory Assistance (such as 1411), you may wish to include those also.
3) Select the trunk(s) you just created. It/they will show as the name whatever you put in the Custom Dial String, for example:
4) Save the new route and then, when it appears in the list of routes, use the arrows to move it to a position higher than the routes you normally use for outgoing PSTN calls. This route must have a higher priority than any other route where the pattern could match. For example, if someone dials 1-212-555-1212, you want the call to hit this route before any other routes to the 212 area code.
First, be aware that if this route is higher in priority than routes that handle calls to toll-free numbers, it will intercept calls to 1-800-555-1212. If that's not desirable behavior, make sure your route that handles North American toll-free calls is higher in priority than this route.
Second, please be aware that ANY calls to 1NXX5551212 will be picked off by this route, which means it will also intercept calls intended for Directory Assistance in Canada and/or the Caribbean (those portions that use the country code "1"). If that's not desirable, you may need to specify each valid USA area code individually, e.g. 12125551212, 12135551212, etc.
Method #3 (the most versatile method):
This method is slightly more complicated to initially set up, but it gives your users the option of going to the free directory assistance service of their choice, while still blocking them from going to the expen$ive telephone company service. It was inspired in part by a thread in the Elastix "Tips and Tricks" forum (Adding mulitple Free dir asst. in your dialplan).
Create the Destinations
Go to Misc Destinations and add the following three destinations:
Create a Recording
Use the System Recordings module to create or upload a recording. Here is a suggested script for the recording:
"Free Directory Assistance! To use 800 411 SAVE, press 1. To use 1 800 FREE 411, press 2. If you want a business listing and wish to use Google's 411 service, press 3. Or stay on the line to be connected to 800 411 SAVE"
(We suggest using 800-411-SAVE as the default because they use live operators. If you're having trouble getting touch tones through, that's the one you want.)
Create an IVR
Go to the IVR module and Add IVR. Here are the suggested settings:
Change name to Directory Assistance
Change timeout to 3 (optional)
Uncheck "Enable Directory"
Uncheck "Enable Direct Dial"
Check "Loop Before t-dest"
Check "Loop Before i-dest"
Change Repeat Loops to 1
For the Announcement, pick the System Recording you created in the previous step.
For the first three options, pick the three Misc Destinations you created, in the same order they are mentioned in the announcement. Be sure to type the number coresponding to the menu option in the text box. Do NOT check "Return to IVR" for any of these. Then click on "Increase Options"
For the final option, type t in the text box and select the default Misc Destination (800-411-SAVE if you used the script above). Once again do NOT check "Return to IVR"
Click on SAVE. Check to make sure that all four options are there and entered correctly after the page reloads, then click the "Apply Configuration changes" bar (this is necessary for the next step).
Determine the new IVR context name - OR - create a Misc Application
At this point you can do either of two things. If you want to get a bit down and dirty with the system, then use a text viewer or editor to look at etc/asterisk/extensions_additional.conf. You need to find the context name for the IVR you just created. It will be in the form [ivr-x] where x is a number, such as [ivr-5]. So search for "[ivr-" (without the quotes) and for each one that comes up, look to see if it appears to be the correct one. It will probably be the highest numbered one (since you just created it) and also it will contain a line that looks like this...
exten => s,n,Background(custom/sound_file)
...where "sound_file" is the name of the file you created or uploaded when you made the System Recording. Make a note of the context name (just the part within the square brackets). You can close the text editor or viewer now (do not make any changes to the file!).
Alternately, you can create a new Misc Application. If you do that, set it up as follows:
Description: Directory Assistance
Feature Code: 411
Feature Status: Enabled
Destination: (The IVR you created in the previous step:) Directory Assistance
Create a Custom Trunk
Create a new CUSTOM Trunk. Fill in the following:
Outbound Caller ID: hidden (optional, see discussion under Method #2 above)
Custom Dial String:
If you did NOT create a Misc. Application in the previous step: Local/s@ivr-x (Replace the x with the correct number from your IVR context as determined in the previous step).
If you DID create the Misc. Application in the previous step: Local/411@from-internal
Click on Submit Changes.
Create an Outbound Route
Go up to Method #2 above and find the section headed "Create The Route" and follow the instructions for that step - for the trunk, pick the Custom Trunk you created in the step above. Don't forget to "Apply Configuration changes" when you are all through. Be sure to read the notes after that section also, they are equally applicable to this method.
Step 3: Analog to IP Interface Gadgets.
Step 4: Softphones
- 3CX VoIP Client (Windows)
- X-Lite (Windows or Mac)
- Zoiper 2.0 (Windows, Mac, Linux)
- FWD.Communicator (Windows)
- iaxComm (Windows, Mac, Linux)
Skype - http://www.skype.com/intl/en-us/home (rumor has it that Microsoft may purchase this product.)
Various other free clients