Pi 2 PiTFT Compatibility

Moderators: adafruit_support_bill, adafruit

Forum rules
Talk about Adafruit Raspberry Pi® accessories! Please do not ask for Linux support, this is for Adafruit products only! For Raspberry Pi help please visit: http://www.raspberrypi.org/phpBB3/
User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Pi 2 PiTFT Compatibility

Post by adafruit_support_rick »

Those of you with PiTFTs, you might want to check out this thread:
http://forums.adafruit.com/viewtopic.ph ... 48#p346252

User avatar
jbntx
 
Posts: 9
Joined: Sun Apr 14, 2013 3:02 pm

Re: Pi 2 Compatibility Updates

Post by jbntx »

It does work, Rick , but as the post says, the touchscreen does not work, so it's only half a solution. I've got it running on my RPi 2, and it works quite well with a keyboard and mousepad.

User avatar
tictag
 
Posts: 224
Joined: Sun Feb 15, 2015 4:01 pm

Re: Pi 2 Compatibility Updates

Post by tictag »

Just spent the better part of four hours scratching my head but finally got my Adafruit PiTFT 2.2" HAT Mini Kit - 320x240 2.2" TFT - No Touch working on my RP2 :-)

I'm not a developer and words like 'kernel' scare me to death but it is possible for laypeople out there and everything you need is on notros fbtft page (https://github.com/notro/fbtft/wiki).

Installation is pretty easy but configuration of the actual screen is a bit of a pain, in short the steps are:

STEP 1: Install fbtft

Code: Select all

sudo REPO_URI=https://github.com/notro/rpi-firmware rpi-update
STEP2: Modify config.txt by adding dtparam=spi=on and dtoverlay=pitft to /boot/config.txt

Code: Select all

sudo nano /boot/config.txt
STEP3: Enable the screen during boot by adding fbcon=map:10 fbcon=font:VGA8x8 to the end of /boot/cmdline.txt then for a more compact font in the terminal, choose UTF8 > Guess optimal character set > Terminus > 6 x 12 (framebuffer only) using dpkg-reconfigure

Code: Select all

sudo nano /boot/cmdline.txt
sudo dpkg-reconfigure console-setup
STEP4: Reboot to see your screen working on the RP2! :-)

Code: Select all

sudo reboot
That's it!.......but I found that the screen was upside down (for my needs) and the overlay (read that as 'configuration') included stuff about touch screens and GPIO pins that I didn't want. In order to change the overlay (configuration) you have to download and edit an example dts file (device tree script), compile it into a dtb (device tree blob) then store it in the /boot/overlays folder, to be called during the kernel boot. YOU ONLY NEED TO DO THIS IF YOU WANT TO CHANGE THE CONFIGURATION:


STEP5: Download an example dts file, for pitft:

Code: Select all

sudo wget https://raw.githubusercontent.com/notro/fbtft/master/dts/overlays/rpi/pitft-overlay.dts /boot/overlays/pitft-overlay.dts
STEP6: Edit it as required, for example, I changed the pitft: pitft@0 rotate parameter to 270 and completely removed the pitft_ts section. More info here: https://github.com/notro/fbtft/wiki/FBTFT-RPI-overlays

Code: Select all

sudo nano /boot/overlays/pitft-overlay.dts
STEP7: Compile the revised dts script into a revised dtb file

Code: Select all

wget -c https://raw.githubusercontent.com/RobertCNelson/tools/master/pkgs/dtc.sh
chmod +x dtc.sh
./dtc.sh
sudo dtc -@ -I dts -O dtb -o /boot/overlays/pitft-overlay.dtb pitft-overlay.dts
STEP8: Reboot

Code: Select all

sudo reboot
Your revised overlay (configuration) should now be active. Sweet.

p.s. Personally I don't like booting straight in X Windows so I used the raspi-config tool to boot to the terminal only. If I want to run it, I just type xstart at the terminal.
--

User avatar
raskolnikoov
 
Posts: 6
Joined: Tue Feb 17, 2015 5:59 pm

Re: Pi 2 Compatibility Updates

Post by raskolnikoov »

Hi, I have the Adafruit 2.8" TFT display with touch. Will this work for this model also (not the touch part)?

User avatar
jbntx
 
Posts: 9
Joined: Sun Apr 14, 2013 3:02 pm

Pi 2 PiTFT Compatibility

Post by jbntx »

Yes, it will.

User avatar
raskolnikoov
 
