Skip to content

Instantly share code, notes, and snippets.

@actuino
Last active July 16, 2023 07:51
Show Gist options
  • Star 8 You must be signed in to star a gist
  • Fork 3 You must be signed in to fork a gist
  • Save actuino/7801a03342665dc988b0f9bb7c257348 to your computer and use it in GitHub Desktop.
Save actuino/7801a03342665dc988b0f9bb7c257348 to your computer and use it in GitHub Desktop.
Cheap 3.95 TFT Screen with ili9488 from mcufriend on a Raspberry Pi Zero

Resolution 480x320 Ili9488 TFT 3.95" From mcufriend, about $8

Info from

Steps

sudo nano /etc/modules-load.d/fbtft.conf
add the following lines:

spi-bcm2835
flexfb
fbtft_device

sudo nano /etc/modprobe.d/fbtft.conf

add the following 2 lines:

options fbtft_device name=flexpfb rotate=180 fps=60 gpios=dc:18,reset:7,wr:17,cs:4,db00:22,db01:23,db02:24,db03:10,db04:25,db05:9,db06:11,db07:8
options flexfb width=480 height=320 buswidth=8 init=-1,0xb0,0x0,-1,0x11,-2,120,-1,0x3A,0x55,-1,0xC2,0x33,-1,0xC5,0x00,0x1E,0x80,-1,0x36,0x28,-1,0xB1,0xB0,-1,0xE0,0x00,0x04,0x0E,0x08,0x17,0x0A,0x40,0x79,0x4D,0x07,0x0E,0x0A,0x1A,0x1D,0x0F,-1,0xE1,0x00,0x1B,0x1F,0x02,0x10,0x05,0x32,0x34,0x43,0x02,0x0A,0x09,0x33,0x37,0x0F,-1,0x11,-1,0x29,-3

sudo nano /boot/cmdline.txt
add this text one the same line, BEFORE rootwait parameter:
fbcon=map:10 fbcon=font:VGA8x8 FRAMEBUFFER=/dev/fb1

sudo apt-get install xserver-xorg-video-fbdev

sudo nano /usr/share/X11/xorg.conf.d/99-fbdev.conf

add the following lines:

Section "Device"  
  Identifier "myfb"
  Driver "fbdev"
  Option "fbdev" "/dev/fb1"
EndSection

save & reboot

See Also

@m412de
Copy link

m412de commented May 24, 2018

very cool. thank you.

I've tried it with my new raspberry pi 3 b+.
the screen switched from only white after reboot to something different and blinking.

any help with it?

@codeclinic
Copy link

After having this thing sat in a draw for approx 4 years, I finally found something about it. I'll give this a try asap, hopefully it actually works.

Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment