Led indication that Pi is on or off,

I am finishing project with audio streamer based on RPi4 and hifiberry Dac+ pro. I have added button for power up/down but I dnt know how to add Led indicator on the front panel. Can you help ? I am just starting adventure with Raspberry Pi.

just google…

https://aliexpress.ru/item/1005002424453281.html?spm=a2g0o.order_list.order_list_main.225.21efa396NduEl1&gatewayAdapt=glo2rus&sku_id=12000020604378522

Today I came back to this project and discovered that if I set Shutdown button as enabled then Hifiberry dac+ Pro stops playing. I tried with different GPIO pins settings, also tried to set play/pause button and nothing. Does anyone have any solution how to add buttons to volumio and hifiberry? maybe you need to change hifiberry to another manufacturer or volumio to something else? Please help. This project makes no sense for me without buttons.

Have you checked which GPIO you’re using and which ones are reserved for the Hifiberry?

HIFIBERRY DAC+, DAC+ ADC, DIGI+ AND AMP+, DAC2 PRO
GPIO2-3 (pins 3 and 5) are used by our products for configuration. If you are experienced with I2C, you might add other slave devices. If you a a novice, we don’t recommend this at all.
GPIOs 18-21 (pins 12, 35, 38 and 40) are used for the sound interface. You can’t use them for any other purpose.

On the HiFiBerry Digi+, GPIO16 is also reserved.

On the HiFiBerry Digi+ Pro GPIOs 5 and 6 are also used and cannot be used for anything else.

Yes, I have, and I did’t use reserved GPIO’s

This is almost impossible to support. You did something wrong. For me this is pnly guessing a bit.

  • Your using a GPIO that is default High or Low and mixed up the pull up/down resistor
  • You have plugins installed that influence the GPIO behavior
  • What is the output of cat /boot/config.txt
  • What is the output of cat /boot/userconfig.txt
  • Please post a full log of the problem
  • List all your installed plugins

OK , let me explain a bit more . I am building streamer using old tape deck . last few weeks I am trying to instal buttons witch exist on the front panel.
I am using RPi4B , Hifiberry Dac2 Pro and touch screen. I have instaled Volumio 3.396 and plugin GPIO Buttons 0.8.3.
Can somebody help me to get those buttons working ?