a) pg_sleep_for - no objection - it is simple and secure
b) pg_sleep_until
I am not sure - maybe this implementation is too simply. I see two possible risk where it should not work as users can expect
a) what will be expected behave whem time is changed - CET/CEST ?
b) what will be expected behave when board clock is not accurate and it is periodically fixed (by NTP) - isn't better to sleep only few seconds and recalculate sleeping interval?