Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

dabdatagroupdecoder.h File Reference


Detailed Description

Journaline(R) news service DAB data group decoder interface.

techidee GmbH

Project: NewsBox

Author: Thomas Fruehwald

Compiler: gcc

Module: DAB data group decoder

Creation date: 2003-08-02

Last modified: 2004-02-25 (rbr)

This decoder will accept DAB data groups, check their validity and pass on the valid (Journaline) data groups.

To use it, you have to implement the callback for handling the output in your application. Then use createDec to create an instance, putData to put DAB data groups into the decoder and in the end, use deleteDec to destroy the instance.

Attention:
only the features needed for the news service "Journaline(R)" are implemented in this DAB data group decoder, i.e.
Attention:
The DAB data group decoder is not thread safe.

Go to the source code of this file.

Compounds

struct  DAB_DATAGROUP_DECODER_msc_datagroup_header_t
 MSC data group header. More...


Typedefs

typedef const void * DAB_DATAGROUP_DECODER_t
 dab data group decoder instance type

typedef void( DAB_DATAGROUP_DECODER_data )(const DAB_DATAGROUP_DECODER_msc_datagroup_header_t *header, const unsigned long len, const unsigned char *buf, void *arg)
 DAB data group callback function.


Functions

DAB_DATAGROUP_DECODER_t DAB_DATAGROUP_DECODER_createDec (DAB_DATAGROUP_DECODER_data *data, void *arg)
 Create a DAB data group decoder instance.

void DAB_DATAGROUP_DECODER_deleteDec (const DAB_DATAGROUP_DECODER_t decoder)
 Delete a DAB data group decoder instance.

unsigned long DAB_DATAGROUP_DECODER_putData (const DAB_DATAGROUP_DECODER_t decoder, const unsigned long len, const unsigned char *buf)
 Put data into DAB data group decoder.


Typedef Documentation

typedef void( DAB_DATAGROUP_DECODER_data)( const DAB_DATAGROUP_DECODER_msc_datagroup_header_t *header, const unsigned long len, const unsigned char *buf, void *arg )
 

DAB data group callback function.

A callback function of this type must be registered at creation time of the DAB data group decoder instance.

It will be called whenever a DAB data group fed into the decoder using DAB_DATAGROUP_DECODER_putData has been processed successfully, i.e. it is a valid (Journaline specific) data group and can fed into the news service decoder.

Parameters:
header  MSC data group header
len  length in bytes of MSC data group data field
buf  MSC data group data field
arg  user specified data pointer (as specified in createDec)

typedef const void* DAB_DATAGROUP_DECODER_t
 

dab data group decoder instance type


Function Documentation

DAB_DATAGROUP_DECODER_t DAB_DATAGROUP_DECODER_createDec DAB_DATAGROUP_DECODER_data   data,
void *    arg
 

Create a DAB data group decoder instance.

call this before anything else

Parameters:
data  DAB data group decoder callback function
arg  user specified data pointer (will only be passed to callback)
Returns :
DAB data group decoder instance

void DAB_DATAGROUP_DECODER_deleteDec const DAB_DATAGROUP_DECODER_t    decoder
 

Delete a DAB data group decoder instance.

call this at shutdown time

Parameters:
decoder  DAB data group decoder instance

unsigned long DAB_DATAGROUP_DECODER_putData const DAB_DATAGROUP_DECODER_t    decoder,
const unsigned long    len,
const unsigned char *    buf
 

Put data into DAB data group decoder.

The input for the DAB data group decoder consists of complete DAB data groups.

A CRC check is done if the CRC flag is set in the data group header.

Parameters:
decoder  DAB data group decoder instance (as obtained by DAB_DATAGROUP_DECODER_createDec)
len  length in bytes of MSC data group
buf  DAB data group
Return values:
0  on failure
1  on success


Generated on Thu Mar 18 13:10:33 2004 for journaline_demo by doxygen1.2.17