Add 4.37inch e-Paper (G) STM32 program and fix some bugs.
This commit is contained in:
parent
31c2e4176e
commit
77accf11dd
32 changed files with 4453 additions and 1186 deletions
|
|
@ -262,14 +262,21 @@ parameter:
|
|||
******************************************************************************/
|
||||
void Paint_Clear(UWORD Color)
|
||||
{
|
||||
if(Paint.Scale == 2 || Paint.Scale == 4){
|
||||
if(Paint.Scale == 2) {
|
||||
for (UWORD Y = 0; Y < Paint.HeightByte; Y++) {
|
||||
for (UWORD X = 0; X < Paint.WidthByte; X++ ) {//8 pixel = 1 byte
|
||||
UDOUBLE Addr = X + Y*Paint.WidthByte;
|
||||
Paint.Image[Addr] = Color;
|
||||
}
|
||||
}
|
||||
}else if(Paint.Scale == 7){
|
||||
}else if(Paint.Scale == 4) {
|
||||
for (UWORD Y = 0; Y < Paint.HeightByte; Y++) {
|
||||
for (UWORD X = 0; X < Paint.WidthByte; X++ ) {
|
||||
UDOUBLE Addr = X + Y*Paint.WidthByte;
|
||||
Paint.Image[Addr] = (Color<<6)|(Color<<4)|(Color<<2)|Color;
|
||||
}
|
||||
}
|
||||
}else if(Paint.Scale == 7) {
|
||||
for (UWORD Y = 0; Y < Paint.HeightByte; Y++) {
|
||||
for (UWORD X = 0; X < Paint.WidthByte; X++ ) {
|
||||
UDOUBLE Addr = X + Y*Paint.WidthByte;
|
||||
|
|
|
|||
|
|
@ -125,11 +125,6 @@ typedef enum {
|
|||
#define GRAY3 0x01 //gray
|
||||
#define GRAY4 0x00 //white
|
||||
|
||||
//colour
|
||||
#define Black_4Color 0x00
|
||||
#define White_4Color 0x01
|
||||
#define Yellow_4Color 0x02
|
||||
#define Red_4Color 0x03
|
||||
/**
|
||||
* The size of the point
|
||||
**/
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue