#ifndef REMOTEDATA_H_
#define REMOTEDATA_H_

#define dRemoteDataLengthBytes	20480
#define dRemoteDataLengthIntegers	5120

class TRemoteData{
	public:
		static constexpr unsigned int RegOffsetPortExist = 0;
		static constexpr unsigned int RegOffsetPortHasRpy = 40;
		static constexpr unsigned int RegOffsetEpType = 80;

	public:
		union{
			unsigned char Bytes[dRemoteDataLengthBytes];
			unsigned int Integers[dRemoteDataLengthIntegers];
			
			struct{
				unsigned char FlashPageData[256];
				unsigned char ProgressVal[40];
				unsigned char SearchCompleted[40];
				unsigned char HasRpy[40];
				unsigned char HasQuery[40];
				unsigned char TransmiteCompleted[40];
				unsigned char ItemsCount[40];
				unsigned char dType[40][256];
				
				unsigned char Data[8];
				unsigned char RecData[8];
				unsigned char RegWhat;
				unsigned char IsQuerying;
				unsigned char QueryNum;
				unsigned char QueryNumRpy;
				unsigned char QueryTimeOut;
			}EpReg;
			
		};
	public:
		TRemoteData(){}
		void Reset(){
			for(int i=0; i<dRemoteDataLengthIntegers; i++)Integers[i] =0;
		}
};



#endif

