summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--README13
-rw-r--r--recipes-bsp/bootfiles/rpi-config_git.bb6
-rw-r--r--recipes-graphics/xorg-xserver/xserver-xf86-config/rpi/xorg.conf.d/99-pitft.conf5
-rw-r--r--recipes-graphics/xorg-xserver/xserver-xf86-config_0.1.bbappend11
-rw-r--r--recipes-kernel/linux/linux-raspberrypi.inc6
5 files changed, 36 insertions, 5 deletions
diff --git a/README b/README
index 3e879dd..129f5e2 100644
--- a/README
+++ b/README
@@ -28,6 +28,7 @@ Contents:
28 3.K. Device tree support 28 3.K. Device tree support
29 3.L. Enable SPI bus 29 3.L. Enable SPI bus
30 3.M. Enable I2C 30 3.M. Enable I2C
31 3.N. Enable PiTFT support
314. Extra apps 324. Extra apps
32 4.A. omxplayer 33 4.A. omxplayer
335. Board Configuration 345. Board Configuration
@@ -213,6 +214,18 @@ ENABLE_SPI_BUS = "1"
213When using device tree kernels, set this variable to enable I2C 214When using device tree kernels, set this variable to enable I2C
214ENABLE_I2C = "1" 215ENABLE_I2C = "1"
215 216
2173.N. Enable PiTFT support
218=========================
219Basic support for using PiTFT screens can be enabled by adding
220below in local.conf:
221
222MACHINE_FEATURES += "pitft"
223 - This will enable SPI bus and i2c device-trees, it will also setup
224 framebuffer for console and x server on PiTFT.
225
226NOTE: To get this working the overlay for the PiTFT model must be build,
227 added and specified as well (dtoverlay=<driver> in config.txt)
228
216 229
2174. Extra apps 2304. Extra apps
218============= 231=============
diff --git a/recipes-bsp/bootfiles/rpi-config_git.bb b/recipes-bsp/bootfiles/rpi-config_git.bb
index 138cb37..bfe00d1 100644
--- a/recipes-bsp/bootfiles/rpi-config_git.bb
+++ b/recipes-bsp/bootfiles/rpi-config_git.bb
@@ -15,6 +15,8 @@ S = "${WORKDIR}/git"
15 15
16PR = "r4" 16PR = "r4"
17 17
18PITFT="${@bb.utils.contains("MACHINE_FEATURES", "pitft", "1", "0", d)}"
19
18inherit deploy 20inherit deploy
19 21
20do_deploy() { 22do_deploy() {
@@ -71,12 +73,12 @@ do_deploy() {
71 fi 73 fi
72 74
73 # SPI bus support 75 # SPI bus support
74 if [ -n "${ENABLE_SPI_BUS}" ]; then 76 if [ -n "${ENABLE_SPI_BUS}" ] || [ "${PITFT}" = "1" ]; then
75 echo "# Enable SPI bus" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt 77 echo "# Enable SPI bus" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt
76 echo "dtparam=spi=on" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt 78 echo "dtparam=spi=on" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt
77 fi 79 fi
78 80
79 if [ -n "${ENABLE_I2C}" ]; then 81 if [ -n "${ENABLE_I2C}" ] || [ "${PITFT}" = "1" ]; then
80 echo "# Enable I2C" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt 82 echo "# Enable I2C" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt
81 echo "dtparam=i2c1=on" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt 83 echo "dtparam=i2c1=on" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt
82 echo "dtparam=i2c_arm=on" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt 84 echo "dtparam=i2c_arm=on" >>${DEPLOYDIR}/bcm2835-bootfiles/config.txt
diff --git a/recipes-graphics/xorg-xserver/xserver-xf86-config/rpi/xorg.conf.d/99-pitft.conf b/recipes-graphics/xorg-xserver/xserver-xf86-config/rpi/xorg.conf.d/99-pitft.conf
new file mode 100644
index 0000000..0d2b36b
--- /dev/null
+++ b/recipes-graphics/xorg-xserver/xserver-xf86-config/rpi/xorg.conf.d/99-pitft.conf
@@ -0,0 +1,5 @@
1Section "Device"
2 Identifier "Adafruit PiTFT"
3 Driver "fbdev"
4 Option "fbdev" "/dev/fb1"
5EndSection
diff --git a/recipes-graphics/xorg-xserver/xserver-xf86-config_0.1.bbappend b/recipes-graphics/xorg-xserver/xserver-xf86-config_0.1.bbappend
index 2cf40f8..0ae2ee0 100644
--- a/recipes-graphics/xorg-xserver/xserver-xf86-config_0.1.bbappend
+++ b/recipes-graphics/xorg-xserver/xserver-xf86-config_0.1.bbappend
@@ -1,10 +1,17 @@
1FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" 1FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
2 2
3SRC_URI_append_rpi = " file://xorg.conf.d/10-evdev.conf " 3SRC_URI_append_rpi = " file://xorg.conf.d/10-evdev.conf \
4 file://xorg.conf.d/99-pitft.conf \
5 "
4 6
5do_install_append_rpi () { 7do_install_append_rpi () {
6 install -d ${D}/${sysconfdir}/X11/xorg.conf.d/ 8 install -d ${D}/${sysconfdir}/X11/xorg.conf.d/
7 install -m 0644 ${WORKDIR}/xorg.conf.d/* ${D}/${sysconfdir}/X11/xorg.conf.d/ 9 install -m 0644 ${WORKDIR}/xorg.conf.d/10-evdev.conf ${D}/${sysconfdir}/X11/xorg.conf.d/
10
11 PITFT="${@bb.utils.contains("MACHINE_FEATURES", "pitft", "1", "0", d)}"
12 if [ "${PITFT}" = "1" ]; then
13 install -m 0644 ${WORKDIR}/xorg.conf.d/99-pitft.conf ${D}/${sysconfdir}/X11/xorg.conf.d/
14 fi
8} 15}
9 16
10FILES_${PN}_rpi += "${sysconfdir}/X11/xorg.conf ${sysconfdir}/X11/xorg.conf.d/*" 17FILES_${PN}_rpi += "${sysconfdir}/X11/xorg.conf ${sysconfdir}/X11/xorg.conf.d/*"
diff --git a/recipes-kernel/linux/linux-raspberrypi.inc b/recipes-kernel/linux/linux-raspberrypi.inc
index 5a8a175..4f59c97 100644
--- a/recipes-kernel/linux/linux-raspberrypi.inc
+++ b/recipes-kernel/linux/linux-raspberrypi.inc
@@ -53,7 +53,11 @@ do_install_prepend() {
53do_deploy_append() { 53do_deploy_append() {
54 # Deploy cmdline.txt 54 # Deploy cmdline.txt
55 install -d ${DEPLOYDIR}/bcm2835-bootfiles 55 install -d ${DEPLOYDIR}/bcm2835-bootfiles
56 echo "${CMDLINE}" > ${DEPLOYDIR}/bcm2835-bootfiles/cmdline.txt 56 PITFT="${@bb.utils.contains("MACHINE_FEATURES", "pitft", "1", "0", d)}"
57 if [ ${PITFT} = "1" ]; then
58 PITFT_PARAMS="fbcon=map:10 fbcon=font:VGA8x8"
59 fi
60 echo "${CMDLINE}${PITFT_PARAMS}" > ${DEPLOYDIR}/bcm2835-bootfiles/cmdline.txt
57} 61}
58 62
59do_rpiboot_mkimage() { 63do_rpiboot_mkimage() {