Sunday, September 29, 2013

Custom Caller ID Names with Google Voice, OBi202, OpenCNAM and YATE (part 2 of 3)

In this series: Part 1 | Part 2 | Part 3

If you are not already aware, Google will be making changes in May, 2014 that will break compatibility with Obi devices and Google Voice. Some or all of this document may not be applicable after that time. (http://blog.obihai.com/2013/10/important-message-about-google-voice.html)


Update 9/11/2014 - Obi + Google Voice now supported again!

In Part 1 of this series, we installed and configured a YATE server on a Linux server. To continue the setup, we will now configure the OBi202 to forward all calls destined for your Google Voice number on to the YATE server.

This procedure is very similar to the first part of this excellent blog post which describes the analogous setup for an Asterisk server. If you are not that familiar with the OBi202 configuration system, you may find that blog helpful since there are screen captures there.


OBi202 Prerequisites

  1. Your OBi202 should be configured for "expert" setup mode. This means that you know the username, password, and URL to access your OBi202 directly (not going through obitalk.com). If you don't know how to do this, look at this blog post for instructions to set that up.
  2. You need one unused service provider and one unused voice services provider slot.

Service Provider Configuration for YATE

As previously noted, this configuration is accomplished in "expert configuration mode." You have to be logged in to the configuration interface of your OBi202.

To get started, locate an unused service provider slot under "Service Providers." I chose ITSP Profile D on my system.

In the General section, check the "Default" box for all items EXCEPT the following, which you should set to the values shown. When finished, click "Submit." (Don't reboot your OBi yet.)
  • SignalingProtocol = SIP
  • X_UseFixedDurationRFC2833DTMF = Checked
In the SIP section, check the "Default" box for all items EXCEPT the following, which you should set to the values shown. When finished, click "Submit." (Don't reboot your OBi yet.)
  • ProxyServer = IP Address of your YATE Server
  • ProxyServerPort = 5060
  • OutboundProxy = (leave this blank)
  • OutboundProxyPort = 5060
  • X_SpoofCallerID = Checked
  • X_AccessList = IP Address of your YATE Server
In the RTP section, check the "Default" box for all items. When finished, click "Submit." (Don't reboot your OBi yet.)

Voice Services Configuration for YATE

As previously noted, this configuration is accomplished in "expert configuration mode."

To get started, locate an unused service provider slot under "Voice Services." I chose SP4 Service on my system.

In this configuration section, check the "Default" box for all items EXCEPT the following, which you should set to the values shown. When finished, click "Submit." (Don't reboot your OBi yet.)

  • X_ServProvProfile = A, B, C, or D to match the service provider used in the previous section
  • X_RingProfile = A
  • AuthUserName = Username you put in /etc/yate/regfile.conf in Part 1 of this blog post
  • AuthPassword = Password you put in /etc/yate/regfile.conf in Part 1 of this blog post

Voice Services Configuration for Google Voice

You already have your Google Voice configured, but there is one tweak that you need to make to the configuration to forward your Google Voice calls to YATE.

Locate the SP# entry for your Google Voice account under "Voice Services." You can easily determine which one it is, because your Google Voice login name (e-mail address) will be visible in the AuthUserName field.

Take note of the existing setting for the X_InboundCallRoute field. If things go wrong, you'll need to restore this setting. It's likely set to "ph,ph2" or just the default.

Now, we make the change to forward incoming Google Voice calls to your YATE server. Uncheck the "default" box if necessary, and change the X_InboundCallRoute field as per the following examples:

Example 1
---------
Voice Services configuration chosen for YATE - SP4
Your Google Voice number - 2025551212 (10 digit, area code + number, no punctuation)
IP Address of your YATE server - 192.168.1.1
Username in /etc/yate/regfile.conf - obi202user
Password in /etc/yate/regfile.conf - obi202password

Set X_InboundCallRoute to:

sp4(2025551212/$1@192.168.1.1;ui=obi202user:obi202password)

Example 2
---------
Voice Services configuration chosen for YATE - SP2
Your Google Voice number - 3125551234 (10 digit, area code + number, no punctuation)
IP Address of your YATE server - 10.0.0.1
Username in /etc/yate/regfile.conf - john
Password in /etc/yate/regfile.conf - secret

Set X_InboundCallRoute to:

sp2(3125551234/$1@10.0.0.1;ui=john:secret)

When you've got that set, click the Submit button.

Reboot the OBi202

To apply the configuration changes made in the previous sections, you need to reboot the OBi202 device. Click the "Reboot" button in the upper right, and follow the prompts. The device takes approximately 15-30 seconds to reboot.

Test Everything

Use your cell phone (or any other phone that doesn't go through your OBi) to place a call to your Google Voice number. At this point we are just hoping that the call goes through and causes the phones connected to the OBi202 to ring. You could look at /var/yate/yate.log on the YATE server to see if any entries are recorded in the log -- there should be at least one entry per call.

If it doesn't work and you can't seem to get it fixed, you can roll back by restoring the X_InboundCallRoute field for your Google Voice service to its original value (or the default). Submit the change and reboot your OBi202 to put the setting back into effect.

Summary

What did we just accomplish?

We configured the OBi202 to route incoming calls destined to your Google Voice number to your YATE server. In Part 1, we configured your YATE server to route those calls right back to the device that called. So we've just created a loop

In and of itself, this configuration is pointless, and we haven't even fixed the missing caller ID names. So don't stop here! In Part 3, we will add additional processing on the YATE side, which in this particular case is manipulating the Caller ID data.

No comments:

Post a Comment