Pi 2 + 320x240 Touchscreen + Kali1.1.0-rpi2.img

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/
Locked
User avatar
hanshass
 
Posts: 10
Joined: Tue Mar 17, 2015 5:13 am

Pi 2 + 320x240 Touchscreen + Kali1.1.0-rpi2.img

Post by hanshass »

Who can help me to get my 2.8" PiTFT Setup done?

1. I have a fresh installed "Kali 1.1.0 RPi2.img" Setup on the MicroSD
2. The 2.8" Touchpad is completely white after boot.....the whole time....theres no color-change
3. I have added the Ardafruit-Repo in Terminal and wrote in SSH-Terminal
"root@kali:~# apt-get update && apt-get upgrade -y && reboot now" ......Screen on the Pi was still white
4. After reboot i tried this
"root@kali:~# uname -a"
Linux kali 3.18.9-v7 #1 SMP PREEMPT Sat Mar 7 07:12:24 EST 2015 armv7l GNU/Linux
"root@kali:~# sudo adafruit-pitft-helper -t 28r"

Type = 28r
[PITFT] Updating X11 default calibration...
[PITFT] Updating X11 setup tweaks...
grep: /home/pi/.profile: No such file or directory
Adding 'export FRAMEBUFFER=/dev/fb1'
/usr/bin/adafruit-pitft-helper: line 169: /home/pi/.profile: No such file or directory
[PITFT] Exiting due to error: Unable to update X11 setup

So whats to do to get my PiTFT to work?
Hope someone can help me!
Attachments
2015-03-17 10_12_22-~.png
2015-03-17 10_12_22-~.png (28.95 KiB) Viewed 1096 times

User avatar
cegha04
 
Posts: 2
Joined: Wed Mar 04, 2015 12:04 am

Re: Pi 2 + 320x240 Touchscreen + Kali1.1.0-rpi2.img

Post by cegha04 »

I use Kali on my laptop. Kali uses Gnome. PiTFT code is designed for X11 which Raspbian uses. I do not know off the top of my head how to convert the work they have done to work on Gnome. You may be better off trying to get Kali to run X11 & if you can make it do that, then the code should just work like normal.

But that is the error your getting is that it's trying to patch & boot X11 which isn't running.

Edit:Actually even if you got X11 running, it may need some slight tweaking. Those directories are for Raspbian locations. You would need to change the scripts to point to where those files would install on Kali. It may or may not be the same location.

User avatar
adafruit2
 
Posts: 22148
Joined: Fri Mar 11, 2005 7:36 pm

Re: Pi 2 + 320x240 Touchscreen + Kali1.1.0-rpi2.img

Post by adafruit2 »

heya it looks like Kali has a custom kernel, and they're moving from 3.12 to 3.18 which they have to to support the Pi 2. What the maintainers of Kali have to do is apply our patches for PiTFT support OR use our 3.18.y branch https://github.com/adafruit/adafruit-raspberrypi-linux and then apply the wifi injection patches.

bpb
 
Posts: 39
Joined: Tue Jan 06, 2015 7:48 pm

Re: Pi 2 + 320x240 Touchscreen + Kali1.1.0-rpi2.img

Post by bpb »

Hey all. For what it's worth, there's now a tweaked version of adafruit-pitft-helper up on GitHub and in the apt repo. On a recent Pi 2 Kali image under a root login, it should work like so:

curl -SLs https://apt.adafruit.com/install | bash
apt-get update
apt-get install adafruit-pitft-helper
mount /dev/mmcblk0p1 /boot
adafruit-pitft-helper -t 28r -u /root

This will probably get you a working PiTFT, but as already mentioned, by itself it won't get you a working version of Kali with their custom kernel, since it's going to rely on our kernel package. (If anyone comes up with the right kernel, the helper script can be run just by grabbing a copy off GitHub so as to avoid pulling in the kernel package dependency.)

No promises, but I'll update this thread if I work up anything more useful.

User avatar
hanshass
 
Posts: 10
Joined: Tue Mar 17, 2015 5:13 am

Re: Pi 2 + 320x240 Touchscreen + Kali1.1.0-rpi2.img

Post by hanshass »

apt-get install curl lua5.1 triggerhappy fbset console-setup
sudo curl -L --output /usr/bin/rpi-update https://raw.githubusercontent.com/Hexxe ... rpi-update
sudo chmod +x /usr/bin/rpi-update
wget http://archive.raspberrypi.org/debian/p ... 28_all.deb
dpkg -i raspi-config_20121028_all.deb

nano /etc/dhcp/dhclient.conf
-> change timeout to 1

sudo REPO_URI=https://github.com/notro/rpi-firmware rpi-update

nano /boot/config.txt
-> add dtparam=spi=on

sudo reboot

sudo modprobe spi-bcm2708
sudo modprobe fbtft_device custom name=pitft width=240 height=320

nano /etc/modprobe.d/fbtft.conf
-> options fbtft_device custom name=pitft width=240 height=320

nano /etc/modprobe.d/adafruit.conf
-> options fbtft_device custom name=pitft width=240 height=320 rotate=90

nano /etc/modules
-> snd-bcm2835
-> spi-bcm2708
-> fbtft_device
-> con2fbmap 1 1

sudo reboot

FRAMEBUFFER=/dev/fb1 startx

Thanks to fhlipZero @ http://hackaday.io/project/4557-handheld-kali-pi-v2

User avatar
fhlipzero
 
Posts: 46
Joined: Tue Dec 10, 2013 6:35 am

Re: Pi 2 + 320x240 Touchscreen + Kali1.1.0-rpi2.img

Post by fhlipzero »

^^^^i know that guy^^^^ lol, yea my handheld pi worked like a charm after that but i think i still had touchscreen issues. I know i updated mine with the pitft helper but never updated by hackaday.io, will do tonight!

User avatar
hanshass
 
Posts: 10
Joined: Tue Mar 17, 2015 5:13 am

Re: Pi 2 + 320x240 Touchscreen + Kali1.1.0-rpi2.img

Post by hanshass »

:)

yes, another way is to install the pi2 kali image, add the adafruit repo, install the pitft-helper, update and reboot!
Thanks, im out!

bpb
 
Posts: 39
Joined: Tue Jan 06, 2015 7:48 pm

Re: Pi 2 + 320x240 Touchscreen + Kali1.1.0-rpi2.img

Post by bpb »

Some better documentation and a kernel package from our end:

https://learn.adafruit.com/kali-linux-o ... t/overview

Feedback welcome!

User avatar
hanshass
 
Posts: 10
Joined: Tue Mar 17, 2015 5:13 am

Re: Pi 2 + 320x240 Touchscreen + Kali1.1.0-rpi2.img

Post by hanshass »

Thanks alot......
works fine!

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”