webradio/receiver.h File Reference


Detailed Description

Audio data receiver.

 *
 * $Log$
 *
 * 

Definition in file receiver.h.

Go to the source code of this file.

Data Structures

struct  RECEIVERPLUGIN
 Receiver plug-in reference structure. More...
struct  RECEIVERINFO
 Receiver information structure. More...

Receiver Status



#define RSTAT_IDLE   0x0001
 Receiver is idle.
#define RSTAT_START   0x0002
 Request to start receiver.
#define RSTAT_BUFFERING   0x0004
 Receiver is running.
#define RSTAT_RUNNING   0x0008
 Receiver is running.
#define RSTAT_STOP   0x0010
 Request to stop receiver.

Functions

RECEIVERINFOReceiverCreate (RECEIVERPLUGIN *plugin)
 Create stream receiver instance with the specified plug-in.
RECEIVERINFOReceiverStart (RECEIVERINFO *ritab[], STATIONINFO *sip)
 Start receiver for the connected stream.
int ReceiverStop (RECEIVERINFO *rip)
 Stop receiver.
u_int ReceiverStatus (RECEIVERINFO *rip)
 Retrieve the current receiver status.


Define Documentation

#define RSTAT_IDLE   0x0001

Receiver is idle.

Definition at line 55 of file receiver.h.

Referenced by main(), ReceiverStop(), and ShoutCastThread().

#define RSTAT_START   0x0002

Request to start receiver.

Definition at line 57 of file receiver.h.

Referenced by ReceiverStart(), and ShoutCastThread().

#define RSTAT_BUFFERING   0x0004

Receiver is running.

Definition at line 59 of file receiver.h.

Referenced by ReceiverStart(), and ShoutCastThread().

#define RSTAT_RUNNING   0x0008

Receiver is running.

Definition at line 61 of file receiver.h.

Referenced by ReceiverStart(), and ShoutCastThread().

#define RSTAT_STOP   0x0010

Request to stop receiver.

Definition at line 63 of file receiver.h.

Referenced by main(), ReceiverStop(), and ShoutCastThread().


Function Documentation

RECEIVERINFO* ReceiverCreate ( RECEIVERPLUGIN plugin  ) 

Create stream receiver instance with the specified plug-in.

Parameters:
plugin Pointer to a receiver plug-in.
Returns:
Pointer to the receiver info structure or NULL, if the creation failed.

Definition at line 86 of file receiver.c.

References RECEIVERINFO::ri_rpp, and RECEIVERPLUGIN::rp_create.

RECEIVERINFO* ReceiverStart ( RECEIVERINFO ritab[],
STATIONINFO sip 
)

Start receiver for the connected stream.

Parameters:
ritab Table of available receivers.
sip Information structure of the connected station .
Returns:
Pointer to the receiver entry that had been started. NULL is returned in case any error.

Definition at line 162 of file receiver.c.

References LOG_WARN, LogMsg(), ReceiverPlugInControl(), ReceiverStop(), RECEIVERINFO::ri_rpp, RECEIVERINFO::ri_sip, RECEIVERPLUGIN::rp_setup, RSTAT_BUFFERING, RSTAT_RUNNING, and RSTAT_START.

Here is the call graph for this function:

LogMsgReceiverPlugInControlReceiverStop

int ReceiverStop ( RECEIVERINFO rip  ) 

Stop receiver.

Parameters:
rip Receiver to stop.
Returns:
0 on success, -1 otherwise.

Definition at line 148 of file receiver.c.

References ReceiverPlugInControl(), RSTAT_IDLE, and RSTAT_STOP.

Here is the call graph for this function:

ReceiverPlugInControlLogMsg

u_int ReceiverStatus ( RECEIVERINFO rip  ) 

Retrieve the current receiver status.

Parameters:
rip Pointer to the receiver information structure.
Returns:
Receiver status.

Definition at line 136 of file receiver.c.

References RECEIVERINFO::ri_status.


© 2008 by egnite GmbH - visit www.ethernut.de