This tutorial extends the article "MicroPython: Taking photos with an ESP32" and in this case, the ESP32-CAM running MicroPython takes a photo every 5 seconds and saves it on the microSD card. The photos can be then combined into a time-lapse video!
The MicroPython official version doesn't support I2S interface. However, tsaarni wrote a driver for the OV2640 and forked the MicroPython repository to include it. Thus, you need to follow the instructions in this article: MicroPython: Taking photos with an ESP32 to install the right firmware.