Routine not running

I created a routine as follows:
Time Period 7:10 am to 7:15 am, Weekdays, once per day
And If
Presence sensor present

Turn on a switch

This does not turn on the switch if during the time period the presence sensor is present. Why not???

Try making the presence a precondition and keep the rest the same.

If that doesn’t work try just using a set time of 7:10am

It should work if the presence sensor changes to present during the time period but not if it is already present at the start. Routines need triggering events to make them do their stuff and the beginning and end of the time period aren’t such things. If you are going to use Routines you’ll need an extra one to run at the start of the time period to see if the presence sensor is already present.