Which digit map takes precedence?

I’m just getting to know digit maps for our phone system and phones (digium and aastra). In the past, if the phone was off-hook and an external number were dialed, it would cut off with the call cannot be completed as dialed message that others on this forum have posted about. It doesn’t seem to do this now since our recent upgrade to asterisk 11.6-cert1. Actually, dialing internal extensions don’t seem to match the [0-8]xx portion of the digit maps to immediately place the call after the third digit.

Anyway, I started looking at digit maps and realized that there are 3 different mappings (phone web ui, phone .conf file, and within FreePBX):

FreePBX 911|9911|[2-8]xx|91xxxxxxxxxx|9xxxxxxx|*80xxx
Phone Web UI [0-8]xx|911|9411|9611|9011xxx.T3|91xxxxxxxxxx|9[2-9]xxxxxx|*xxx.T3
Phone config [0-8]xxxxx|911|9411|9611|9011xxx.T3|91xxxxxxxxxx|9[2-9]xxxxxx|*xx.T3|[0-8]xx.T3

Our digium phones are provisioned almost the same as the Aastras, through the End Point Manager (but I have to move the .conf file to the /var/www/html/digium directory and tell Digiums to “fetch configuration from URL” to provision).

Which digit map in this case would take precedence?!

Any help is greatly appreciated.

Running Asterisk 11.6-cert1 with FreePBX 2.10.1.2

I changed the digit map for my phone to simply this and it dialed the extension immediately after the third digit (after rebooting my phone first, of course):

[0-80xx

It seems the MAC.conf file for my phone takes precedence but perhaps there is a conflict in the patterns that didn’t allow it to match anything before. I’m still tinkering with this but any insight is still greatly welcome!

there is supposed to be a closing bracket symbol at the end of that digit map snippet I just posted…

Configuration hierarchy usually is:
Phone UI
Phone configuration files
FreePBX Settings.

BF

I’ve been messing around with this and it doesn’t seem to do what I thought it would in certain cases. Does match from left to right strictly or will it match anything in the digit map simultaneously?

I had patterns in there for 3 and 4 digit extensions, but it wouldn’t dial after the timeout for the 3 digit pattern:

[1-8]xx.T2|[1-8]xxx|

The same with feature codes:

*xx.T3|*xxx

It seems like it counts the star as one of the digits as well.

Thoughts?

The “*” is litteral. So *xxx would match *123 or *456.

A “.” Is a wildcard.

Does the timer parameter only begin counting after the last digit of a particular pattern is dialed? Or does it count during the entire pattern match?

So if I have 9[2-8]xxxxxxxxx.T3 so that it will catch 7 and 10 digit numbers, will the .T3 start counting right away for this pattern or will it only start counting after the last x digit is dialed?

Also, are the patterns matched one at a time from left to right or all at the same time? In other words, if the dialed digits match the first pattern and possibly another one farther right in the digit map, will it only pay attention to the first match until, of course, digits are dialed that make it no longer match the first pattern?

The timer begins when each digit is dialed. So if there’s a delay of 4-5 seconds between dialing digits, the system will assume you’ve finished dialing and try to dial what you’re already entered.

BF

Thanks for the info! I’m having trouble with this pattern:
9[2-9]xxxxxxxxx.T3

I dial 95705556666 (not a real number) and it dials after a few seconds as expected. However, if I dial 95556666 (no area code) it doesn’t ever dial until I dial more digits.
This pattern should cover 9+seven digit and 9+ten digit external numbers but it doesn’t seem to dial after the timeout for 9+seven digit numbers.

Thoughts?

I was mainly speaking of the FreePbx dialing sequence. Each phone is slightly different.

BF

Again, I think I figured this out from something I found online. The patterns match anything that can be matched in the digit map, not strictly from left to right. Correct me if I’m wrong though. I’m always open for corrections!