LED - set rainbow intensity per day and night

The values in the documentation are wrong.
They are from brightest to off:
100
70
40
25
12
5
1
0

Create a cron job with the values and set them to “fixed”.
$ cat /etc/cron.d/rainbow_day_night
MAILTO=""
0 7 * * * root /usr/bin/rainbow intensity 70
0 7 * * * root /bin/echo 70 > /etc/rainbow.magic
0 19 * * * root /usr/bin/rainbow intensity 12
0 19 * * * root /bin/echo 12 > /etc/rainbow.magic

remove /etc/cron.d/rainbow

1 Like