Star code variables
RevKev:
First off, thanks to RonR and many others for their support in these forums. I've been reading through a number of topics and learned far more here than from the admin guide.
I'm trying to create a star code script that inserts a variable number into a call string.
Specifically, a company I do business with has all of their DIDs use their extension number, By that I mean that extension 1288 has a DID of 212-555-1288. Also, all of their extensions start with 12 (it's a small company).
So I want a star code - *12 - with which I can dial the last 2 digits and have the full DID dialed.
I tried this:
*12xx, dial company, call(**1121255512$code)
and several variations.
I expect $code to be the last 2 digits I dial after *12.
As in the predefined *75 -- *75(x|xx), Check Speed Dial, say($Spd[$Code])
With that failing, I thought maybe setting and using a speed dial might work:
*12xx, dial company, set($spd[99],**1121255512$code),call($spd[99])
In either case, when I dial *1288, I get "the number you dialed was rejected by the service provider".
One variation I tried -
*12xx, dial company, call(**1121255512($code))
produces a busy signal.
Any ideas on how this might work? I suspect that $code is not getting replaced as I thought it would.
RonR:
It appears the Star Code processor in the OBi isn't as flexible as we might like.
*99(xx), Test, say(123) Announces "The value is 123" when *9988 is dialed.
*99(xx), Test, say($Code) Announces "The value is 88" when *9988 is dialed.
*99(xx), Test, say($Code123) gets a busy when *9988 is dialed.
*99(xx), Test, say(123$Code) crashes the OBi when *9988 is dialed.
It looks like a token can be a literal OR a variable, but not a combination of both.
*99(xx), Test, say($Code$Code) also gets a busy when *9988 is dialed.
So it looks like stuffing a couple of variables with the pieces and using multiple tokens won't work either.
Stewart:
Quote from: RevKev on November 27, 2011, 06:53:38 pm
So I want a star code - *12 - with which I can dial the last 2 digits and have the full DID dialed.
It seems that this shouldn't require star codes at all -- just have the digit map translate *12xx to **1121255512xx .
I'm not an expert at this, but wouldn't something like <*12:**1121255512>xx work?
RevKev:
RonR - Thanks for your testing. Using say() is a good way to try this out. I also later thought to check the call log and I can see that obi dials (literally) "121255512$code". So it obviously doesn't do variable replacement within a string.
Stewart - Your idea works. What I don't like is that it makes my digit map that much longer. I added "<*12:**1121255512>xx" at the end of Phone:DigitMap (before "(Mpli)") and it works fine. I then tried adding it to a user defined digit map - ext - and referencing that as "(Mext)" in Phone:DigitMap - that didn't work. As soon as I dialed "*12" I got another dial tone.
Obihai -
Please consider enhancing the star code variable replacement to allow replacement within a string. This, I think, adds valuable functionality.
RonR:
RevKev,
Assuming SP1/ITSP A is your PrimaryLine, you should be adding:
Service Providers -> ITSP Profile A -> General -> DigitMap: (<*12:121255512>xx|...)
Dialing *1212 will send 12125551212 out SP1.
Navigation
[0] Message Index
[#] Next page