FreeCalypso > hg > gsm-codec-lib
comparison libtest/tw5reader.h @ 522:4d2cccaeb4a7
libtest: implement TW-TS-005 reader function
Spec reference:
https://www.freecalypso.org/specs/tw-ts-005-v010002.txt
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Thu, 19 Sep 2024 03:08:47 +0000 |
parents | libtest/binreader.h@820d88b97924 |
children |
comparison
equal
deleted
inserted
replaced
521:68fe269b4316 | 522:4d2cccaeb4a7 |
---|---|
1 /* | |
2 * This header file defines the interface to our reader function for | |
3 * hexadecimal RTP frame sequence files in TW-TS-005 format. | |
4 * | |
5 * twts005_read_frame() return values are: | |
6 * 1 = successfully read valid frame | |
7 * 0 = normal EOF | |
8 * -1 = read line with invalid content | |
9 * -2 = line too long or missing newline | |
10 * | |
11 * The reader function skips blank, whitespace-only and comment lines, | |
12 * returning only actual frames. lineno variable must be initialized to 0 | |
13 * by the application program, but not touched otherwise. In case of an | |
14 * error, this variable will hold the line number at which the error was | |
15 * encountered. | |
16 */ | |
17 | |
18 #define TWTS005_MAX_FRAME 40 | |
19 | |
20 int twts005_read_frame(FILE *hexf, unsigned *lineno, uint8_t *frame, | |
21 unsigned *lenp); |