pimoroni / st7789-python

Python library to control an ST7789 240x240 1.3" TFT LCD display.
MIT License
199 stars 54 forks source link

using ST7789 library for Mini Display Hat... How do I control the onboard LED? #20

Open Nwhitten opened 3 years ago

Nwhitten commented 3 years ago

Hi

when using the ST7789 library (not the displayhatmini library) is there a way to control the onboard LED??

thanks

Neil

Sebwap commented 3 years ago

Yes probably, by replicating the code included in display hat mini library!

Wikinaut commented 1 year ago

You do not need the library. Just control the ACT LED on pin 47.

See for example lines in https://github.com/Wikinaut/pinetradio/blob/main/pinetradio.py (look for ACT, which stands for activity LED.).

PI system use of the ACT-LED must be disabled. You can use this service https://github.com/Wikinaut/pinetradio/blob/main/disable-led.service and run sudo systemctl enable disable-led once.