Timelapse code for Raspberry Pi and PiCamera.