/**************************************************************************
<MODULE NAME>
<FILENAME></FILENAME>
<HISTORY>
	<MODIFICATION>
		<DATE>04/01/2006</DATE>
		<AUTHOR>DRO</AUTHOR>
		<DESCRIPTION>
		</DESCRIPTION>
	</MODIFICATION>
</HISTORY>
</MODULE NAME>
**************************************************************************/
#ifndef __CdRdIJit_H__
#define __CdRdIJit_H__

/**************************************************************************
INCLUDE FILE
**************************************************************************/
#include "..\comp\UrnCrd\CDRDMGUR.h"
#include "..\comp\CardRead\LECTEUR.h"

/**************************************************************************
<CLASS>
	<NAME>CCardReaderJites</NAME>
	<MOTHERS>
		<MOTHER></MOTHER>
	</MOTHERS>
	<DESCRIPTION>
	</DESCRIPTION>
</CLASS>
**************************************************************************/
class CCardReaderUrneJites : public CCardReaderUrneManager
{
public:
	CCardReaderUrneJites(void);
	virtual ~CCardReaderUrneJites(void);

	virtual int LecteurInit(s_Parameters* shParm);
	virtual int  LecteurInit(void);

	virtual int SendReadCommande(char* pzLectBuffer);
	virtual int ReadCommande(char* pzLectBuffer);
	
	virtual int SendEjectCommande(unsigned char ucDirection);	
	virtual int EjectCommande(char* pzString);

	virtual int SendStatusCommande(void);
	virtual int StatusCommande(char* pzString);

	virtual int CloseConnection(void);

	virtual int SendDeblock(void);
	virtual int Deblock(char* pzString);
	
	virtual int Tempo(char* pzString);
	virtual int WaitCard(void);
	virtual void CheckQueue(void);


	static CCardReaderUrneManager* Instance(void);
	
	/*Urne if read only*/
	virtual int SendWriteCommande(const char* pzString)
		{return -1;}
	virtual int WriteCommande(char* pzString)
		{return -1;}

protected:
	int TcrSnd(char *Buff_Commande);
	int TcrRx(char *Buff_Commande);
	int FinRx(char *Buff_Commande);

private:
	uchar m_arucRxBuffer[100];
	uchar m_arucTxBuffer[100];
	
	s_Parameters m_sParameters;

};

#endif /*__CdRdIJit_H__*/