spandsp  0.0.6
t38_core.h
Go to the documentation of this file.
1 /*
2  * SpanDSP - a series of DSP components for telephony
3  *
4  * t38_core.h - An implementation of T.38, less the packet exchange part
5  *
6  * Written by Steve Underwood <steveu@coppice.org>
7  *
8  * Copyright (C) 2005 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_T38_CORE_H_)
29 #define _SPANDSP_T38_CORE_H_
30 
31 /*! \page t38_core_page T.38 real time FAX over IP message handling
32 There are two ITU recommendations which address sending FAXes over IP networks. T.37 specifies a
33 method of encapsulating FAX images in e-mails, and transporting them to the recipient (an e-mail
34 box, or another FAX machine) in a store-and-forward manner. T.38 defines a protocol for
35 transmitting a FAX across an IP network in real time. The core T.38 modules implements the basic
36 message handling for the T.38, real time, FAX over IP (FoIP) protocol.
37 
38 The T.38 protocol can operate between:
39  - Internet-aware FAX terminals, which connect directly to an IP network. The T.38 terminal module
40  extends this module to provide a complete T.38 terminal.
41  - FAX gateways, which allow traditional PSTN FAX terminals to communicate through the Internet.
42  The T.38 gateway module extends this module to provide a T.38 gateway.
43  - A combination of terminals and gateways.
44 
45 T.38 is the only standardised protocol which exists for real-time FoIP. Reliably transporting a
46 FAX between PSTN FAX terminals, through an IP network, requires use of the T.38 protocol at FAX
47 gateways. VoIP connections are not robust for modem use, including FAX modem use. Most use low
48 bit rate codecs, which cannot convey the modem signals accurately. Even when high bit rate
49 codecs are used, VoIP connections suffer dropouts and timing adjustments, which modems cannot
50 tolerate. In a LAN environment the dropout rate may be very low, but the timing adjustments which
51 occur in VoIP connections still make modem operation unreliable. T.38 FAX gateways deal with the
52 delays, timing jitter, and packet loss experienced in packet networks, and isolate the PSTN FAX
53 terminals from these as far as possible. In addition, by sending FAXes as image data, rather than
54 digitised audio, they reduce the required bandwidth of the IP network.
55 
56 \section t38_core_page_sec_1 What does it do?
57 
58 \section t38_core_page_sec_2 How does it work?
59 
60 Timing differences and jitter between two T.38 entities can be a serious problem, if one of those
61 entities is a PSTN gateway.
62 
63 Flow control for non-ECM image data takes advantage of several features of the T.30 specification.
64 First, an unspecified number of 0xFF octets may be sent at the start of transmission. This means we
65 can add endless extra 0xFF bytes at this point, without breaking the T.30 spec. In practice, we
66 cannot add too many, or we will affect the timing tolerance of the T.30 protocol by delaying the
67 response at the end of each image. Secondly, just before an end of line (EOL) marker we can pad
68 with zero bits. Again, the number is limited only by need to avoid upsetting the timing of the
69 step following the non-ECM data.
70 */
71 
72 /*! T.38 indicator types */
74 {
75  T38_IND_NO_SIGNAL = 0,
76  T38_IND_CNG,
77  T38_IND_CED,
78  T38_IND_V21_PREAMBLE,
79  T38_IND_V27TER_2400_TRAINING,
80  T38_IND_V27TER_4800_TRAINING,
81  T38_IND_V29_7200_TRAINING,
82  T38_IND_V29_9600_TRAINING,
83  T38_IND_V17_7200_SHORT_TRAINING,
84  T38_IND_V17_7200_LONG_TRAINING,
85  T38_IND_V17_9600_SHORT_TRAINING,
86  T38_IND_V17_9600_LONG_TRAINING,
87  T38_IND_V17_12000_SHORT_TRAINING,
88  T38_IND_V17_12000_LONG_TRAINING,
89  T38_IND_V17_14400_SHORT_TRAINING,
90  T38_IND_V17_14400_LONG_TRAINING,
91  T38_IND_V8_ANSAM,
92  T38_IND_V8_SIGNAL,
93  T38_IND_V34_CNTL_CHANNEL_1200,
94  T38_IND_V34_PRI_CHANNEL,
95  T38_IND_V34_CC_RETRAIN,
96  T38_IND_V33_12000_TRAINING,
97  T38_IND_V33_14400_TRAINING
98 };
99 
100 /*! T.38 data types */
102 {
103  T38_DATA_NONE = -1,
104  T38_DATA_V21 = 0,
105  T38_DATA_V27TER_2400,
106  T38_DATA_V27TER_4800,
107  T38_DATA_V29_7200,
108  T38_DATA_V29_9600,
109  T38_DATA_V17_7200,
110  T38_DATA_V17_9600,
111  T38_DATA_V17_12000,
112  T38_DATA_V17_14400,
113  T38_DATA_V8,
114  T38_DATA_V34_PRI_RATE,
115  T38_DATA_V34_CC_1200,
116  T38_DATA_V34_PRI_CH,
117  T38_DATA_V33_12000,
118  T38_DATA_V33_14400
119 };
120 
121 /*! T.38 data field types */
123 {
124  T38_FIELD_HDLC_DATA = 0,
125  T38_FIELD_HDLC_SIG_END,
126  T38_FIELD_HDLC_FCS_OK,
127  T38_FIELD_HDLC_FCS_BAD,
128  T38_FIELD_HDLC_FCS_OK_SIG_END,
129  T38_FIELD_HDLC_FCS_BAD_SIG_END,
130  T38_FIELD_T4_NON_ECM_DATA,
131  T38_FIELD_T4_NON_ECM_SIG_END,
132  T38_FIELD_CM_MESSAGE,
133  T38_FIELD_JM_MESSAGE,
134  T38_FIELD_CI_MESSAGE,
135  T38_FIELD_V34RATE
136 };
137 
138 /*! T.38 field classes */
140 {
141  T38_FIELD_CLASS_NONE = 0,
142  T38_FIELD_CLASS_HDLC,
143  T38_FIELD_CLASS_NON_ECM
144 };
145 
146 /*! T.38 message types */
148 {
149  T38_TYPE_OF_MSG_T30_INDICATOR = 0,
150  T38_TYPE_OF_MSG_T30_DATA
151 };
152 
153 /*! T.38 transport types */
155 {
156  T38_TRANSPORT_UDPTL = 0,
157  T38_TRANSPORT_RTP,
158  T38_TRANSPORT_TCP,
159  T38_TRANSPORT_TCP_TPKT
160 };
161 
162 /*! T.38 TCF management types */
164 {
165  T38_DATA_RATE_MANAGEMENT_LOCAL_TCF = 1,
166  T38_DATA_RATE_MANAGEMENT_TRANSFERRED_TCF = 2
167 };
168 
169 /*! T.38 Packet categories used for setting the redundancy level and packet repeat
170  counts on a packet by packet basis. */
172 {
173  /*! \brief Indicator packet */
175  /*! \brief Control data packet */
177  /*! \brief Terminating control data packet */
179  /*! \brief Image data packet */
181  /*! \brief Terminating image data packet */
183 };
184 
185 #define T38_RX_BUF_LEN 2048
186 #define T38_TX_BUF_LEN 16384
187 
188 /*! T.38 data field */
189 typedef struct
190 {
191  /*! Field type */
193  /*! Field contents */
194  const uint8_t *field;
195  /*! Field length */
198 
199 /*!
200  Core T.38 state, common to all modes of T.38.
201 */
203 
204 typedef int (t38_tx_packet_handler_t)(t38_core_state_t *s, void *user_data, const uint8_t *buf, int len, int count);
205 
206 typedef int (t38_rx_indicator_handler_t)(t38_core_state_t *s, void *user_data, int indicator);
207 typedef int (t38_rx_data_handler_t)(t38_core_state_t *s, void *user_data, int data_type, int field_type, const uint8_t *buf, int len);
208 typedef int (t38_rx_missing_handler_t)(t38_core_state_t *s, void *user_data, int rx_seq_no, int expected_seq_no);
209 
210 #if defined(__cplusplus)
211 extern "C"
212 {
213 #endif
214 
215 /*! \brief Convert the code for an indicator to a short text name.
216  \param indicator The type of indicator.
217  \return A pointer to a short text name for the indicator. */
218 SPAN_DECLARE(const char *) t38_indicator_to_str(int indicator);
219 
220 /*! \brief Convert the code for a type of data to a short text name.
221  \param data_type The data type.
222  \return A pointer to a short text name for the data type. */
223 SPAN_DECLARE(const char *) t38_data_type_to_str(int data_type);
224 
225 /*! \brief Convert the code for a type of data field to a short text name.
226  \param field_type The field type.
227  \return A pointer to a short text name for the field type. */
228 SPAN_DECLARE(const char *) t38_field_type_to_str(int field_type);
229 
230 /*! \brief Convert the code for a CM profile code to text description.
231  \param profile The profile code from a CM message.
232  \return A pointer to a short text description of the profile. */
233 SPAN_DECLARE(const char *) t38_cm_profile_to_str(int profile);
234 
235 /*! \brief Convert a JM message code to text description.
236  \param data The data field of the message.
237  \param len The length of the data field.
238  \return A pointer to a short text description of the profile. */
239 SPAN_DECLARE(const char *) t38_jm_to_str(const uint8_t *data, int len);
240 
241 /*! \brief Convert a V34rate message to an actual bit rate.
242  \param data The data field of the message.
243  \param len The length of the data field.
244  \return The bit rate, or -1 for a bad message. */
245 SPAN_DECLARE(int) t38_v34rate_to_bps(const uint8_t *data, int len);
246 
247 /*! \brief Send an indicator packet
248  \param s The T.38 context.
249  \param indicator The indicator to send.
250  \return The delay to allow after this indicator is sent. */
251 SPAN_DECLARE(int) t38_core_send_indicator(t38_core_state_t *s, int indicator);
252 
253 /*! \brief Find the delay to allow for HDLC flags after sending an indicator
254  \param s The T.38 context.
255  \param indicator The indicator to check.
256  \return The delay to allow for initial HDLC flags after this indicator is sent. */
257 SPAN_DECLARE(int) t38_core_send_flags_delay(t38_core_state_t *s, int indicator);
258 
259 /*! \brief Find the delay to allow for modem training after sending an indicator
260  \param s The T.38 context.
261  \param indicator The indicator to check.
262  \return The delay to allow for modem training after this indicator is sent. */
263 SPAN_DECLARE(int) t38_core_send_training_delay(t38_core_state_t *s, int indicator);
264 
265 /*! \brief Send a data packet
266  \param s The T.38 context.
267  \param data_type The packet's data type.
268  \param field_type The packet's field type.
269  \param field The message data content for the packet.
270  \param field_len The length of the message data, in bytes.
271  \param category The category of the packet being sent. This should be one of the values defined for t38_packet_categories_e.
272  \return 0 for OK, else -1 */
273 SPAN_DECLARE(int) t38_core_send_data(t38_core_state_t *s, int data_type, int field_type, const uint8_t field[], int field_len, int category);
274 
275 /*! \brief Send a data packet
276  \param s The T.38 context.
277  \param data_type The packet's data type.
278  \param field The list of fields.
279  \param fields The number of fields in the list.
280  \param category The category of the packet being sent. This should be one of the values defined for t38_packet_categories_e.
281  \return 0 for OK, else -1 */
282 SPAN_DECLARE(int) t38_core_send_data_multi_field(t38_core_state_t *s, int data_type, const t38_data_field_t field[], int fields, int category);
283 
284 /*! \brief Process a received T.38 IFP packet from an unreliable packet stream (e.g. UDPTL or RTP). This processing includes
285  packet sequence number checking, missing packet recovery, and skipping repeat packets.
286  \param s The T.38 context.
287  \param buf The packet contents.
288  \param len The length of the packet contents.
289  \param seq_no The packet sequence number.
290  \return 0 for OK, else -1. */
291 SPAN_DECLARE_NONSTD(int) t38_core_rx_ifp_packet(t38_core_state_t *s, const uint8_t *buf, int len, uint16_t seq_no);
292 
293 /*! \brief Process a received T.38 IFP packet from a reliable stream (e.g. TCP).
294  \param s The T.38 context.
295  \param buf The packet contents.
296  \param len The length of the packet contents.
297  \param seq_no The packet sequence number, used for logging purposes.
298  \return The length of the packet processed, or -1 if there is an error in the packet, or too few bytes of data to complete it. */
299 SPAN_DECLARE_NONSTD(int) t38_core_rx_ifp_stream(t38_core_state_t *s, const uint8_t *buf, int len, uint16_t log_seq_no);
300 
301 /*! Set the method to be used for data rate management, as per the T.38 spec.
302  \param s The T.38 context.
303  \param method 1 for pass TCF across the T.38 link, 2 for handle TCF locally.
304 */
305 SPAN_DECLARE(void) t38_set_data_rate_management_method(t38_core_state_t *s, int method);
306 
307 /*! Set the data transport protocol.
308  \param s The T.38 context.
309  \param data_transport_protocol UDPTL, RTP or TPKT.
310 */
312 
313 /*! Set the non-ECM fill bit removal mode.
314  \param s The T.38 context.
315  \param fill_bit_removal TRUE to remove fill bits across the T.38 link, else FALSE.
316 */
318 
319 /*! Set the MMR transcoding mode.
320  \param s The T.38 context.
321  \param mmr_transcoding TRUE to transcode to MMR across the T.38 link, else FALSE.
322 */
323 SPAN_DECLARE(void) t38_set_mmr_transcoding(t38_core_state_t *s, int mmr_transcoding);
324 
325 /*! Set the JBIG transcoding mode.
326  \param s The T.38 context.
327  \param jbig_transcoding TRUE to transcode to JBIG across the T.38 link, else FALSE.
328 */
330 
331 /*! Set the maximum buffer size for received data at the far end.
332  \param s The T.38 context.
333  \param max_buffer_size The maximum buffer size.
334 */
335 SPAN_DECLARE(void) t38_set_max_buffer_size(t38_core_state_t *s, int max_buffer_size);
336 
337 /*! Set the maximum size of an IFP packet that is acceptable by the far end.
338  \param s The T.38 context.
339  \param max_datagram_size The maximum IFP packet length, in bytes.
340 */
342 
343 /*! \brief Send a data packet
344  \param s The T.38 context.
345  \param category The category of the packet being sent. This should be one of the values defined for t38_packet_categories_e.
346  \param setting The repeat count for the category. This should be at least one for all categories other an indicator packets.
347  Zero is valid for indicator packets, as it suppresses the sending of indicator packets, as an application using
348  TCP for the transport would require. As the setting is passed through to the transmission channel, additional
349  information may be encoded in it, such as the redundancy depth for the particular packet category. */
350 SPAN_DECLARE(void) t38_set_redundancy_control(t38_core_state_t *s, int category, int setting);
351 
352 SPAN_DECLARE(void) t38_set_pace_transmission(t38_core_state_t *s, int pace_transmission);
353 
354 SPAN_DECLARE(void) t38_set_fastest_image_data_rate(t38_core_state_t *s, int max_rate);
355 
356 SPAN_DECLARE(int) t38_get_fastest_image_data_rate(t38_core_state_t *s);
357 
358 /*! Set the T.38 version to be emulated.
359  \param s The T.38 context.
360  \param t38_version Version number, as in the T.38 spec.
361 */
362 SPAN_DECLARE(void) t38_set_t38_version(t38_core_state_t *s, int t38_version);
363 
364 /*! Set the sequence number handling option.
365  \param s The T.38 context.
366  \param check TRUE to check sequence numbers, and handle gaps reasonably. FALSE
367  for no sequence number processing (e.g. for TPKT over TCP transport).
368 */
369 SPAN_DECLARE(void) t38_set_sequence_number_handling(t38_core_state_t *s, int check);
370 
371 /*! Set the TEP handling option.
372  \param s The T.38 context.
373  \param allow_for_tep TRUE to allow for TEP playout, else FALSE.
374 */
375 SPAN_DECLARE(void) t38_set_tep_handling(t38_core_state_t *s, int allow_for_tep);
376 
377 /*! Get a pointer to the logging context associated with a T.38 context.
378  \brief Get a pointer to the logging context associated with a T.38 context.
379  \param s The T.38 context.
380  \return A pointer to the logging context, or NULL.
381 */
383 
384 /*! Restart a T.38 core context.
385  \brief Restart a T.38 core context.
386  \param s The T.38 context.
387  \return 0 for OK, else -1. */
388 SPAN_DECLARE(int) t38_core_restart(t38_core_state_t *s);
389 
390 /*! Initialise a T.38 core context.
391  \brief Initialise a T.38 core context.
392  \param s The T.38 context.
393  \param rx_indicator_handler Receive indicator handling routine.
394  \param rx_data_handler Receive data packet handling routine.
395  \param rx_rx_missing_handler Missing receive packet handling routine.
396  \param rx_packet_user_data An opaque pointer passed to the rx packet handling routines.
397  \param tx_packet_handler Packet transmit handling routine.
398  \param tx_packet_user_data An opaque pointer passed to the tx_packet_handler.
399  \return A pointer to the T.38 context, or NULL if there was a problem. */
401  t38_rx_indicator_handler_t *rx_indicator_handler,
402  t38_rx_data_handler_t *rx_data_handler,
403  t38_rx_missing_handler_t *rx_missing_handler,
404  void *rx_user_data,
405  t38_tx_packet_handler_t *tx_packet_handler,
406  void *tx_packet_user_data);
407 
408 /*! Release a signaling tone transmitter context.
409  \brief Release a signaling tone transmitter context.
410  \param s The T.38 context.
411  \return 0 for OK */
412 SPAN_DECLARE(int) t38_core_release(t38_core_state_t *s);
413 
414 /*! Free a signaling tone transmitter context.
415  \brief Free a signaling tone transmitter context.
416  \param s The T.38 context.
417  \return 0 for OK */
418 SPAN_DECLARE(int) t38_core_free(t38_core_state_t *s);
419 
420 #if defined(__cplusplus)
421 }
422 #endif
423 
424 #endif
425 /*- End of file ------------------------------------------------------------*/
int t38_core_restart(t38_core_state_t *s)
Restart a T.38 core context.
Definition: t38_core.c:1082
int data_transport_protocol
The emitting gateway may indicate a preference for either UDP/UDPTL, or UDP/RTP, or TCP for transport...
Definition: private/t38_core.h:61
Image data packet.
Definition: t38_core.h:180
int t38_core_send_indicator(t38_core_state_t *s, int indicator)
Send an indicator packet.
Definition: t38_core.c:889
t30_indicator_types_e
Definition: t38_core.h:73
int t38_v34rate_to_bps(const uint8_t *data, int len)
Convert a V34rate message to an actual bit rate.
Definition: t38_core.c:272
t38_transport_types_e
Definition: t38_core.h:154
void t38_set_tep_handling(t38_core_state_t *s, int allow_for_tep)
Definition: t38_core.c:1052
Terminating control data packet.
Definition: t38_core.h:178
const char * t38_field_type_to_str(int field_type)
Convert the code for a type of data field to a short text name.
Definition: t38_core.c:187
void t38_set_t38_version(t38_core_state_t *s, int t38_version)
Definition: t38_core.c:1034
Definition: t38_core.h:189
Terminating image data packet.
Definition: t38_core.h:182
int max_datagram_size
This option indicates the maximum size of a UDPTL packet or the maximum size of the payload within an...
Definition: private/t38_core.h:86
void * tx_packet_user_data
An opaque pointer passed to tx_packet_handler.
Definition: private/t38_core.h:37
const char * t38_jm_to_str(const uint8_t *data, int len)
Convert a JM message code to text description.
Definition: t38_core.c:241
t38_rx_indicator_handler_t * rx_indicator_handler
Handler routine to process received indicator packets.
Definition: private/t38_core.h:40
void t38_set_sequence_number_handling(t38_core_state_t *s, int check)
Definition: t38_core.c:1040
int t38_version
This is the version number of ITU-T Rec. T.38. New versions shall be compatible with previous version...
Definition: private/t38_core.h:90
t38_field_classes_e
Definition: t38_core.h:139
int jbig_transcoding
Indicates the ability to convert to/from JBIG to reduce bandwidth.
Definition: private/t38_core.h:73
logging_state_t * t38_core_get_logging_state(t38_core_state_t *s)
Get a pointer to the logging context associated with a T.38 context.
Definition: t38_core.c:1076
t38_rx_missing_handler_t * rx_missing_handler
Handler routine to process the missing packet condition.
Definition: private/t38_core.h:44
const char * t38_data_type_to_str(int data_type)
Convert the code for a type of data to a short text name.
Definition: t38_core.c:148
void * rx_user_data
An opaque pointer passed to any of the above receive handling routines.
Definition: private/t38_core.h:46
int field_type
Definition: t38_core.h:192
SPAN_DECLARE_NONSTD(int) t38_core_rx_ifp_packet(t38_core_state_t *s
Process a received T.38 IFP packet from an unreliable packet stream (e.g. UDPTL or RTP)...
int field_len
Definition: t38_core.h:196
const char * t38_indicator_to_str(int indicator)
Convert the code for an indicator to a short text name.
Definition: t38_core.c:93
Control data packet.
Definition: t38_core.h:176
t38_rx_data_handler_t * rx_data_handler
Handler routine to process received data packets.
Definition: private/t38_core.h:42
t38_data_rate_management_types_e
Definition: t38_core.h:163
int t38_core_send_flags_delay(t38_core_state_t *s, int indicator)
Find the delay to allow for HDLC flags after sending an indicator.
Definition: t38_core.c:932
int pace_transmission
Pace transmission.
Definition: private/t38_core.h:99
void t38_set_fill_bit_removal(t38_core_state_t *s, int fill_bit_removal)
Definition: t38_core.c:1004
void t38_set_mmr_transcoding(t38_core_state_t *s, int mmr_transcoding)
Definition: t38_core.c:1010
void t38_set_max_buffer_size(t38_core_state_t *s, int max_buffer_size)
Definition: t38_core.c:1022
const uint8_t * field
Definition: t38_core.h:194
t38_packet_categories_e
Definition: t38_core.h:171
int fill_bit_removal
Indicates the capability to remove and insert fill bits in Phase C, non-ECM data to reduce bandwidth ...
Definition: private/t38_core.h:65
Definition: private/logging.h:33
int t38_core_free(t38_core_state_t *s)
Free a signaling tone transmitter context.
Definition: t38_core.c:1157
void t38_set_redundancy_control(t38_core_state_t *s, int category, int setting)
Send a data packet.
Definition: t38_core.c:1058
const char * t38_cm_profile_to_str(int profile)
Convert the code for a CM profile code to text description.
Definition: t38_core.c:220
int mmr_transcoding
Indicates the ability to convert to/from MMR from/to the line format to improve the compression of th...
Definition: private/t38_core.h:70
int max_buffer_size
For UDP (UDPTL or RTP) modes, this option indicates the maximum number of octets that can be stored o...
Definition: private/t38_core.h:81
void t38_set_data_rate_management_method(t38_core_state_t *s, int method)
Definition: t38_core.c:992
void t38_set_jbig_transcoding(t38_core_state_t *s, int jbig_transcoding)
Definition: t38_core.c:1016
t38_tx_packet_handler_t * tx_packet_handler
Handler routine to transmit IFP packets generated by the T.38 protocol engine.
Definition: private/t38_core.h:35
int allow_for_tep
Allow time for TEP playout.
Definition: private/t38_core.h:93
t38_field_types_e
Definition: t38_core.h:122
void t38_set_data_transport_protocol(t38_core_state_t *s, int data_transport_protocol)
Definition: t38_core.c:998
void t38_set_max_datagram_size(t38_core_state_t *s, int max_datagram_size)
Definition: t38_core.c:1028
int t38_core_send_training_delay(t38_core_state_t *s, int indicator)
Find the delay to allow for modem training after sending an indicator.
Definition: t38_core.c:940
t38_core_state_t * t38_core_init(t38_core_state_t *s, t38_rx_indicator_handler_t *rx_indicator_handler, t38_rx_data_handler_t *rx_data_handler, t38_rx_missing_handler_t *rx_missing_handler, void *rx_user_data, t38_tx_packet_handler_t *tx_packet_handler, void *tx_packet_user_data)
Initialise a T.38 core context.
Definition: t38_core.c:1102
Definition: private/t38_core.h:32
t38_message_types_e
Definition: t38_core.h:147
int t38_core_release(t38_core_state_t *s)
Release a signaling tone transmitter context.
Definition: t38_core.c:1151
int t38_core_send_data_multi_field(t38_core_state_t *s, int data_type, const t38_data_field_t field[], int fields, int category)
Send a data packet.
Definition: t38_core.c:972
t38_data_types_e
Definition: t38_core.h:101
Indicator packet.
Definition: t38_core.h:174
int t38_core_send_data(t38_core_state_t *s, int data_type, int field_type, const uint8_t field[], int field_len, int category)
Send a data packet.
Definition: t38_core.c:948