I'm working on a way to get a lamp ON for a certain time (between 10pm to 3am) with a regular check of the state (if there is any outage, the Pi at the reboot will check the Lamp status). What I did was to set a Timer command each 10min what is perfect from here.
Now I got another issue as in case of an outage, the light and Rpi will turn OFF then if the current comes back in less than 10min, the Lamp will set herself into security mode (Hot reStart is really not good

Does someone have any solution for this?
Thank you