Closed tomvanbraeckel closed 3 days ago
The disk LED change is reasonable and I've pushed a commit to make your RG_GPIO_LED check actually work (it was default defined so your check would always fail).
But the backlight one isn't as straightforward because it isn't necessarily controlled by RG_GPIO_LCD_BCKL, so it's not a 100% good indication of the capability...
Ah yes, thanks for catching that. I can confirm the disk LED option is gone now, as well as the backlight option. I've added an additional "defined(AW_TFT_BACKLIGHT)" to cover the qtpy-gamer's backlight configuration.
I'm not happy with this solution, because future targets might use totally different things to control brightness. In fact, I have unmerged device support that uses /sys/class/backlight/...
for example.
I've added a constant. For simplicity we'll assume that if it's undefined or zero it means no backlight, so a short #if RG_SCREEN_BACKLIGHT
should correctly fail on both scenarios.
Alright, pushed it!
Simplify menu by hiding inoperable options, to avoid confusing the users.
On the Fri3D Camp 2022 badge, the backlight is always on, and there is no GPIO LED to show activity, AFAIK. In any case, if a board doesn't have these configured in config.h, then showing a changeable option in the menu for it doesn't make sense.