Working switch. Now I only have to store the data in a way that makes sense