Skip to content

solved issue of mirroring screen after rotation. #1270

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions drivers/staging/fbtft/fb_tinylcd.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ static int init_display(struct fbtft_par *par)

write_reg(par, 0xB0, 0x80);
write_reg(par, 0xC0, 0x0A, 0x0A);
write_reg(par, 0xC1, 0x45, 0x07);
write_reg(par, 0xC1, 0x01, 0x01);
write_reg(par, 0xC2, 0x33);
write_reg(par, 0xC5, 0x00, 0x42, 0x80);
write_reg(par, 0xB1, 0xD0, 0x11);
Expand Down Expand Up @@ -83,20 +83,20 @@ static int set_var(struct fbtft_par *par)

switch (par->info->var.rotate) {
case 270:
write_reg(par, 0xB6, 0x00, 0x02, 0x3B);
write_reg(par, 0x36, 0x28);
write_reg(par, 0xB6, 0x00, 0x62, 0x3B);
write_reg(par, 0x36, 0x2B);
break;
case 180:
write_reg(par, 0xB6, 0x00, 0x22, 0x3B);
write_reg(par, 0x36, 0x58);
write_reg(par, 0xB6, 0x00, 0x42, 0x3B);
write_reg(par, 0x36, 0x09);
break;
case 90:
write_reg(par, 0xB6, 0x00, 0x22, 0x3B);
write_reg(par, 0x36, 0x38);
write_reg(par, 0xB6, 0x00, 0x02, 0x3B);
write_reg(par, 0x36, 0x2B);
break;
default:
write_reg(par, 0xB6, 0x00, 0x22, 0x3B);
write_reg(par, 0x36, 0x08);
write_reg(par, 0x36, 0x09);
break;
}

Expand Down