summaryrefslogtreecommitdiffstats
path: root/bchannel.h
diff options
context:
space:
mode:
authorAndreas Eversberg2010-01-24 14:22:34 +0100
committerAndreas Eversberg2010-01-24 14:22:34 +0100
commit34b17bad86b02fae864505ae5fe7055a2bd63290 (patch)
tree5bc4fe77434528ae57e7aa6f2f2a5e577fec5d96 /bchannel.h
parentAdded "release" action and timeout to "execute" action. (diff)
downloadlcr-34b17bad86b02fae864505ae5fe7055a2bd63290.tar.gz
lcr-34b17bad86b02fae864505ae5fe7055a2bd63290.tar.xz
lcr-34b17bad86b02fae864505ae5fe7055a2bd63290.zip
Added queue buffer for chan_lcr sending faxes without interruption.
Use options "t:q250" for disabling mISDN_dsp and adding a 250ms delay. modified: README modified: bchannel.c modified: bchannel.h modified: chan_lcr.c modified: chan_lcr.h modified: select.c
Diffstat (limited to 'bchannel.h')
-rw-r--r--bchannel.h16
1 files changed, 15 insertions, 1 deletions
diff --git a/bchannel.h b/bchannel.h
index 2b03444..55ce323 100644
--- a/bchannel.h
+++ b/bchannel.h
@@ -9,6 +9,11 @@
** **
\*****************************************************************************/
+/* this test produces a test tone to test gaps in audio stream */
+//#define SEAMLESS_TEST
+
+#define QUEUE_BUFFER_SIZE 8192 /* must be the power of two */
+#define QUEUE_BUFFER_MAX 4096 /* half of size */
struct bchannel {
struct bchannel *next;
@@ -31,6 +36,15 @@ struct bchannel {
int b_dtmf;
int b_bf_len;
unsigned char b_bf_key[128];
+ int nodsp_queue; /* enables nodsp_queue_buffer */
+ unsigned char nodsp_queue_buffer[QUEUE_BUFFER_SIZE];
+ /* buffer for seamless transmission */
+ unsigned int nodsp_queue_in, nodsp_queue_out;
+ /* in and out pointers */
+ int queue_sent; /* data for mISDN was not confrmed yet */
+#ifdef SEAMLESS_TEST
+ int test;
+#endif
};
@@ -40,7 +54,7 @@ extern pid_t bchannel_pid;
int bchannel_initialize(void);
void bchannel_deinitialize(void);
void bchannel_destroy(struct bchannel *bchannel);
-int bchannel_create(struct bchannel *channel, int mode);
+int bchannel_create(struct bchannel *channel, int mode, int queue);
void bchannel_activate(struct bchannel *channel, int activate);
void bchannel_transmit(struct bchannel *channel, unsigned char *data, int len);
void bchannel_join(struct bchannel *channel, unsigned short id);