佛系修bug

This commit is contained in:
HalfSweet
2022-02-14 17:57:45 +08:00
parent 8728602643
commit 8797aaa8b3
2 changed files with 16 additions and 9 deletions

View File

@@ -18,6 +18,7 @@ EPaperDrive::EPaperDrive(bool SPIMode, uint8_t CS, uint8_t RST, uint8_t DC, uint
pinMode(CS, OUTPUT); // io初始化 pinMode(CS, OUTPUT); // io初始化
pinMode(DC, OUTPUT); pinMode(DC, OUTPUT);
pinMode(RST, OUTPUT); pinMode(RST, OUTPUT);
digitalWrite(RST, HIGH);
pinMode(BUSY, INPUT); pinMode(BUSY, INPUT);
pinMode(CLK, OUTPUT); pinMode(CLK, OUTPUT);
pinMode(DIN, OUTPUT); pinMode(DIN, OUTPUT);
@@ -27,6 +28,7 @@ EPaperDrive::EPaperDrive(bool SPIMode, uint8_t CS, uint8_t RST, uint8_t DC, uint
pinMode(CS, OUTPUT); pinMode(CS, OUTPUT);
pinMode(DC, OUTPUT); pinMode(DC, OUTPUT);
pinMode(RST, OUTPUT); pinMode(RST, OUTPUT);
digitalWrite(RST, HIGH);
pinMode(BUSY, INPUT); pinMode(BUSY, INPUT);
} }
} }
@@ -2530,7 +2532,7 @@ void EPaperDrive::EPD_Dis_Part(int xStart, int xEnd, int yStart, int yEnd, uint8
// Serial.printf("即将写入的是局刷的的0x26数据 \n"); // Serial.printf("即将写入的是局刷的的0x26数据 \n");
EPD_WriteDispRam_Old(Xsize, Ysize, (uint8_t *)DisBuffer, offset, 1); EPD_WriteDispRam_Old(Xsize, Ysize, (uint8_t *)DisBuffer, offset, 1);
} }
else if (EPD_Type == GDEY042Z98) else if (EPD_Type == GDEY042Z98 )
{ {
EPD_WriteDispRam_Old(Xsize, Ysize, (uint8_t *)DisBuffer, offset, 1); EPD_WriteDispRam_Old(Xsize, Ysize, (uint8_t *)DisBuffer, offset, 1);
@@ -2541,6 +2543,10 @@ void EPaperDrive::EPD_Dis_Part(int xStart, int xEnd, int yStart, int yEnd, uint8
EPD_SetRamPointer(xStart / 8, yEnd % 256, yEnd / 256); EPD_SetRamPointer(xStart / 8, yEnd % 256, yEnd / 256);
EPD_WriteDispRam_Old(Xsize, Ysize, (uint8_t *)DisBuffer, offset, 1); EPD_WriteDispRam_Old(Xsize, Ysize, (uint8_t *)DisBuffer, offset, 1);
} }
else if(EPD_Type == OPM42 || EPD_Type == DKE42_3COLOR)
{
EPD_WriteDispRam(Xsize, Ysize, (uint8_t *)DisBuffer, offset, 1);
}
// EPD_WriteDispRam_Old(Xsize, Ysize,(uint8_t *)DisBuffer,offset,1); // EPD_WriteDispRam_Old(Xsize, Ysize,(uint8_t *)DisBuffer,offset,1);
} }

View File

@@ -814,8 +814,8 @@ const uint8_t lut_bb_part_WFT0290CZ10[]={
const uint8_t LUTDefault_full_GDEY042Z98[] = { const uint8_t LUTDefault_full_GDEY042Z98[] = {
0x32, 0x32,
//VCOM //VCOM
0x01, 0x1E, 0x1E, 0x05, 0x3C, 0x02, 0x03, 0x01, 0x23, 0x23, 0x05, 0x3C, 0x02, 0x03,
0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
@@ -823,8 +823,8 @@ const uint8_t LUTDefault_full_GDEY042Z98[] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
//RED //RED
0x01, 0x5E, 0x9E, 0x85, 0xFC, 0x02, 0x03, 0x01, 0x63, 0xA3, 0x85, 0xFC, 0x02, 0x03,
0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
@@ -832,8 +832,8 @@ const uint8_t LUTDefault_full_GDEY042Z98[] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
//WHITE //WHITE
0x01, 0x5E, 0x9E, 0x05, 0x3C, 0x02, 0x03, 0x01, 0x63, 0xA3, 0x05, 0x3C, 0x02, 0x03,
0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
@@ -841,8 +841,8 @@ const uint8_t LUTDefault_full_GDEY042Z98[] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
//BLACK //BLACK
0x01, 0x9E, 0x5E, 0x05, 0x3C, 0x02, 0x03, 0x01, 0xA3, 0x63, 0x05, 0x3C, 0x02, 0x03,
0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
@@ -853,6 +853,7 @@ const uint8_t LUTDefault_full_GDEY042Z98[] = {
0x03, 0x00, 0x00, 0x22, 0x17, 0x41, 0xA8, 0x03, 0x00, 0x00, 0x22, 0x17, 0x41, 0xA8,
0x32, 0x48, 0x32, 0x48,
}; };
const uint8_t LUTDefault_part_GDEY042Z98[] = { const uint8_t LUTDefault_part_GDEY042Z98[] = {