Posts: 6
Joined: Tue Feb 17, 2015 5:59 pm

Re: Pi 2 PiTFT Compatibility

Post by raskolnikoov »

I got it working today. But im having issues viewing RetroPie emulationstation on the pitft. When I start a game it goes black. Any idea?

User avatar
olipayne
 
Posts: 2
Joined: Tue Feb 17, 2015 4:06 pm

Re: Pi 2 PiTFT Compatibility

Post by olipayne »

raskolnikoov wrote:I got it working today. But im having issues viewing RetroPie emulationstation on the pitft. When I start a game it goes black. Any idea?
Did you up the gpu_mem?

User avatar
raskolnikoov
 
Posts: 6
Joined: Tue Feb 17, 2015 5:59 pm

Re: Pi 2 PiTFT Compatibility

Post by raskolnikoov »

Yes it's set to 256mb. I got picture on the hdmi cabel put not on pitft.

User avatar
tapanther
 
Posts: 2
Joined: Sat Feb 21, 2015 12:53 am

Re: Pi 2 PiTFT Compatibility

Post by tapanther »

raskolnikoov wrote:I got it working today. But im having issues viewing RetroPie emulationstation on the pitft. When I start a game it goes black. Any idea?
Hey raskolnikoov,

If I'm not mistaken, emulationstation doesn't work directly on the PiTFT. If you look at this reddit thread ( http://www.reddit.com/r/raspberry_pi/co ... _retropie/ ) you need fbcp to "copy" the image output from emulationstation to the PiTFT framebuffer, but it's a little slow.

User avatar
antony123
 
Posts: 6
Joined: Tue Feb 17, 2015 9:48 am

Re: Pi 2 PiTFT Compatibility

Post by antony123 »

my display pitft 1601 initially is white, after putting the driver turns black but do not see anything ... why?

User avatar
martywittrock
 
Posts: 7
Joined: Mon Feb 16, 2015 11:38 pm

Re: Pi 2 PiTFT Compatibility

Post by martywittrock »

tictag,

Just a quick question - I followed all your steps and I have the display working excellent in console mode - all the characters are visible on the display and looks great..! But when I do 'startx' the PI boots directly to my HDMI screen and not to the 2.8" pitft display. I made all the adjustments to the cmdline and config files, but still not getting the Raspi to display there. I've tried the FRAMEBUFFER=/dev/fb0 startx and FRAMEBUFFER=/dev/fb1 startx commands on the console display (on the 2.8" tft at that time) and see all that happening, but it only boots to HDMI.

Any hints as to why this is happening? Please advise at your soonest - thanks..!

Marty

User avatar
AuronJS
 
Posts: 12
Joined: Sat Feb 21, 2015 3:04 pm

Re: Pi 2 PiTFT Compatibility

Post by AuronJS »

Marty,

Did you modify /usr/share/X11/xorg.conf.d/99-fbturbo.conf by changing
Option "fbdev" "/dev/fb0"
to
Option "fbdev" "/dev/fb1"

?

User avatar
martywittrock
 
Posts: 7
Joined: Mon Feb 16, 2015 11:38 pm

Re: Pi 2 PiTFT Compatibility

Post by martywittrock »

Auron,

IT WORKED..!! Many thanks for the tip on getting my 2.8" pitft to work with my Pi V2 Model B - - it looks GREAT..! :)

Thanks again -

Marty

User avatar
AuronJS
 
Posts: 12
Joined: Sat Feb 21, 2015 3:04 pm

Re: Pi 2 PiTFT Compatibility

Post by AuronJS »

Awesome!!!

User avatar
martywittrock
 
Posts: 7
Joined: Mon Feb 16, 2015 11:38 pm

Re: Pi 2 PiTFT Compatibility

Post by martywittrock »

Auron,

Now that I have the small screen working for display (no touch), I'm not able to switch between the HDMI and the small screen like I did before by doing the following right after log-in:

FRAMEBUFFER=/dev/fb0 startx (for the small screen)
FRAMEBUFFER=/dev/fb1 startx (for the HDMI screen)

It just keeps booting into the small screen.

Is there a fix for this...? Please let me know - thanks!

Marty

Locked
Forum rules
Talk about Adafruit Raspberry Pi® accessories! Please do not ask for Linux support, this is for Adafruit products only! For Raspberry Pi help please visit: http://www.raspberrypi.org/phpBB3/

Return to “Adafruit Raspberry Pi® accessories”