News:

On Tuesday September 6th the forum will be down for maintenance from 9:30 PM to 11:59 PM PDT

Main Menu

Need more help in Digimap

Started by jtan, May 24, 2015, 01:40:25 PM

Previous topic - Next topic

jtan

First of all, many thanks to the people in this forum who have helped me.    


The following are area code of Canada

(236|250|778|403|587|780|825|306|639|204|431|416|437|647|807|249|705|226|519|548|289
|365|905|343|613|418|581|450|579|438|514|819|873|709|506|782|902|867)

http://www.allareacodes.com/canadian_area_codes.htm

How can I code it so that
SP1 FPL (FreePhoneLine)  for all canadian and toll free number
SP2 GV  (Google Voice) for all canadian and toll free numbers that SP1 failed + USA numbers
without dialing **2 ?    

Dialing any 7 digit number OBi will insert 604 area code

I preferred to set FPL as Phone1 since it has local area code number.

Thank you

========================================

Using OBi200
My Local area code 604
*97 FPL voicemail
*98 GV voicemail

Ban - prevent scanner
Ban2 - block list of phone numbers ... forward them to msg the number you dialed is not in service.


References
https://www.obitalk.com/forum/index.php?topic=9107.msg64223%20-%20msg64223

https://www.obitalk.com/forum/index.php?topic=8381.msg55901#msg55901

http://www.obitalk.com/forum/index.php?topic=5467.0


========================================

Router Configuration -- WAN Setting -- Local DNS Records
freephoneline.ca={voip.freephoneline.ca|1}|{voip2.freephoneline.ca|2}|{voip4.freephoneline.ca:6060|3}


Service Provider -- ITSP Profile A General -- Name             
FreePhoneLine
Service Provider -- ITSP Profile A General -- DigitMap           
(*98|<1604>[2-9]xx xxxx|1xxx xxx xxxx |<1>[2-9]xx xxx xxxx)

Service Provider -- ITSP Profile A Sip -- ProxyServer
freephoneline.ca
Service Provider -- ITSP Profile A Sip -- RegistrationPeriod
3600
Service Provider -- ITSP Profile A Sip -- RegisterRetryInterval
120
Service Provider -- ITSP Profile A Sip -- X_ProxyServerRedundancy
check

Service Provider -- ITSP Profile B General -- Name
Google Voice
Service Provider -- ITSP Profile B General -- DigitMap           
(<1604>[2-9]xx xxxx|1xxx xxx xxxx |<1>[2-9]xx xxx xxxx)


Voice Service -- SP1 Service -- X_InboundCallRoute
{(MBan2):sp1(9991234567@sip.tropo.com)}|{(MBan):}|{>1604 123 4567:ph}|{(x.604 111 2222):aa}
Voice Service -- SP1 Service --  X_KeepAliveEnable       
check   
Voice Service -- SP1 Service --  X_KeepAliveExpires       
20

Voice Service -- SP2 Service -- X_InboundCallRoute
{(x.604 111 2222):aa}|{ph}


