spandsp: adsi.h Source File

spandsp 0.0.6

private/adsi.h
Go to the documentation of this file.
1/*
2 * SpanDSP - a series of DSP components for telephony
3 *
4 * private/adsi.h - Analogue display services interface and other call ID related handling.
5 *
6 * Written by Steve Underwood <steveu@coppice.org>
7 *
8 * Copyright (C) 2003 Steve Underwood
9 *
10 * All rights reserved.
11 *
12 * This program is free software; you can redistribute it and/or modify
13 * it under the terms of the GNU Lesser General Public License version 2.1,
14 * as published by the Free Software Foundation.
15 *
16 * This program is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU Lesser General Public License for more details.
20 *
21 * You should have received a copy of the GNU Lesser General Public
22 * License along with this program; if not, write to the Free Software
23 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
24 */
25
26/*! \file */
27
28#if !defined(_SPANDSP_PRIVATE_ADSI_H_)
29#define _SPANDSP_PRIVATE_ADSI_H_
30
31/*!
32 ADSI transmitter descriptor. This contains all the state information for an ADSI
33 (caller ID, CLASS, CLIP, ACLIP) transmit channel.
34 */
35 struct adsi_tx_state_s
36{
37 /*! */
38 int standard;
39
40 /*! */
41 tone_gen_descriptor_t alert_tone_desc;
42 /*! */
43 tone_gen_state_t alert_tone_gen;
44 /*! */
45 fsk_tx_state_t fsktx;
46 /*! */
47 dtmf_tx_state_t dtmftx;
48 /*! */
49 async_tx_state_t asynctx;
50
51 /*! */
52 int tx_signal_on;
53
54 /*! */
55 int byte_no;
56 /*! */
57 int bit_pos;
58 /*! */
59 int bit_no;
60 /*! */
61 uint8_t msg[256];
62 /*! */
63 int msg_len;
64 /*! */
65 int preamble_len;
66 /*! */
67 int preamble_ones_len;
68 /*! */
69 int postamble_ones_len;
70 /*! */
71 int stop_bits;
72 /*! */
73 int baudot_shift;
74
75 /*! */
76 logging_state_t logging;
77};
78
79/*!
80 ADSI receiver descriptor. This contains all the state information for an ADSI
81 (caller ID, CLASS, CLIP, ACLIP, JCLIP) receive channel.
82 */
83 struct adsi_rx_state_s
84{
85 /*! */
86 int standard;
87 /*! */
88 put_msg_func_t put_msg;
89 /*! */
90 void *user_data;
91
92 /*! */
93 fsk_rx_state_t fskrx;
94 /*! */
95 dtmf_rx_state_t dtmfrx;
96
97 /*! */
98 int consecutive_ones;
99 /*! */
100 int bit_pos;
101 /*! */
102 int in_progress;
103 /*! */
104 uint8_t msg[256];
105 /*! */
106 int msg_len;
107 /*! */
108 int baudot_shift;
109
110 /*! A count of the framing errors. */
111 int framing_errors;
112
113 /*! */
114 logging_state_t logging;
115};
116
117#endif
118/*- End of file ------------------------------------------------------------*/
put_msg_func_t
void(* put_msg_func_t)(void *user_data, const uint8_t *msg, int len)
Definition async.h:93
adsi_rx_state_s
Definition private/adsi.h:84
adsi_rx_state_s::framing_errors
int framing_errors
Definition private/adsi.h:111
adsi_tx_state_s
Definition private/adsi.h:36
async_tx_state_s
Definition private/async.h:35
dtmf_rx_state_s
Definition private/dtmf.h:51
dtmf_tx_state_s
Definition private/dtmf.h:34
fsk_rx_state_s
Definition private/fsk.h:59
fsk_tx_state_s
Definition private/fsk.h:34
logging_state_s
Definition private/logging.h:34
tone_gen_descriptor_s
Definition private/tone_generate.h:43
tone_gen_state_s
Definition private/tone_generate.h:54