Code and design for a Raspberry Pi-based photo controller