State since x minutes

Hello,

i want to do some shutter shadowing with my node red module. Now, i think i can check every minute if the sun azimut is in my desired range and the lux value is higher than 40.000 lux for 2 minutes.
But how can i check if the sensor for lux reports values higher than 40.000 lux within the last 2 minutes?

The events:state sensor has this option, but this node i can only use to trigger something. but i need this option in the current state node, or something else.
Thanks for your help.