FutabaGP1212A02.h
changeset 15 105f2c0d3cf1
parent 14 86faea78ddf0
child 16 42ba42be810d
     1.1 --- a/FutabaGP1212A02.h	Sat Aug 30 18:43:54 2014 +0200
     1.2 +++ b/FutabaGP1212A02.h	Sun Aug 31 17:42:10 2014 +0200
     1.3 @@ -30,18 +30,13 @@
     1.4  	virtual void SetPixel(unsigned char aX, unsigned char aY, bool aOn);
     1.5  	virtual void SetAllPixels(unsigned char aPattern);
     1.6      virtual int FrameBufferSizeInBytes() const {return KGP12xFrameBufferSizeInBytes;}
     1.7 -    //virtual void BitBlit(const BitArray& aBitmap, int aSrcWidth, int aSrcHeight, int aTargetX, int aTargetY) const;
     1.8  	virtual void SetBrightness(int aBrightness);
     1.9  	virtual void Clear();
    1.10  	virtual void Fill();
    1.11 +	virtual void Request(TMiniDisplayRequest aRequest);
    1.12  
    1.13 -	//Specific to GP1212A02A
    1.14  	
    1.15 -	
    1.16 -    //
    1.17 -    void RequestDeviceId();
    1.18 -    void RequestFirmwareRevision();
    1.19 -    void RequestPowerSupplyStatus();
    1.20 +		
    1.21  	//
    1.22  	void ToggleOffScreenMode();
    1.23      void SetOffScreenMode(bool aOn);
    1.24 @@ -70,7 +65,6 @@
    1.25  		ETargetDataMemory=0x31
    1.26  	};
    1.27  
    1.28 -
    1.29  	enum TDirection
    1.30  	{
    1.31  		EDirectionY=0x30,
    1.32 @@ -78,6 +72,8 @@
    1.33  	};
    1.34  
    1.35  
    1.36 +private:
    1.37 +	//Specific to GP1212A02A
    1.38  	//General setting command
    1.39  	void BmpDataInput(TTarget aTarget, unsigned short aAddress, TDirection aDirection, unsigned short aSize, unsigned char* aPixels);
    1.40  
    1.41 @@ -88,6 +84,12 @@
    1.42  	void BmpBoxDataInput(unsigned short aSize, unsigned char* aPixels);
    1.43  
    1.44  private:
    1.45 +    void RequestDeviceId();
    1.46 +    void RequestFirmwareRevision();
    1.47 +    void RequestPowerSupplyStatus();
    1.48 +
    1.49 +
    1.50 +private:
    1.51  	unsigned char OffScreenY() const;
    1.52  	void SendClearCommand();
    1.53  	void OffScreenTranslation(unsigned char& aX, unsigned char& aY);
    1.54 @@ -122,6 +124,8 @@
    1.55  	char iDeviceId[KFutabaMaxHidReportSize];
    1.56  	char iFirmwareRevision[KFutabaMaxHidReportSize];
    1.57      bool iPowerOn;
    1.58 +	//
    1.59 +	unsigned short iNextFrameAddress;
    1.60  	};
    1.61  
    1.62