Hi everyone,
I’m pretty new to resin io and I’m enjoying it so far. I’m trying to get a PiTFT working. I don’t need touchscreen events, I just want to show some content from Python with it. I have looked at a few things in the playground, mainly this node clock and this fullscreen browser.
Here’s my starting shell script:
udevd --daemon
udevadm trigger
echo "Running start shell script..."
if [ ! -c /dev/fb1 ]; then
echo "loading piTFT kernel module"
modprobe spi-bcm2835
modprobe fbtft_device name=pitft verbose=0 rotate=270
sleep 1
mknod /dev/fb1 c $(cat /sys/class/graphics/fb1/dev | tr ':' ' ')
fi
modprobe v4l2_common && python demo.py &
cd /data
python -m SimpleHTTPServer 80
The PiTFT goes black, but it doesn’t show anything. Here’s the log output:
Systemd init system enabled.
17.10.17 11:32:04 (+0100) systemd 215 running in system mode. (+PAM +AUDIT +SELINUX +IMA +SYSVINIT +LIBCRYPTSETUP +GCRYPT +ACL +XZ -SECCOMP -APPARMOR)
17.10.17 11:32:04 (+0100) Detected virtualization 'other'.
17.10.17 11:32:04 (+0100) Detected architecture 'arm'.
17.10.17 11:32:04 (+0100) Set hostname to <30f7d8b>.
17.10.17 11:32:08 (+0100) Running start shell script...
17.10.17 11:32:08 (+0100) loading piTFT kernel module
17.10.17 11:32:10 (+0100) cat: /sys/class/graphics/fb1/dev: No such file or directory
17.10.17 11:32:10 (+0100) mknod: missing operand after ‘c’
17.10.17 11:32:10 (+0100) Special files require major and minor device numbers.
17.10.17 11:32:10 (+0100) Try 'mknod --help' for more information.
17.10.17 11:32:12 (+0100) Serving HTTP on 0.0.0.0 port 80 ...
17.10.17 11:32:19 (+0100) Application is already running 'registry2.resin.io/gifbooth/4f9813ac4ae91638f1ddbc9328c09781798a0fb8'
Does anyone have some steps to getting the PiTFT working? What modules do I need to install to get this working? I’m assuming there might also be some frame buffer copying involved, ala Adafruit?
Any help is much appreciated.
Looks like it was just updated very recently as well, so should likely work…