-
Notifications
You must be signed in to change notification settings - Fork 2
SYSFS
The FBTFT drivers exposes some files in the sysfs filesystem.
/sys/class/graphics/fb1
gamma Driver specific, see Gamma
0005 0001 0001 0001 0001 0001 0001 0001 0001 0001 0001 0001 0001 0001 0001 0001 0001 0001 0002 0002 0001 0001 0001 0002 0002 0002 0002 0002 0003 0003 0003 0003 0003 0003 0003 0003 0003 0003 0003 0004 0004 0004 0004 0004 0004 0004 0004 0004 0004 0004 0004 0005 0005 0005 0005 0005 0005 0005 0005 0005 0005 0005 0005
http://lxr.free-electrons.com/source/drivers/video/fbsysfs.c
bits_per_pixel
Read: fb_info->var.bits_per_pixel
16
Write: not supported by FBTFT
blank Read: (can be read, but returns nothing) Write: Currently only supported by ssd1351fb
# blank display
echo "4" | sudo tee blank
# unblank display
echo "0" | sudo tee blank
bl_curve Only works with drivers that have registered a backlight device. Not used by FBTFT, as it doesn't support PWM.
console (does nothing)
cursor (does nothing)
mode Read: If set: fb_info->mode (nothing) Write: does not apply to FBTFT
modes
Read: fb_info->modelist
U:128x128p-0
Write: does not apply to FBTFT
name
Read: fb_info->fix.id (driver name)
ssd1351fb
pan
0,0
rotate
Read: fb_info->var.rotate
0
Write: not supported by FBTFT
state
Read: fb_info->state
0
Write: don't know
stride
Read: fb_info->fix.line_length
256
virtual_size
Read: fb_info->var.xres_virtual, fb_info->var.yres_virtual
128,128
Write: not supported by FBTFT
OTHER
dev
29:1
device -> ../../../spi0.0
power/ (empty directory)
subsystem -> ../../../../../../../../class/graphics
uevent
MAJOR=29
MINOR=1
DEVNAME=fb1
Many FBTFT drivers have backlight support
/sys/backlight//
https://www.kernel.org/doc/Documentation/ABI/stable/sysfs-class-backlight
pi@raspberrypi /sys/class/graphics/fb1 $ ls -l
total 0
-rw-r--r-- 1 root root 4096 Jul 2 23:15 bits_per_pixel
-rw-r--r-- 1 root root 4096 Jul 2 23:15 blank
-rw-r--r-- 1 root root 4096 Jul 2 23:15 bl_curve
-rw-r--r-- 1 root root 4096 Jul 2 23:15 console
-rw-r--r-- 1 root root 4096 Jul 2 23:15 cursor
-r--r--r-- 1 root root 4096 Jul 2 23:15 dev
lrwxrwxrwx 1 root root 0 Jul 2 23:15 device -> ../../../spi0.0
-rw-rw-rw- 1 root root 4096 Jul 2 23:15 gamma
-rw-r--r-- 1 root root 4096 Jul 2 23:15 mode
-rw-r--r-- 1 root root 4096 Jul 2 23:15 modes
-r--r--r-- 1 root root 4096 Jul 2 23:15 name
-rw-r--r-- 1 root root 4096 Jul 2 23:15 pan
drwxr-xr-x 2 root root 0 Jul 2 23:15 power
-rw-r--r-- 1 root root 4096 Jul 2 23:15 rotate
-rw-r--r-- 1 root root 4096 Jul 2 23:15 state
-r--r--r-- 1 root root 4096 Jul 2 23:15 stride
lrwxrwxrwx 1 root root 0 Jul 2 23:15 subsystem -> ../../../../../../../../class/graphics
-rw-r--r-- 1 root root 4096 Jul 2 23:15 uevent
-rw-r--r-- 1 root root 4096 Jul 2 23:15 virtual_size