/**
 * receiver_controller.h: Controller for softdevice receiver
 * 
 * Copyright: See COPYING file that comes with this distribution
 *
 * Author: Matthias Feistel <hitman_47@users.sourceforge.net>, (C) 2006, 2007
 */

#ifndef ___RECEIVERCONTROLLER_H
#define ___RECEIVERCONTROLLER_H

#include <vdr/plugin.h>
// BEGIN SoftplayReceiver
#include "receiver_softdevice.h"
#include "receiver_softhandles.h"
// END SoftplayReceiver


class cReceiverController
{
protected:
	void ResetDevice( int Streams );
	bool PollDevice( int Streams );
	void FlushDevice( int Streams );
	void FreezeDevice( int Streams, bool Freeze );
public:
	cReceiverController( void );
	~cReceiverController( );
	void ChannelUpDown( int i );
private:
	cSoftplayReceiver *Receiver_;
	int pollTimeouts;
	PacketHandlesV100 SoftHandles;
	cPlugin *softdevicePlugin_;
	int SearchSoftdevice( void );
};

#endif // ___RECEIVERCONTROLLER_H
