view trau-ul-prep/binreader.h @ 74:e78c6b1ecb91

trau-decode: refactor trau-hr-dump The desire is to create a companion program that will read hex lines representing TRAU-8k frames and then decode those frames in exactly the same way how we currently decode frames read from binary capture files. Hence the decoder portion of trau-hr-dump needs to be factored out.
author Mychaela Falconia <falcon@freecalypso.org>
date Sat, 08 Feb 2025 03:00:31 +0000
parents 4ab8762be333
children
line wrap: on
line source

/*
 * This header file defines the interface to our reader function for binary
 * files recording GSM FR or EFR streams, see ../doc/Binary-file-format.
 *
 * binfile_read_frame() return values are:
 *  1 = successfully read valid frame
 *  0 = normal EOF
 * -1 = unrecognized header byte
 * -2 = EOF in the middle of a frame
 */

#define	BINFILE_MAX_FRAME	33

extern int binfile_read_frame(FILE *binf, uint8_t *frame);