> The Darkener's Console

You are behind the white house. A path leads into the forest to the east. In one corner of the house there is a small window which is slightly ajar.

Adjust Official Raspberry Pi 7″ Touchscreen LCD Brightness With Zenity —

Here’s a quick-n-dirty script for adjusting the Official Raspberry Pi 7″ Touchscreen LCD Brightness With Zenity (Tested on Raspbian):


#!/bin/bash
#
# Sets the Raspberry Pi touchscreen brightness.

# Set variables
zenity="/usr/bin/zenity"

# Get desired brightness level
b=$("$zenity" \
--scale \
--value=120 \
--min-value=10 \
--max-value=254 \
--step=2 \
--title "Set LCD Brightness" \
--text "Please set desired brightness level:")

# Set desired brightness level
echo "$b" > /sys/class/backlight/10-0045/brightness

exit 0


Categorised as: Blogs | Technical



Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.