He uses a FET as a low side current switch to switch the GND of the ESP32-Cam. The FET is triggered by a PIR sensor which keeps its output high for 2 seconds in case of motion.