spandsp 0.0.6

t30_logging.h
Go to the documentation of this file.
1/*
2 * SpanDSP - a series of DSP components for telephony
3 *
4 * t30_logging.h - definitions for T.30 fax processing
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_T30_LOGGING_H_)
29#define _SPANDSP_T30_LOGGING_H_
30
31#if defined(__cplusplus)
32 extern "C"
33{
34#endif
35
36/*! Return a text name for a T.30 frame type.
37 \brief Return a text name for a T.30 frame type.
38 \param x The frametype octet.
39 \return A pointer to the text name for the frame type. If the frame type is
40 not value, the string "???" is returned. */
41SPAN_DECLARE(const char *) t30_frametype(uint8_t x);
42
43/*! Decode a DIS, DTC or DCS frame, and log the contents.
44 \brief Decode a DIS, DTC or DCS frame, and log the contents.
45 \param s The T.30 context.
46 \param dis A pointer to the frame to be decoded.
47 \param len The length of the frame. */
48SPAN_DECLARE(void) t30_decode_dis_dtc_dcs(t30_state_t *s, const uint8_t *dis, int len);
49
50/*! Convert a phase E completion code to a short text description.
51 \brief Convert a phase E completion code to a short text description.
52 \param result The result code.
53 \return A pointer to the description. */
54SPAN_DECLARE(const char *) t30_completion_code_to_str(int result);
55
56#if defined(__cplusplus)
57}
58#endif
59
60#endif
61/*- End of file ------------------------------------------------------------*/
t30_completion_code_to_str
const char * t30_completion_code_to_str(int result)
Convert a phase E completion code to a short text description.
Definition t30_logging.c:108
t30_frametype
const char * t30_frametype(uint8_t x)
Return a text name for a T.30 frame type.
Definition t30_logging.c:241
t30_decode_dis_dtc_dcs
void t30_decode_dis_dtc_dcs(t30_state_t *s, const uint8_t *dis, int len)
Decode a DIS, DTC or DCS frame, and log the contents.
Definition t30_logging.c:506