How to stop void loop() after 20 minutes

I am making a program for a robot vacuum, and I want it to stop after 20 minutes, does anybody knows how to do it?
Sorry for my english :smiley: :smiley:

if (millis() >= 20ul * 60ul * 1000ul){

That will lock the program up 20 minutes after the board starts. If that's not what you want then maybe you need to be a bit more specific.

Thank you!