Help with Template sensor (Time into Percentage)

Hey :wave:

Thanks for stopping by! I need help with a template sensor. I have a ESP32 Box3 S3 with custom firmware from BigBobbas. With that you get a sensor which shows you the time left on a timer, you made with voice assistant. And because I like to make a visual timer with WLED I need a template sensor that converts the Time into percentage.

The sensor is always at 0:00:00 by standard. When you set a timer by voice, it changes to the desired timer countdown. E.g. a 12 minute timer is shown as 0:12:00 and counting down.

I tried to modify the version for Alexa timers, but this one has no state attributes. So Iā€™m struggling a bit.

Maybe on of you can help!

Bonus question: is it possible to get the time left also on a Awtrix LED matrix clock? This thing is not in use and would be a great addition :slight_smile:

Thanks and cheers!