[asterisk-bugs] [Asterisk 0015487]: callerid in Canada does not work for Voicetronix Openswitch12
Asterisk Bug Tracker
noreply at bugs.digium.com
Sun Jul 12 14:35:44 CDT 2009
A NOTE has been added to this issue.
======================================================================
https://issues.asterisk.org/view.php?id=15487
======================================================================
Reported By: rick_in_hfx
Assigned To:
======================================================================
Project: Asterisk
Issue ID: 15487
Category: Channels/General
Reproducibility: always
Severity: major
Priority: normal
Status: new
Asterisk Version: 1.6.0.10
Regression: No
SVN Branch (only for SVN checkouts, not tarball releases): N/A
SVN Revision (number only!):
Request Review:
======================================================================
Date Submitted: 2009-07-10 22:23 CDT
Last Modified: 2009-07-12 14:35 CDT
======================================================================
Summary: callerid in Canada does not work for Voicetronix
Openswitch12
Description:
I have tried product versions from 1.4.25.1 through to current 1.6.2 beta3.
None seem to work to have vpb pick up callerid from PSTN trunk or to pass
along callerid presentation for analogue phones connected on FXS ports.
I have tried all available options for callerid=____ in the
/etc/asterisk/vpb.conf file. I am also using last version of vpb driver
from Voicetronix.
The best I can do without major research is to go with callerid=on and
modify chan_vpb.cc. (see in Additional Information below)
Still, I can't get Asterisk to pass cid from caller to called. On the
plus side, my CID does show in a SIP call. :)
======================================================================
----------------------------------------------------------------------
(0107623) rick_in_hfx (reporter) - 2009-07-12 14:35
https://issues.asterisk.org/view.php?id=15487#c107623
----------------------------------------------------------------------
Problems with chan_vpb.cc in Canada (debug code added):
if ((rc = vpb_cid_decode2(cli_struct, buf, CID_MSECS * 8)) ==
VPB_OK ) {
/*
if (owner->cid.cid_num)
ast_free(owner->cid.cid_num);
owner->cid.cid_num=NULL;
if (owner->cid.cid_name)
ast_free(owner->cid.cid_name);
owner->cid.cid_name=NULL;
*/
/*
I need to find out what is populated
in each field whether it is used or not
*/
ast_log(LOG_ERROR, "DEBUG::CID record - got [%s] [%s]",
cli_struct->cldn, cli_struct->ra_cldn);
ast_log(LOG_ERROR, "DEBUG:: - got [%s] [%s]",
cli_struct->cdn, cli_struct->cn);
if (cli_struct->ra_cldn[0] != '\0') {
/*
owner->cid.cid_num = ast_strdup(cli_struct->cldn);
owner->cid.cid_name = ast_strdup(cli_struct->cn);
*/
/*
In Canada, the Calling number
shows up in Called number field
- Need to populate field used
by the program - 'cldn'
*/
/ strcpy(cli_struct->cldn, cli_struct->cdn);
if (owner) {
ast_set_callerid(owner, cli_struct->cldn,
cli_struct->cn, cli_struct->cldn);
} else {
strcpy(p->cid_num, cli_struct->cldn);
strcpy(p->cid_name, cli_struct->cn);
}
Found out from the display of cli_struct->ra_cldn what now makes sense,
it's value is not NULL, but rather it is '0', as set prior to the call to
vpb_cid_decode2(). The reason is that cli_struct->clid does not contain
anything. If it did, then ra_cldn would be reset to NULL '\0'.
> Using VPB Caller ID
> CID record - start
-- Executing [s at from-pstn:1] Wait("vpb/0-11", "5") in new stack
> CID record - skipped 501ms trailing ring
> CID record - recorded 4021ms between rings
[Jul 11 13:50:27] ERROR[7040]: chan_vpb.cc:688 void
get_callerid(vpb_pvt*): DEBUG::CID record - got [] [O]
[Jul 11 13:50:27] ERROR[7040]: chan_vpb.cc:689 void
get_callerid(vpb_pvt*): DEBUG:: - got [4011099] [RICHARD STONEHO]
> CID record - got [4011099] [RICHARD STONEHO]
callerid.c – func: callerid_feed(). Case 4 refers to /* number */, but
for Bell Canada, that is 'Reason for Absence of Diable Directory Number'
(calling number id). In the case of Canadian received calls, that field
never gets reset from '0'... so callerid_feed does try to process it.
Could this possibly cause the segmentation fault??
/vpb-driver-4.2.41/src/libvpb/vpbapi.h – contains another definiton of
the identifiers for CID..., albeit VPB_CID_CALLING_LINE_DN and
VPB_CID_CALLED_DN are not correct for Canada.
Just to reiterate, this problem affects everything callerid related and
CDR related. All I can do successfully is receive calls and make calls.
Hmmm, sounds like a phone, not a PBX. :(
Now, I do not see where the callerid is presented to the called device....
Looking into that.
Issue History
Date Modified Username Field Change
======================================================================
2009-07-12 14:35 rick_in_hfx Note Added: 0107623
======================================================================
More information about the asterisk-bugs
mailing list