Physical Interfaces  -- Phone1 -- DigitMap          
(<*97:**2320 333 4444>|[1-9]x?*(Mpli)|[1-9]S9|[1-9][0-9]S9|**0|***|#|##|222222222|**1(Msp1)|**2(Msp2)|**3(Msp3)|**4(Msp4)|**9(Mpp)|(Mpli))

Physical Interfaces  -- Phone1 -- OutboundCallRoute       
{([1-9]x?*(Mpli)):pp}}|{(<##:>):li}|{**0:aa}|{***:aa2}|{222222222:pp}|{(<**1:>(Msp1)):sp1}|{(<**2:>(Msp2)):sp2}|{(<**3:>(Msp3)):sp3}|{(<**4:>(Msp4)):sp4}|{(<**9:>(Mpp)):pp}|{(Mpli):pli}


Star Codes  Profile A & B  -- Code28         
*95| Blind Transfer| coll($Bxrn)


User Settings -- User Defined Digit Map2 --Label             
Ban
User Settings -- User Defined Digit Map2 --DigitMap       
(?|x|xx|xxx|xxxx|xxxxx|xxxxxx|un@@.|Un@@.|anon@@.|Anon@@.|1?1234567890|1?0987654321)

User Settings -- User Defined Digit Map3 --Label       
Ban2
User Settings -- User Defined Digit Map3 --DigitMap
(604111 1111|800222 2222|1778 333 3333)

azrobert

#1
ITSP A DigitMap:
(*98|<1604>[2-9]xxxxxx|1(236|250|778|403|587|780|825|306|639|204|431|416|437|647|807|249|705|226|519|548|289|365|905|343|613|418|581|450|579|438|514|819|873|709|506|782|902|867)xxxxxxx)

Physical Interfaces  -- Phone1 -- DigitMap          
(1xxxxxxxxxx|<1>[2-9]xxxxxxxxx|<*97:**2320 333 4444>|[1-9]x?*(Mpli)|[1-9]S9|[1-9][0-9]S9|**0|***|#|##|222222222|**1(Msp1)|**2(Msp2)|**3(Msp3)|**4(Msp4)|**9(Mpp)|(Mpli))

Physical Interfaces  -- Phone1 -- OutboundCallRoute      
{([1-9]x?*(Mpli)):pp},{(<##:>):li},{**0:aa},{***:aa2},{222222222:pp},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mpli):pli},{(Msp2):sp2}

Edit:
You had vertical bars separating the OuboundCallRoute rules, I changed them to commas.


jtan

#2
Thank you azrobert however,

somehow when I dialed a local number such as
664-9010 or 604-664-9010 or 1-604-664-9010 they go to sp2

Also all toll free number just go to sp2, it did not try sp1 first.
Should I add |18(00|88|77|66|55|44)xxxxxxx|  to ITSP Profile A -> DigitMap:


azrobert

Add 604 to the list of Canadian area codes.
Add the tollfree numbers like you asked to ITSP A DigitMap.

jtan

Quote from: azrobert on May 24, 2015, 05:44:37 PM
Add 604 to the list of Canadian area codes.
Add the tollfree numbers like you asked to ITSP A DigitMap.

Thanks got it  ;D

(*98|<1604>[2-9]xxxxxx|1(604|236|250|778|403|587|780|825|306|639|204|431|416|437|647|807|249|705|226|519|548|289|365|905|343|613|418|581|450|579|438|514|819|873|709|506|782|902)xxxxxxx |18(00|88|77|66|55|44)xxxxxxx)

jtan

#5
I dialed 800-213-8378 somehow I got 404 not found why doesn't it also try to call on sp2 (GV) automatically when sp1 (FPL) failed.


When I dialed **2 800-213-8378 the call went through.

Please advice and thanks

azrobert

Maybe that 800 number is not reachable from Canada. Are you using a trunk group for failover?  Not all failures will failover. Maybe this is one of them.

jtan

#7
The 800-213-8378 does not accept any call dialing from a Canadian phone number.
I use the wrong term "failover" sp1 (FPL) system is not down.

Is there a way to code Obi200 so that it automatically use sp2 (GV) to dial that 800 number
when sp1 is rejected with 404 msg ?

Regarding failover settings, is this the correct way ?

Voice Service -- Gateway & Trunk Grps -- Trunk Group1 -- TrunkList
pp,sp1,sp2

Voice Service -- SP1 Service -- X_NoRegNoCall
check

Voice Service -- SP2 Service -- X_NoRegNoCall
check

Physical Interfaces  -- Phone1 -- OutboundCallRoute      
{([1-9]x?*(Mpli)):pp},{(<##:>):li},{**0:aa},{***:aa2},{222222222:pp},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mpli):pli},{(Msp2):sp2},{(Mtg1):tg1}



Reference

https://www.obitalk.com/forum/index.php?topic=9107.msg64223#msg64223

http://www.obitalk.com/forum/index.php?topic=9327.msg61861#msg61861


Thank you Robert once again for you patience and guidance.

azrobert

#8
The old rules must be removed.
You have 2 options.

{([1-9]x?*(Mpli)):pp},{(<##:>):li},{**0:aa},{***:aa2},{222222222:pp},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mtg1):tg1}

OR

{([1-9]x?*(Mpli)):pp},{(<##:>):li},{**0:aa},{***:aa2},{222222222:pp},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mpli):pli}

Physical Interfaces -> Phone1 Port -> PrimaryLine: Trunk Group 1
_________________________________

Here is an option if failover doesn't work.
Some tollfree numbers don't work with GV, so I use a free tollfree service.
Here is a list of some tollfree providers:
tf.callwithus.com
tf.arctele.com
tf.callwithus.com
sip.tollfreegateway.com
tollfree.alcazarnetworks.com

I mainly use tf.callwithus.com
I don't know if these will work with Canadian tollfree numbers.
To test, setup a Speed Dial like:
sp1(18005551212@provider.com;ui=2223334444)

Change 18005551212 to a Canadian tollfree number.
Change provider.com to one of the above providers.
Change 2223334444 to the CallerID you want the receiving party to see.

If the Speed Dial works calling a Canadian number, we can setup a Voice Gateway with the provider and route tollfree numbers to it by adding the VG to the beginning of your Trunk Group.

Edit:
I think CallWithUs is located in Canada, so it should work.

azrobert

#9
This is the setup:

Service Providers -> Voice Gateways -> Voice Gateway#1
Name: CallWithUs
AccessNumber: sp1(tf.callwithus.com)
DigitMap: (18(00|88|77|66|55|44)xxxxxxx)
AuthUserID: 2223334444

Voice Service -> Gateway & Trunk Grps -> Trunk Group1 -> TrunkList
pp,vg1,sp1,sp2

Change 222333444 to your CallerID.

azrobert

#10
You also need this:
Voice Service -> Gateway & Trunk Grps -> Trunk Group1 -> DigitMap:
((Mpp)|(Msp1)|(Msp2))

OzarkEdge

Quote from: azrobert on May 25, 2015, 09:39:49 PM
This is the setup:

Service Providers -> Voice Gateways -> Voice Gateway#1
Name: CallWithUs
AccessNumber: sp1(tf.callwithus.com)
DigitMap: (18(00|88|77|66|55|44)xxxxxxx)
AuthUserID: 2223334444

Voice Service -> Gateway & Trunk Grps -> Trunk Group1 -> TrunkList
pp,vg1,sp1,sp2

Change 222333444 to your CallerID.


This also works with CWU in lieu of setting AuthUserID:

Gateways and Trunk Groups - Voice Gateway1::AccessNumber = sp1(tf.callwithus.com;ui=callerID number)

And, you may need to add (Mvg1) to (Mtg1):

TG1 (Mtg1) = (...|(Mvg1)|...)

OE

azrobert

#12
Quote from: OzarkEdge on May 26, 2015, 01:02:08 PM
And, you may need to add (Mvg1) to (Mtg1):

TG1 (Mtg1) = (...|(Mvg1)|...)

(Msp2) has rule "1xxxxxxxxxx", so (Mvg1) is not needed in (Mtg1). It wouldn't hurt to include (Mvg1), but it would be redundant.

OzarkEdge

#13
Quote from: azrobert on May 26, 2015, 01:41:04 PM
Quote from: OzarkEdge on May 26, 2015, 01:02:08 PM
And, you may need to add (Mvg1) to (Mtg1):

TG1 (Mtg1) = (...|(Mvg1)|...)

(Msp2) has rule "1xxxxxxxxxx", so (Mvg1) is not needed in (Mtg1). It wouldn't hurt to include (Mvg1), but it would be redundant.

Understood.  I said 'may' because I wasn't going to check the whole dial plan.

I suggest that redundancy is perfectly acceptable/desirable if both trunks are to permit the same digits dialed.  I suggest that a trunk's digit map should be complete.  Then when you go to use it in the dial plan, it enables its trunk as it should without having to rely on rules spread around elsewhere that may or may not be in play... much easier to keep it simple and redundant, and to use user-defined digit maps to easily share the redundant rules.

I believe VG1 will ultimately not be used unless (Mvg1) permits the digits dialed.

OE

jtan

#14
Like to thank Robert and OE for you suggestions and ideas.   It took me a while to experiment these toll free number that will not accept calling from FPL.

1-800-213-8378 (USA only)
1-800-444-4444 MCI (USA only)

Using the trunk method :

Voice Service -- SP1 Service -- X_NoRegNoCall
check

Voice Service -- SP2 Service -- X_NoRegNoCall
check

Service Providers -> Voice Gateways -> Voice Gateway#1
Name:                         CallWithUs
AccessNumber:            sp1(tf.callwithus.com)
DigitMap:                     (18(00|88|77|66|55|44)xxxxxxx)
AuthUserID:                 320 123 4567

Voice Service -- Gateway & Trunk Grps -- Trunk Group1 -- TrunkList
pp,vg1,sp1,sp2

Voice Service -> Gateway & Trunk Grps -> Trunk Group1 -> DigitMap:
((Mpp)|(Msp1)|(Msp2))


Physical Interfaces  -- Phone1 -- OutboundCallRoute      
{([1-9]x?*(Mpli)):pp},{(<##:>):li},{**0:aa},{***:aa2},{222222222:pp},{(<**1:>(Msp1)):sp1},{(<**2:>(Msp2)):sp2},{(<**3:>(Msp3)):sp3},{(<**4:>(Msp4)):sp4},{(<**9:>(Mpp)):pp},{(Mtg1):tg1}


Reference

https://www.obitalk.com/forum/index.php?topic=8208.0

azrobert

I just looked at your reference and it's one of my posts I did about a year ago.
I only got one reply.
I love trunk groups, but I guess most people couldn't care less.
Thanks for the advertising.

jtan

@Robert

Most of my references are from your posting  ;D

They are well written and provide great insight / ideas in coding.

Many thanks to your contributions to this community.


gsmlnx

@azrobert

I used your trunk post and mrjoe's to set-up my own trunk based mapping.

I have used it to provide for redundancy for normal calls and emergency calls too (based in the UK so a no cost option unlike the USA). I also used user defined digit maps (UDDM) to store the various digit maps so the ITSP digit maps are cleaner (to my eyes) and just contain mostly a list of UDDM's. Just having ten UDDM's is a bit mean in my eyes.

Also UDDM just have to be changed in one place not across multiple ITSP's for when I have a change of heart or the call costs change between providers.

OzarkEdge

Quote from: azrobert on May 26, 2015, 09:38:47 PM
I love trunk groups, but I guess most people couldn't care less.

I care!  :)  Trunk groups are very useful.

OP:  If you want to bend your brain some more, check out the OBi202 dial plan in my notes.  Also, maybe FPL can fix their routing for those two numbers... instead of you having to dial plan a solution?

OE

jtan

#19
@OzarkEdge

Wow ... lot of good stuff and ideas to read  ;)

Thank you.


Reference

http://ozarkedge.com/