Open ROBERT-MCDOWELL opened 12 months ago
This also present in 1.10.9, as a temporary solution used the following (hope not mistaken with additional args in v18_init())
--- mod_spandsp_dsp.c 2023-02-03 20:07:30.000000000 +0000
+++ mod_spandsp_dsp.c.fixes 2023-07-13 08:47:35.332074299 +0000
@@ -156,13 +156,13 @@
{
switch_channel_t *channel = switch_core_session_get_channel(session);
const char *var;
- int r = V18_MODE_5BIT_4545;
+ int r = V18_MODE_WEITBRECHT_5BIT_4545;
if ((var = switch_channel_get_variable(channel, "v18_mode"))) {
if (!strcasecmp(var, "5BIT_45") || !strcasecmp(var, "baudot")) {
- r = V18_MODE_5BIT_4545;
+ r = V18_MODE_WEITBRECHT_5BIT_4545;
} else if (!strcasecmp(var, "5BIT_50")) {
- r = V18_MODE_5BIT_50;
+ r = V18_MODE_WEITBRECHT_5BIT_4545;
} else if (!strcasecmp(var, "DTMF")) {
r = V18_MODE_DTMF;
} else if (!strcasecmp(var, "EDT")) {
@@ -213,7 +213,7 @@
return SWITCH_STATUS_FALSE;
}
- tdd_state = v18_init(NULL, TRUE, get_v18_mode(session), V18_AUTOMODING_GLOBAL, put_text_msg, NULL);
+ tdd_state = v18_init(NULL, TRUE, get_v18_mode(session), V18_AUTOMODING_GLOBAL, put_text_msg, NULL, NULL, NULL);
v18_put(tdd_state, text, -1);
@@ -260,7 +260,7 @@
}
pvt->session = session;
- pvt->tdd_state = v18_init(NULL, TRUE, get_v18_mode(session), V18_AUTOMODING_GLOBAL, put_text_msg, NULL);
+ pvt->tdd_state = v18_init(NULL, TRUE, get_v18_mode(session), V18_AUTOMODING_GLOBAL, put_text_msg, NULL, NULL, NULL);
pvt->head_lead = TDD_LEAD;
v18_put(pvt->tdd_state, text, -1);
@@ -338,7 +338,7 @@
}
pvt->session = session;
- pvt->tdd_state = v18_init(NULL, FALSE, get_v18_mode(session), V18_AUTOMODING_GLOBAL, put_text_msg, pvt);
+ pvt->tdd_state = v18_init(NULL, FALSE, get_v18_mode(session), V18_AUTOMODING_GLOBAL, put_text_msg, pvt, NULL, NULL);
if ((status = switch_core_media_bug_add(session, "spandsp_tdd_decode", NULL,
tdd_decode_callback, pvt, 0, SMBF_READ_REPLACE | SMBF_NO_PAUSE, &bug)) != SWITCH_STATUS_SUCCESS) {
works! many thanks!
you are welcome
This commit broke compatibllity between libspandsp
and mod_spandsp
. mod_spandsp
must be updated to use new defines introduced in that commit.
As a workaround reset spandsp to something preceding that commit, e.g.:
git reset --hard 67d2455efe02e7ff0d897f3fd5636fed4d54549e
Reconfigure, compile, reinstall spandsp.
@piotrgregor solution works nicely. It was a headache to debug this, thank you.
This commit broke compatibllity between
libspandsp
andmod_spandsp
.mod_spandsp
must be updated to use new defines introduced in that commit. As a workaround reset spandsp to something preceding that commit, e.g.:git reset --hard 67d2455efe02e7ff0d897f3fd5636fed4d54549e
Reconfigure, compile, reinstall spandsp.
thanks dear it's worked
This commit broke compatibllity between
libspandsp
andmod_spandsp
.mod_spandsp
must be updated to use new defines introduced in that commit. As a workaround reset spandsp to something preceding that commit, e.g.:git reset --hard 67d2455efe02e7ff0d897f3fd5636fed4d54549e
Reconfigure, compile, reinstall spandsp.
Thanks so much. It works on my lab.
Hi, wonder if there is a fix coming for this issue. I've got same issue on Debian Bookworm, and had to follow the above "git reset" workaround to make it work. Thanks.
Describe the bug make .... make[4]: Entering directory '/home/src/freeswitch/src/mod/applications/mod_spandsp' CC mod_spandsp_la-mod_spandsp.lo CC mod_spandsp_la-udptl.lo CC mod_spandsp_la-mod_spandsp_fax.lo CC mod_spandsp_la-mod_spandsp_dsp.lo mod_spandsp_dsp.c: In function 'get_v18_mode': mod_spandsp_dsp.c:159:17: error: 'V18_MODE_5BIT_4545' undeclared (first use in this function) 159 | int r = V18_MODE_5BIT_4545; | ^
~~~~~ mod_spandsp_dsp.c:159:17: note: each undeclared identifier is reported only once for each function it appears in mod_spandsp_dsp.c:165:29: error: 'V18_MODE_5BIT_50' undeclared (first use in this function) 165 | r = V18_MODE_5BIT_50; | ^~~~mod_spandsp_dsp.c: In function 'spandsp_tdd_send_session': mod_spandsp_dsp.c:216:21: error: too few arguments to function 'v18_init' 216 | tdd_state = v18_init(NULL, TRUE, get_v18_mode(session), V18_AUTOMODING_GLOBAL, put_text_msg, NULL); | ^~~~ In file included from /usr/local/include/spandsp.h:111, from mod_spandsp.h:50, from mod_spandsp_dsp.c:36: /usr/local/include/spandsp/v18.h:138:29: note: declared here 138 | SPAN_DECLARE(v18_state_t ) v18_init(v18_state_t s, | ^~~~ mod_spandsp_dsp.c: In function 'spandsp_tdd_encode_session': mod_spandsp_dsp.c:263:26: error: too few arguments to function 'v18_init' 263 | pvt->tdd_state = v18_init(NULL, TRUE, get_v18_mode(session), V18_AUTOMODING_GLOBAL, put_text_msg, NULL); | ^~~~ /usr/local/include/spandsp/v18.h:138:29: note: declared here 138 | SPAN_DECLARE(v18_state_t ) v18_init(v18_state_t s, | ^~~~ mod_spandsp_dsp.c: In function 'spandsp_tdd_decode_session': mod_spandsp_dsp.c:341:26: error: too few arguments to function 'v18_init' 341 | pvt->tdd_state = v18_init(NULL, FALSE, get_v18_mode(session), V18_AUTOMODING_GLOBAL, put_text_msg, pvt); | ^~~~ /usr/local/include/spandsp/v18.h:138:29: note: declared here 138 | SPAN_DECLARE(v18_state_t ) v18_init(v18_state_t s, ....Package version or git hash